All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH][Resend] USB: Remove test for NULL that'll never happen in usb_disconnect()
@ 2011-08-01 22:03 Jesper Juhl
  2011-08-01 22:10 ` Sarah Sharp
  0 siblings, 1 reply; 4+ messages in thread
From: Jesper Juhl @ 2011-08-01 22:03 UTC (permalink / raw)
  To: linux-kernel
  Cc: Alan Stern, linux-usb, Greg Kroah-Hartman, Sarah Sharp,
	Andiry Xu, Luben Tuikov

In drivers/usb/core/hub.c::usb_disconnect(), 'udev' will never be
NULL, so remove the test and printing of debug message.

Signed-off-by: Jesper Juhl <jj@chaosbits.net>
Acked-by: Alan Stern <stern@rowland.harvard.edu>
---
 drivers/usb/core/hub.c |    5 -----
 1 files changed, 0 insertions(+), 5 deletions(-)

diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
index a428aa0..99fff6b 100644
--- a/drivers/usb/core/hub.c
+++ b/drivers/usb/core/hub.c
@@ -1636,11 +1636,6 @@ void usb_disconnect(struct usb_device **pdev)
 	int			i;
 	struct usb_hcd		*hcd = bus_to_hcd(udev->bus);
 
-	if (!udev) {
-		pr_debug ("%s nodev\n", __func__);
-		return;
-	}
-
 	/* mark the device as inactive, so any further urb submissions for
 	 * this device (and any of its children) will fail immediately.
 	 * this quiesces everything except pending urbs.
-- 
1.7.6


-- 
Jesper Juhl <jj@chaosbits.net>       http://www.chaosbits.net/
Don't top-post http://www.catb.org/jargon/html/T/top-post.html
Plain text mails only, please.


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

* Re: [PATCH][Resend] USB: Remove test for NULL that'll never happen in usb_disconnect()
  2011-08-01 22:03 [PATCH][Resend] USB: Remove test for NULL that'll never happen in usb_disconnect() Jesper Juhl
@ 2011-08-01 22:10 ` Sarah Sharp
  2011-08-01 22:24   ` Greg KH
  0 siblings, 1 reply; 4+ messages in thread
From: Sarah Sharp @ 2011-08-01 22:10 UTC (permalink / raw)
  To: Jesper Juhl
  Cc: linux-kernel, Alan Stern, linux-usb, Greg Kroah-Hartman,
	Andiry Xu, Luben Tuikov

Hi Jesper,

You probably need to send this directly to Greg, instead of to the list.
I'm not sure if Greg's still on vacation, so resend in a couple days if
you don't hear from him.

Sarah Sharp

On Tue, Aug 02, 2011 at 12:03:24AM +0200, Jesper Juhl wrote:
> In drivers/usb/core/hub.c::usb_disconnect(), 'udev' will never be
> NULL, so remove the test and printing of debug message.
> 
> Signed-off-by: Jesper Juhl <jj@chaosbits.net>
> Acked-by: Alan Stern <stern@rowland.harvard.edu>
> ---
>  drivers/usb/core/hub.c |    5 -----
>  1 files changed, 0 insertions(+), 5 deletions(-)
> 
> diff --git a/drivers/usb/core/hub.c b/drivers/usb/core/hub.c
> index a428aa0..99fff6b 100644
> --- a/drivers/usb/core/hub.c
> +++ b/drivers/usb/core/hub.c
> @@ -1636,11 +1636,6 @@ void usb_disconnect(struct usb_device **pdev)
>  	int			i;
>  	struct usb_hcd		*hcd = bus_to_hcd(udev->bus);
>  
> -	if (!udev) {
> -		pr_debug ("%s nodev\n", __func__);
> -		return;
> -	}
> -
>  	/* mark the device as inactive, so any further urb submissions for
>  	 * this device (and any of its children) will fail immediately.
>  	 * this quiesces everything except pending urbs.
> -- 
> 1.7.6
> 
> 
> -- 
> Jesper Juhl <jj@chaosbits.net>       http://www.chaosbits.net/
> Don't top-post http://www.catb.org/jargon/html/T/top-post.html
> Plain text mails only, please.
> 
> --
> To unsubscribe from this list: send the line "unsubscribe linux-usb" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html

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

* Re: [PATCH][Resend] USB: Remove test for NULL that'll never happen in usb_disconnect()
  2011-08-01 22:10 ` Sarah Sharp
@ 2011-08-01 22:24   ` Greg KH
  2011-08-01 22:24     ` Greg KH
  0 siblings, 1 reply; 4+ messages in thread
From: Greg KH @ 2011-08-01 22:24 UTC (permalink / raw)
  To: Sarah Sharp
  Cc: Jesper Juhl, linux-kernel, Alan Stern, linux-usb, Andiry Xu,
	Luben Tuikov

On Mon, Aug 01, 2011 at 03:10:19PM -0700, Sarah Sharp wrote:
> Hi Jesper,
> 
> You probably need to send this directly to Greg, instead of to the list.

He copied me :)

> I'm not sure if Greg's still on vacation, so resend in a couple days if
> you don't hear from him.

I'm back, but digging out from a huge load of todo work, so it will be a
while before getting to non-3.1-bugfix patches (unlike this one.)

thanks,

greg k-h

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

* Re: [PATCH][Resend] USB: Remove test for NULL that'll never happen in usb_disconnect()
  2011-08-01 22:24   ` Greg KH
@ 2011-08-01 22:24     ` Greg KH
  0 siblings, 0 replies; 4+ messages in thread
From: Greg KH @ 2011-08-01 22:24 UTC (permalink / raw)
  To: Sarah Sharp
  Cc: Jesper Juhl, linux-kernel, Alan Stern, linux-usb, Andiry Xu,
	Luben Tuikov

On Mon, Aug 01, 2011 at 03:24:05PM -0700, Greg KH wrote:
> On Mon, Aug 01, 2011 at 03:10:19PM -0700, Sarah Sharp wrote:
> > Hi Jesper,
> > 
> > You probably need to send this directly to Greg, instead of to the list.
> 
> He copied me :)
> 
> > I'm not sure if Greg's still on vacation, so resend in a couple days if
> > you don't hear from him.
> 
> I'm back, but digging out from a huge load of todo work, so it will be a
> while before getting to non-3.1-bugfix patches (unlike this one.)

s/unlike/like/


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

end of thread, other threads:[~2011-08-01 22:25 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-08-01 22:03 [PATCH][Resend] USB: Remove test for NULL that'll never happen in usb_disconnect() Jesper Juhl
2011-08-01 22:10 ` Sarah Sharp
2011-08-01 22:24   ` Greg KH
2011-08-01 22:24     ` Greg KH

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.