diff options
author | Sarah Sharp <sarah.a.sharp@linux.intel.com> | 2012-04-23 13:08:51 -0400 |
---|---|---|
committer | Sarah Sharp <sarah.a.sharp@linux.intel.com> | 2012-05-18 18:42:55 -0400 |
commit | e1f12eb6ba6f1e74007eb01ed26fad7c5239d62b (patch) | |
tree | 4c6753fc5091cd31b8cc0029e41f86f4f8c3b195 /drivers/net/wireless | |
parent | e3567d2c15a7a8e2f992a5f7c7683453ca406d82 (diff) |
USB: Disable hub-initiated LPM for comms devices.
Hub-initiated LPM is not good for USB communications devices. Comms
devices should be able to tell when their link can go into a lower power
state, because they know when an incoming transmission is finished.
Ideally, these devices would slam their links into a lower power state,
using the device-initiated LPM, after finishing the last packet of their
data transfer.
If we enable the idle timeouts for the parent hubs to enable
hub-initiated LPM, we will get a lot of useless LPM packets on the bus
as the devices reject LPM transitions when they're in the middle of
receiving data. Worse, some devices might blindly accept the
hub-initiated LPM and power down their radios while they're in the
middle of receiving a transmission.
The Intel Windows folks are disabling hub-initiated LPM for all USB
communications devices under a xHCI USB 3.0 host. In order to keep
the Linux behavior as close as possible to Windows, we need to do the
same in Linux.
Set the disable_hub_initiated_lpm flag for for all USB communications
drivers. I know there aren't currently any USB 3.0 devices that
implement these class specifications, but we should be ready if they do.
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Cc: Marcel Holtmann <marcel@holtmann.org>
Cc: Gustavo Padovan <gustavo@padovan.org>
Cc: Johan Hedberg <johan.hedberg@gmail.com>
Cc: Hansjoerg Lipp <hjlipp@web.de>
Cc: Tilman Schmidt <tilman@imap.cc>
Cc: Karsten Keil <isdn@linux-pingi.de>
Cc: Peter Korsgaard <jacmet@sunsite.dk>
Cc: Jan Dumon <j.dumon@option.com>
Cc: Petko Manolov <petkan@users.sourceforge.net>
Cc: Steve Glendinning <steve.glendinning@smsc.com>
Cc: "John W. Linville" <linville@tuxdriver.com>
Cc: Kalle Valo <kvalo@qca.qualcomm.com>
Cc: "Luis R. Rodriguez" <mcgrof@qca.qualcomm.com>
Cc: Jouni Malinen <jouni@qca.qualcomm.com>
Cc: Vasanthakumar Thiagarajan <vthiagar@qca.qualcomm.com>
Cc: Senthil Balasubramanian <senthilb@qca.qualcomm.com>
Cc: Christian Lamparter <chunkeey@googlemail.com>
Cc: Brett Rudley <brudley@broadcom.com>
Cc: Roland Vossen <rvossen@broadcom.com>
Cc: Arend van Spriel <arend@broadcom.com>
Cc: "Franky (Zhenhui) Lin" <frankyl@broadcom.com>
Cc: Kan Yan <kanyan@broadcom.com>
Cc: Dan Williams <dcbw@redhat.com>
Cc: Jussi Kivilinna <jussi.kivilinna@mbnet.fi>
Cc: Ivo van Doorn <IvDoorn@gmail.com>
Cc: Gertjan van Wingerde <gwingerde@gmail.com>
Cc: Helmut Schaa <helmut.schaa@googlemail.com>
Cc: Herton Ronaldo Krzesinski <herton@canonical.com>
Cc: Hin-Tak Leung <htl10@users.sourceforge.net>
Cc: Larry Finger <Larry.Finger@lwfinger.net>
Cc: Chaoming Li <chaoming_li@realsil.com.cn>
Cc: Daniel Drake <dsd@gentoo.org>
Cc: Ulrich Kunitz <kune@deine-taler.de>
Signed-off-by: Sarah Sharp <sarah.a.sharp@linux.intel.com>
Diffstat (limited to 'drivers/net/wireless')
-rw-r--r-- | drivers/net/wireless/at76c50x-usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath6kl/usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/hif_usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/ath/carl9170/usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/brcm80211/brcmfmac/usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/libertas/if_usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/libertas_tf/if_usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/orinoco/orinoco_usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/p54/p54usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/rndis_wlan.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2500usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt2800usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/rt2x00/rt73usb.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/rtl818x/rtl8187/dev.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/rtlwifi/rtl8192cu/sw.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/zd1201.c | 1 | ||||
-rw-r--r-- | drivers/net/wireless/zd1211rw/zd_usb.c | 1 |
17 files changed, 17 insertions, 0 deletions
diff --git a/drivers/net/wireless/at76c50x-usb.c b/drivers/net/wireless/at76c50x-usb.c index cc741b3cc024..9dcd49cfab94 100644 --- a/drivers/net/wireless/at76c50x-usb.c +++ b/drivers/net/wireless/at76c50x-usb.c | |||
@@ -2486,6 +2486,7 @@ static struct usb_driver at76_driver = { | |||
2486 | .probe = at76_probe, | 2486 | .probe = at76_probe, |
2487 | .disconnect = at76_disconnect, | 2487 | .disconnect = at76_disconnect, |
2488 | .id_table = dev_table, | 2488 | .id_table = dev_table, |
2489 | .disable_hub_initiated_lpm = 1, | ||
2489 | }; | 2490 | }; |
2490 | 2491 | ||
2491 | static int __init at76_mod_init(void) | 2492 | static int __init at76_mod_init(void) |
diff --git a/drivers/net/wireless/ath/ath6kl/usb.c b/drivers/net/wireless/ath/ath6kl/usb.c index 325b1224c2b1..f8a27db69c7f 100644 --- a/drivers/net/wireless/ath/ath6kl/usb.c +++ b/drivers/net/wireless/ath/ath6kl/usb.c | |||
@@ -405,6 +405,7 @@ static struct usb_driver ath6kl_usb_driver = { | |||
405 | .probe = ath6kl_usb_probe, | 405 | .probe = ath6kl_usb_probe, |
406 | .disconnect = ath6kl_usb_remove, | 406 | .disconnect = ath6kl_usb_remove, |
407 | .id_table = ath6kl_usb_ids, | 407 | .id_table = ath6kl_usb_ids, |
408 | .disable_hub_initiated_lpm = 1, | ||
408 | }; | 409 | }; |
409 | 410 | ||
410 | static int ath6kl_usb_init(void) | 411 | static int ath6kl_usb_init(void) |
diff --git a/drivers/net/wireless/ath/ath9k/hif_usb.c b/drivers/net/wireless/ath/ath9k/hif_usb.c index 424aabb2c730..dea53dea9a53 100644 --- a/drivers/net/wireless/ath/ath9k/hif_usb.c +++ b/drivers/net/wireless/ath/ath9k/hif_usb.c | |||
@@ -1356,6 +1356,7 @@ static struct usb_driver ath9k_hif_usb_driver = { | |||
1356 | #endif | 1356 | #endif |
1357 | .id_table = ath9k_hif_usb_ids, | 1357 | .id_table = ath9k_hif_usb_ids, |
1358 | .soft_unbind = 1, | 1358 | .soft_unbind = 1, |
1359 | .disable_hub_initiated_lpm = 1, | ||
1359 | }; | 1360 | }; |
1360 | 1361 | ||
1361 | int ath9k_hif_usb_init(void) | 1362 | int ath9k_hif_usb_init(void) |
diff --git a/drivers/net/wireless/ath/carl9170/usb.c b/drivers/net/wireless/ath/carl9170/usb.c index 89821e4835c7..888152ce3eca 100644 --- a/drivers/net/wireless/ath/carl9170/usb.c +++ b/drivers/net/wireless/ath/carl9170/usb.c | |||
@@ -1159,6 +1159,7 @@ static struct usb_driver carl9170_driver = { | |||
1159 | .resume = carl9170_usb_resume, | 1159 | .resume = carl9170_usb_resume, |
1160 | .reset_resume = carl9170_usb_resume, | 1160 | .reset_resume = carl9170_usb_resume, |
1161 | #endif /* CONFIG_PM */ | 1161 | #endif /* CONFIG_PM */ |
1162 | .disable_hub_initiated_lpm = 1, | ||
1162 | }; | 1163 | }; |
1163 | 1164 | ||
1164 | module_usb_driver(carl9170_driver); | 1165 | module_usb_driver(carl9170_driver); |
diff --git a/drivers/net/wireless/brcm80211/brcmfmac/usb.c b/drivers/net/wireless/brcm80211/brcmfmac/usb.c index 82364223e817..8852d23ef829 100644 --- a/drivers/net/wireless/brcm80211/brcmfmac/usb.c +++ b/drivers/net/wireless/brcm80211/brcmfmac/usb.c | |||
@@ -1605,6 +1605,7 @@ static struct usb_driver brcmf_usbdrvr = { | |||
1605 | .suspend = brcmf_usb_suspend, | 1605 | .suspend = brcmf_usb_suspend, |
1606 | .resume = brcmf_usb_resume, | 1606 | .resume = brcmf_usb_resume, |
1607 | .supports_autosuspend = 1 | 1607 | .supports_autosuspend = 1 |
1608 | .disable_hub_initiated_lpm = 1, | ||
1608 | }; | 1609 | }; |
1609 | 1610 | ||
1610 | void brcmf_usb_exit(void) | 1611 | void brcmf_usb_exit(void) |
diff --git a/drivers/net/wireless/libertas/if_usb.c b/drivers/net/wireless/libertas/if_usb.c index 74da5f1ea243..76ea66d53b9c 100644 --- a/drivers/net/wireless/libertas/if_usb.c +++ b/drivers/net/wireless/libertas/if_usb.c | |||
@@ -1180,6 +1180,7 @@ static struct usb_driver if_usb_driver = { | |||
1180 | .suspend = if_usb_suspend, | 1180 | .suspend = if_usb_suspend, |
1181 | .resume = if_usb_resume, | 1181 | .resume = if_usb_resume, |
1182 | .reset_resume = if_usb_resume, | 1182 | .reset_resume = if_usb_resume, |
1183 | .disable_hub_initiated_lpm = 1, | ||
1183 | }; | 1184 | }; |
1184 | 1185 | ||
1185 | module_usb_driver(if_usb_driver); | 1186 | module_usb_driver(if_usb_driver); |
diff --git a/drivers/net/wireless/libertas_tf/if_usb.c b/drivers/net/wireless/libertas_tf/if_usb.c index 7ced130f4f9e..19a5a92dd779 100644 --- a/drivers/net/wireless/libertas_tf/if_usb.c +++ b/drivers/net/wireless/libertas_tf/if_usb.c | |||
@@ -920,6 +920,7 @@ static struct usb_driver if_usb_driver = { | |||
920 | .id_table = if_usb_table, | 920 | .id_table = if_usb_table, |
921 | .suspend = if_usb_suspend, | 921 | .suspend = if_usb_suspend, |
922 | .resume = if_usb_resume, | 922 | .resume = if_usb_resume, |
923 | .disable_hub_initiated_lpm = 1, | ||
923 | }; | 924 | }; |
924 | 925 | ||
925 | module_usb_driver(if_usb_driver); | 926 | module_usb_driver(if_usb_driver); |
diff --git a/drivers/net/wireless/orinoco/orinoco_usb.c b/drivers/net/wireless/orinoco/orinoco_usb.c index f634d4582bfe..7f53cea2f205 100644 --- a/drivers/net/wireless/orinoco/orinoco_usb.c +++ b/drivers/net/wireless/orinoco/orinoco_usb.c | |||
@@ -1752,6 +1752,7 @@ static struct usb_driver orinoco_driver = { | |||
1752 | .probe = ezusb_probe, | 1752 | .probe = ezusb_probe, |
1753 | .disconnect = ezusb_disconnect, | 1753 | .disconnect = ezusb_disconnect, |
1754 | .id_table = ezusb_table, | 1754 | .id_table = ezusb_table, |
1755 | .disable_hub_initiated_lpm = 1, | ||
1755 | }; | 1756 | }; |
1756 | 1757 | ||
1757 | module_usb_driver(orinoco_driver); | 1758 | module_usb_driver(orinoco_driver); |
diff --git a/drivers/net/wireless/p54/p54usb.c b/drivers/net/wireless/p54/p54usb.c index f4d28c39aac7..d14dc81820e3 100644 --- a/drivers/net/wireless/p54/p54usb.c +++ b/drivers/net/wireless/p54/p54usb.c | |||
@@ -1081,6 +1081,7 @@ static struct usb_driver p54u_driver = { | |||
1081 | .reset_resume = p54u_resume, | 1081 | .reset_resume = p54u_resume, |
1082 | #endif /* CONFIG_PM */ | 1082 | #endif /* CONFIG_PM */ |
1083 | .soft_unbind = 1, | 1083 | .soft_unbind = 1, |
1084 | .disable_hub_initiated_lpm = 1, | ||
1084 | }; | 1085 | }; |
1085 | 1086 | ||
1086 | module_usb_driver(p54u_driver); | 1087 | module_usb_driver(p54u_driver); |
diff --git a/drivers/net/wireless/rndis_wlan.c b/drivers/net/wireless/rndis_wlan.c index d66e2980bc27..748a89de50d0 100644 --- a/drivers/net/wireless/rndis_wlan.c +++ b/drivers/net/wireless/rndis_wlan.c | |||
@@ -3776,6 +3776,7 @@ static struct usb_driver rndis_wlan_driver = { | |||
3776 | .disconnect = usbnet_disconnect, | 3776 | .disconnect = usbnet_disconnect, |
3777 | .suspend = usbnet_suspend, | 3777 | .suspend = usbnet_suspend, |
3778 | .resume = usbnet_resume, | 3778 | .resume = usbnet_resume, |
3779 | .disable_hub_initiated_lpm = 1, | ||
3779 | }; | 3780 | }; |
3780 | 3781 | ||
3781 | module_usb_driver(rndis_wlan_driver); | 3782 | module_usb_driver(rndis_wlan_driver); |
diff --git a/drivers/net/wireless/rt2x00/rt2500usb.c b/drivers/net/wireless/rt2x00/rt2500usb.c index 1de9c752c88b..d432e49ed6cd 100644 --- a/drivers/net/wireless/rt2x00/rt2500usb.c +++ b/drivers/net/wireless/rt2x00/rt2500usb.c | |||
@@ -1980,6 +1980,7 @@ static struct usb_driver rt2500usb_driver = { | |||
1980 | .disconnect = rt2x00usb_disconnect, | 1980 | .disconnect = rt2x00usb_disconnect, |
1981 | .suspend = rt2x00usb_suspend, | 1981 | .suspend = rt2x00usb_suspend, |
1982 | .resume = rt2x00usb_resume, | 1982 | .resume = rt2x00usb_resume, |
1983 | .disable_hub_initiated_lpm = 1, | ||
1983 | }; | 1984 | }; |
1984 | 1985 | ||
1985 | module_usb_driver(rt2500usb_driver); | 1986 | module_usb_driver(rt2500usb_driver); |
diff --git a/drivers/net/wireless/rt2x00/rt2800usb.c b/drivers/net/wireless/rt2x00/rt2800usb.c index 001735f7a661..d60d4e2772e6 100644 --- a/drivers/net/wireless/rt2x00/rt2800usb.c +++ b/drivers/net/wireless/rt2x00/rt2800usb.c | |||
@@ -1293,6 +1293,7 @@ static struct usb_driver rt2800usb_driver = { | |||
1293 | .disconnect = rt2x00usb_disconnect, | 1293 | .disconnect = rt2x00usb_disconnect, |
1294 | .suspend = rt2x00usb_suspend, | 1294 | .suspend = rt2x00usb_suspend, |
1295 | .resume = rt2x00usb_resume, | 1295 | .resume = rt2x00usb_resume, |
1296 | .disable_hub_initiated_lpm = 1, | ||
1296 | }; | 1297 | }; |
1297 | 1298 | ||
1298 | module_usb_driver(rt2800usb_driver); | 1299 | module_usb_driver(rt2800usb_driver); |
diff --git a/drivers/net/wireless/rt2x00/rt73usb.c b/drivers/net/wireless/rt2x00/rt73usb.c index e477a964081d..f813de6cd1b7 100644 --- a/drivers/net/wireless/rt2x00/rt73usb.c +++ b/drivers/net/wireless/rt2x00/rt73usb.c | |||
@@ -2526,6 +2526,7 @@ static struct usb_driver rt73usb_driver = { | |||
2526 | .disconnect = rt2x00usb_disconnect, | 2526 | .disconnect = rt2x00usb_disconnect, |
2527 | .suspend = rt2x00usb_suspend, | 2527 | .suspend = rt2x00usb_suspend, |
2528 | .resume = rt2x00usb_resume, | 2528 | .resume = rt2x00usb_resume, |
2529 | .disable_hub_initiated_lpm = 1, | ||
2529 | }; | 2530 | }; |
2530 | 2531 | ||
2531 | module_usb_driver(rt73usb_driver); | 2532 | module_usb_driver(rt73usb_driver); |
diff --git a/drivers/net/wireless/rtl818x/rtl8187/dev.c b/drivers/net/wireless/rtl818x/rtl8187/dev.c index cf53ac9d6f23..c2d2a21dd452 100644 --- a/drivers/net/wireless/rtl818x/rtl8187/dev.c +++ b/drivers/net/wireless/rtl818x/rtl8187/dev.c | |||
@@ -1662,6 +1662,7 @@ static struct usb_driver rtl8187_driver = { | |||
1662 | .id_table = rtl8187_table, | 1662 | .id_table = rtl8187_table, |
1663 | .probe = rtl8187_probe, | 1663 | .probe = rtl8187_probe, |
1664 | .disconnect = __devexit_p(rtl8187_disconnect), | 1664 | .disconnect = __devexit_p(rtl8187_disconnect), |
1665 | .disable_hub_initiated_lpm = 1, | ||
1665 | }; | 1666 | }; |
1666 | 1667 | ||
1667 | module_usb_driver(rtl8187_driver); | 1668 | module_usb_driver(rtl8187_driver); |
diff --git a/drivers/net/wireless/rtlwifi/rtl8192cu/sw.c b/drivers/net/wireless/rtlwifi/rtl8192cu/sw.c index 82c85286ab2e..0face8b7e524 100644 --- a/drivers/net/wireless/rtlwifi/rtl8192cu/sw.c +++ b/drivers/net/wireless/rtlwifi/rtl8192cu/sw.c | |||
@@ -372,6 +372,7 @@ static struct usb_driver rtl8192cu_driver = { | |||
372 | #ifdef CONFIG_AUTOSUSPEND | 372 | #ifdef CONFIG_AUTOSUSPEND |
373 | .supports_autosuspend = 1, | 373 | .supports_autosuspend = 1, |
374 | #endif | 374 | #endif |
375 | .disable_hub_initiated_lpm = 1, | ||
375 | }; | 376 | }; |
376 | 377 | ||
377 | module_usb_driver(rtl8192cu_driver); | 378 | module_usb_driver(rtl8192cu_driver); |
diff --git a/drivers/net/wireless/zd1201.c b/drivers/net/wireless/zd1201.c index a66b93b7ff9a..48273dd05b63 100644 --- a/drivers/net/wireless/zd1201.c +++ b/drivers/net/wireless/zd1201.c | |||
@@ -1905,6 +1905,7 @@ static struct usb_driver zd1201_usb = { | |||
1905 | .id_table = zd1201_table, | 1905 | .id_table = zd1201_table, |
1906 | .suspend = zd1201_suspend, | 1906 | .suspend = zd1201_suspend, |
1907 | .resume = zd1201_resume, | 1907 | .resume = zd1201_resume, |
1908 | .disable_hub_initiated_lpm = 1, | ||
1908 | }; | 1909 | }; |
1909 | 1910 | ||
1910 | module_usb_driver(zd1201_usb); | 1911 | module_usb_driver(zd1201_usb); |
diff --git a/drivers/net/wireless/zd1211rw/zd_usb.c b/drivers/net/wireless/zd1211rw/zd_usb.c index f766b3e67c6d..af83c43bcdb1 100644 --- a/drivers/net/wireless/zd1211rw/zd_usb.c +++ b/drivers/net/wireless/zd1211rw/zd_usb.c | |||
@@ -1542,6 +1542,7 @@ static struct usb_driver driver = { | |||
1542 | .disconnect = disconnect, | 1542 | .disconnect = disconnect, |
1543 | .pre_reset = pre_reset, | 1543 | .pre_reset = pre_reset, |
1544 | .post_reset = post_reset, | 1544 | .post_reset = post_reset, |
1545 | .disable_hub_initiated_lpm = 1, | ||
1545 | }; | 1546 | }; |
1546 | 1547 | ||
1547 | struct workqueue_struct *zd_workqueue; | 1548 | struct workqueue_struct *zd_workqueue; |