From: Pavel Machek <pavel@suse.cz>
To: Patrick Mochel <mochel@osdl.org>
Cc: Linux usb mailing list <linux-usb-devel@lists.sourceforge.net>,
kernel list <linux-kernel@vger.kernel.org>
Subject: [PATCH] Re: Driver model problems in -test5: usb this time
Date: Wed, 10 Sep 2003 02:19:56 +0200 [thread overview]
Message-ID: <20030910001955.GF217@elf.ucw.cz> (raw)
In-Reply-To: <Pine.LNX.4.44.0309091628000.695-100000@cherise>
Hi!
> > > The latter two functions do not exist in -test5. It would helpful if you
> > > tried to reproduce with a virgin -test5. It would be courteous to state
> > > what patches you applied on top of the virgin -test5 kernel.
> >
> > Lot of them, but only "revert to -test3 swsusp" should be important
> > here.
>
> Then all bets are off. I cannot expect to reproduce the problems until you
> narrow down which patch causes the problem or verify that it appears on a
> standard kernel release.
Here's patch that should fix it. [First part of first hunk defitely
triggered twice during suspend, and made machine survive that.] Please
apply,
Pavel
--- clean/drivers/usb/core/usb.c 2003-09-09 12:45:35.000000000 +0200
+++ linux/drivers/usb/core/usb.c 2003-09-10 02:16:10.000000000 +0200
@@ -1429,9 +1429,11 @@
return 0;
intf = to_usb_interface(dev);
+ if (!dev->driver)
+ return 0;
driver = to_usb_driver(dev->driver);
- if (driver && driver->suspend)
+ if (driver->suspend)
return driver->suspend(intf, state);
return 0;
}
@@ -1446,9 +1448,11 @@
return 0;
intf = to_usb_interface(dev);
+ if (!dev->driver)
+ return 0;
driver = to_usb_driver(dev->driver);
- if (driver && driver->resume)
+ if (driver->resume)
return driver->resume(intf);
return 0;
}
--
When do you have a heart between your knees?
[Johanka's followup: and *two* hearts?]
next prev parent reply other threads:[~2003-09-10 0:23 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2003-09-09 12:29 Driver model problems in -test5: usb this time Pavel Machek
2003-09-09 15:57 ` Patrick Mochel
2003-09-09 23:01 ` Pavel Machek
2003-09-09 23:29 ` Patrick Mochel
2003-09-09 23:57 ` Pavel Machek
2003-09-10 0:19 ` Pavel Machek [this message]
2003-09-10 3:33 ` [linux-usb-devel] [PATCH] " Greg KH
2003-09-10 0:27 ` Pavel Machek
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=20030910001955.GF217@elf.ucw.cz \
--to=pavel@suse.cz \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-usb-devel@lists.sourceforge.net \
--cc=mochel@osdl.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox