All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jiri Slaby <jirislaby@gmail.com>
To: Greg KH <greg@kroah.com>
Cc: David Brownell <david-b@pacbell.net>,
	Mattia Dongili <malattia@linux.it>,
	Jiri Slaby <jirislaby@gmail.com>,
	linux-pm@osdl.org, linux-kernel@vger.kernel.org,
	linux-usb-devel@lists.sourceforge.net
Subject: Re: [PATCH] get USB suspend to work again on 2.6.17-mm1
Date: Thu, 22 Jun 2006 23:26:26 +0159	[thread overview]
Message-ID: <449B0B19.9000901@gmail.com> (raw)
In-Reply-To: <20060622202952.GA14135@kroah.com>

Greg KH napsal(a):
> Mattai and Jiri, can you try the patch below to see if it fixes the USB
> suspend problem you are seeing with 2.6.17-mm1?
> 
> David, we really should not be caring about what the children of a USB
> device is doing here, as who knows what type of "device" might hang off
> of a struct usb_device.  This patch is just a band-aid around this area,
> until Alan's patches fix up everything "properly" :)
> 
> thanks,
> 
> greg k-h
> 
> -----------------------------
> Subject: USB: get USB suspend to work again
> 
> Yeah, it's a hack, but it is only temporary until Alan's patches
> reworking this area make it in.  We really should not care what devices
> below us are doing, especially when we do not really know what type of
> devices they are.  This patch relies on the fact that the endpoint
> devices do not have a driver assigned to us.
> 
> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
> 
> ---
>  drivers/usb/core/usb.c |    2 ++
>  1 file changed, 2 insertions(+)
> 
> --- gregkh-2.6.orig/drivers/usb/core/usb.c
> +++ gregkh-2.6/drivers/usb/core/usb.c
> @@ -991,6 +991,8 @@ void usb_buffer_unmap_sg (struct usb_dev
>  
>  static int verify_suspended(struct device *dev, void *unused)
>  {
> +	if (dev->driver == NULL)
> +		return 0;
>  	return (dev->power.power_state.event == PM_EVENT_ON) ? -EBUSY : 0;
>  }
>  

Yeah, it works just fine.

regards,
-- 
Jiri Slaby         www.fi.muni.cz/~xslaby
\_.-^-._   jirislaby@gmail.com   _.-^-._/
B67499670407CE62ACC8 22A032CC55C339D47A7E

WARNING: multiple messages have this Message-ID (diff)
From: Jiri Slaby <jirislaby@gmail.com>
To: Greg KH <greg@kroah.com>
Cc: Mattia Dongili <malattia@linux.it>,
	Jiri Slaby <jirislaby@gmail.com>,
	Alan Stern <stern@rowland.harvard.edu>,
	David Brownell <david-b@pacbell.net>,
	Andrew Morton <akpm@osdl.org>,
	linux-kernel@vger.kernel.org,
	linux-usb-devel@lists.sourceforge.net, linux-pm@osdl.org,
	pavel@suse.cz
Subject: Re: [PATCH] get USB suspend to work again on 2.6.17-mm1
Date: Thu, 22 Jun 2006 23:26:26 +0159	[thread overview]
Message-ID: <449B0B19.9000901@gmail.com> (raw)
In-Reply-To: <20060622202952.GA14135@kroah.com>

Greg KH napsal(a):
> Mattai and Jiri, can you try the patch below to see if it fixes the USB
> suspend problem you are seeing with 2.6.17-mm1?
> 
> David, we really should not be caring about what the children of a USB
> device is doing here, as who knows what type of "device" might hang off
> of a struct usb_device.  This patch is just a band-aid around this area,
> until Alan's patches fix up everything "properly" :)
> 
> thanks,
> 
> greg k-h
> 
> -----------------------------
> Subject: USB: get USB suspend to work again
> 
> Yeah, it's a hack, but it is only temporary until Alan's patches
> reworking this area make it in.  We really should not care what devices
> below us are doing, especially when we do not really know what type of
> devices they are.  This patch relies on the fact that the endpoint
> devices do not have a driver assigned to us.
> 
> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
> 
> ---
>  drivers/usb/core/usb.c |    2 ++
>  1 file changed, 2 insertions(+)
> 
> --- gregkh-2.6.orig/drivers/usb/core/usb.c
> +++ gregkh-2.6/drivers/usb/core/usb.c
> @@ -991,6 +991,8 @@ void usb_buffer_unmap_sg (struct usb_dev
>  
>  static int verify_suspended(struct device *dev, void *unused)
>  {
> +	if (dev->driver == NULL)
> +		return 0;
>  	return (dev->power.power_state.event == PM_EVENT_ON) ? -EBUSY : 0;
>  }
>  

Yeah, it works just fine.

regards,
-- 
Jiri Slaby         www.fi.muni.cz/~xslaby
\_.-^-._   jirislaby@gmail.com   _.-^-._/
B67499670407CE62ACC8 22A032CC55C339D47A7E


  reply	other threads:[~2006-06-22 21:27 UTC|newest]

Thread overview: 44+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-06-22 20:29 [PATCH] get USB suspend to work again on 2.6.17-mm1 Greg KH
2006-06-22 21:27 ` Jiri Slaby [this message]
2006-06-22 21:27   ` Jiri Slaby
2006-06-22 21:28 ` Mattia Dongili
2006-06-22 21:28   ` Mattia Dongili
2006-06-22 21:34 ` Mattia Dongili
2006-06-22 21:34   ` Mattia Dongili
2006-06-22 23:24 ` David Brownell
2006-06-22 23:24   ` David Brownell
2006-06-22 23:51   ` Greg KH
2006-06-22 23:51     ` Greg KH
2006-06-23  2:45     ` Alan Stern
2006-06-23  2:45       ` Alan Stern
2006-06-23  4:26       ` Greg KH
2006-06-23  4:26         ` Greg KH
2006-06-23 14:28         ` Alan Stern
2006-06-23 14:28           ` Alan Stern
2006-06-23  3:34     ` David Brownell
2006-06-23  3:34       ` David Brownell
2006-06-23  4:24       ` Greg KH
2006-06-23  4:24         ` Greg KH
2006-06-23 14:51         ` Alan Stern
2006-06-23 14:51           ` Alan Stern
2006-06-23 15:38           ` David Brownell
2006-06-23 15:38             ` [linux-usb-devel] " David Brownell
2006-06-26 23:57           ` Greg KH
2006-06-26 23:57             ` Greg KH
2006-06-27  2:04             ` David Brownell
2006-06-27  2:04               ` David Brownell
2006-06-27 15:24               ` Alan Stern
2006-06-27 15:24                 ` Alan Stern
2006-06-27 23:28                 ` Greg KH
2006-06-27 23:28                   ` Greg KH
2006-06-27 23:26               ` Greg KH
2006-06-27 23:26                 ` Greg KH
2006-06-27  9:03             ` Pavel Machek
2006-06-27  9:03               ` Pavel Machek
2006-06-27 17:38               ` David Brownell
2006-06-27 23:20                 ` Greg KH
2006-06-27 23:20                   ` Greg KH
2006-06-25  2:42       ` [linux-pm] " Jim Gettys
2006-06-25  2:42         ` Jim Gettys
2006-06-25  4:32         ` David Brownell
2006-06-25  4:32           ` David Brownell

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=449B0B19.9000901@gmail.com \
    --to=jirislaby@gmail.com \
    --cc=david-b@pacbell.net \
    --cc=greg@kroah.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-pm@osdl.org \
    --cc=linux-usb-devel@lists.sourceforge.net \
    --cc=malattia@linux.it \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.