[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Test patch for sleep on Aluminium PowerBooks



On Thu, Oct 28, 2004 at 08:38:52AM +1000, Benjamin Herrenschmidt wrote:
> On Wed, 2004-10-27 at 16:10 +0200, Sjoerd Simons wrote:
> 
> > the usb_bus_type struct doesn't have the rwsem member anymore, so that
> > doesn't compile.. 
> 
> --- linux-2.6.9/drivers/usb/core/hub.c.susp     2004-10-27 17:30:39.796999176 +0100
> +++ linux-2.6.9/drivers/usb/core/hub.c  2004-10-27 17:31:49.991979112 +0100
> @@ -1527,12 +1527,12 @@ static int __usb_suspend_device (struct 
>                          * even for drivers that can't suspend.
>                          */
>                         if (!driver->suspend || state > PM_SUSPEND_MEM) {
> -#if 1
> +#if 0
>                                 dev_warn(&intf->dev, "resume is unsafe!\n");
>  #else
> -                               down_write(&usb_bus_type.rwsem);
> +                               down_write(&usb_bus_type.subsys.rwsem);
>                                 device_release_driver(&intf->dev);
> -                               up_write(&usb_bus_type.rwsem);
> +                               up_write(&usb_bus_type.subsys.rwsem);
>  #endif
>                         }
>                 }

That worked once and oopsed/deadlocked another time.. I've made some webcam
shots of the oops[0]. Sorry for the bad quality.

  Sjoerd
0: http://fire.luon.net/~sjoerd/pb-oops/
-- 
We are governed not by armies and police but by ideas.
		-- Mona Caird, 1892



Reply to: