public inbox for kernel-janitors@vger.kernel.org
 help / color / mirror / Atom feed
* [patch] USB: Checking the wrong variable in usb_disable_lpm()
@ 2012-05-22 17:54 Dan Carpenter
  2012-05-22 20:49 ` Sarah Sharp
  0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2012-05-22 17:54 UTC (permalink / raw)
  To: kernel-janitors

We check "u1_params" instead of checking "u2_params".

Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
---
Static checker stuff, not tested.

diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
index 04fb834..25a7422 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
@@ -3379,7 +3379,7 @@ int usb_disable_lpm(struct usb_device *udev)
 		return 0;
 
 	udev->lpm_disable_count++;
-	if ((udev->u1_params.timeout = 0 && udev->u1_params.timeout = 0))
+	if ((udev->u1_params.timeout = 0 && udev->u2_params.timeout = 0))
 		return 0;
 
 	/* If LPM is enabled, attempt to disable it. */

^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2012-05-22 20:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-05-22 17:54 [patch] USB: Checking the wrong variable in usb_disable_lpm() Dan Carpenter
2012-05-22 20:49 ` Sarah Sharp

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox