From e1f12eb6ba6f1e74007eb01ed26fad7c5239d62b Mon Sep 17 00:00:00 2001 From: Sarah Sharp Date: Mon, 23 Apr 2012 10:08:51 -0700 Subject: 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 Cc: Marcel Holtmann Cc: Gustavo Padovan Cc: Johan Hedberg Cc: Hansjoerg Lipp Cc: Tilman Schmidt Cc: Karsten Keil Cc: Peter Korsgaard Cc: Jan Dumon Cc: Petko Manolov Cc: Steve Glendinning Cc: "John W. Linville" Cc: Kalle Valo Cc: "Luis R. Rodriguez" Cc: Jouni Malinen Cc: Vasanthakumar Thiagarajan Cc: Senthil Balasubramanian Cc: Christian Lamparter Cc: Brett Rudley Cc: Roland Vossen Cc: Arend van Spriel Cc: "Franky (Zhenhui) Lin" Cc: Kan Yan Cc: Dan Williams Cc: Jussi Kivilinna Cc: Ivo van Doorn Cc: Gertjan van Wingerde Cc: Helmut Schaa Cc: Herton Ronaldo Krzesinski Cc: Hin-Tak Leung Cc: Larry Finger Cc: Chaoming Li Cc: Daniel Drake Cc: Ulrich Kunitz Signed-off-by: Sarah Sharp --- drivers/isdn/hisax/hfc_usb.c | 1 + drivers/isdn/hisax/st5481_init.c | 1 + 2 files changed, 2 insertions(+) (limited to 'drivers/isdn/hisax') diff --git a/drivers/isdn/hisax/hfc_usb.c b/drivers/isdn/hisax/hfc_usb.c index 62c65bdefd8a..84f9c8103078 100644 --- a/drivers/isdn/hisax/hfc_usb.c +++ b/drivers/isdn/hisax/hfc_usb.c @@ -1568,6 +1568,7 @@ static struct usb_driver hfc_drv = { .id_table = hfcusb_idtab, .probe = hfc_usb_probe, .disconnect = hfc_usb_disconnect, + .disable_hub_initiated_lpm = 1, }; static void __exit diff --git a/drivers/isdn/hisax/st5481_init.c b/drivers/isdn/hisax/st5481_init.c index 100296e20dc0..54ef9e4f8cbc 100644 --- a/drivers/isdn/hisax/st5481_init.c +++ b/drivers/isdn/hisax/st5481_init.c @@ -182,6 +182,7 @@ static struct usb_driver st5481_usb_driver = { .probe = probe_st5481, .disconnect = disconnect_st5481, .id_table = st5481_ids, + .disable_hub_initiated_lpm = 1, }; static int __init st5481_usb_init(void) -- cgit v1.2.3