diff options
author | Thomas Pugliese <thomas.pugliese@gmail.com> | 2014-09-17 01:40:15 +0400 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-09-24 09:06:59 +0400 |
commit | 275e517c30ab23d6da332419b6da5e2d5a234891 (patch) | |
tree | a666464f83ff70b5cac837aca401913b9d45ca26 /drivers/usb/wusbcore/wusbhc.h | |
parent | b94be0db5b17fe5616ecfc4c064264625f92afb2 (diff) | |
download | linux-275e517c30ab23d6da332419b6da5e2d5a234891.tar.xz |
usb: wusbcore: fix device disconnect on rekey timeout
If three or more wireless devices are connected and two of them
disconnect between 1-3 seconds apart, it can cause the HWA to disconnect
the remaining devices due to failing to see a DN_Alive message from
them. This happens because when the HWA detects that the first device
is gone, it will attempt to rekey the remaining devices. If one of the
devices is not responding because it has also been disconnected but not
yet timed out, the synchronous rekey operation running on the wusbd
workqueue can block for up to 5 seconds. This will prevent the
KEEPALIVE timer from running and DN_Alive messages from being processed
because they are processed by the same workqueue. This patch moves the
rekey operation to a separate workqueue since it is the only wusb work
item that needs to communicate directly with wireless devices. The rest
of the WUSB work items either perform no device IO or communicate
directly with the host controller and should not be blocked out by a
non-responding wireless device.
Signed-off-by: Thomas Pugliese <thomas.pugliese@gmail.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/usb/wusbcore/wusbhc.h')
-rw-r--r-- | drivers/usb/wusbcore/wusbhc.h | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/usb/wusbcore/wusbhc.h b/drivers/usb/wusbcore/wusbhc.h index 2384add45371..41838db7f85c 100644 --- a/drivers/usb/wusbcore/wusbhc.h +++ b/drivers/usb/wusbcore/wusbhc.h @@ -295,6 +295,9 @@ struct wusbhc { } __attribute__((packed)) gtk; u8 gtk_index; u32 gtk_tkid; + + /* workqueue for WUSB security related tasks. */ + struct workqueue_struct *wq_security; struct work_struct gtk_rekey_work; struct usb_encryption_descriptor *ccm1_etd; |