From: Hin-Tak Leung <htl10@users.sourceforge.net>
To: Alan Jenkins <alan-jenkins@tuffmail.co.uk>,
Larry Finger <Larry.Finger@lwfinger.net>
Cc: Alan Stern <stern@rowland.harvard.edu>,
Bob Copeland <me@bobcopeland.com>,
linux-wireless@vger.kernel.org,
linux-pm@lists.linux-foundation.org,
USB list <linux-usb@vger.kernel.org>,
Herton Ronaldo Krzesinski <herton@mandriva.com.br>
Subject: Re: [linux-pm] rtl8187 usb wifi adaptor causes suspend hang
Date: Tue, 30 Dec 2008 18:05:16 +0000 (GMT) [thread overview]
Message-ID: <226846.55836.qm@web23108.mail.ird.yahoo.com> (raw)
In-Reply-To: <495A5FEC.5070608@lwfinger.net>
--- On Tue, 30/12/08, Larry Finger <Larry.Finger@lwfinger.net> wrote:
> From: Larry Finger <Larry.Finger@lwfinger.net>
> Subject: Re: [linux-pm] rtl8187 usb wifi adaptor causes suspend hang
> To: "Alan Jenkins" <alan-jenkins@tuffmail.co.uk>
> Cc: "Alan Stern" <stern@rowland.harvard.edu>, "Bob Copeland" <me@bobcopeland.com>, linux-wireless@vger.kernel.org, linux-pm@lists.linux-foundation.org, "USB list" <linux-usb@vger.kernel.org>, "Hin-Tak Leung" <htl10@users.sourceforge.net>, "Herton Ronaldo Krzesinski" <herton@mandriva.com.br>
> Date: Tuesday, 30 December, 2008, 5:52 PM
> Alan Jenkins wrote:
> > That won't fix hibernation though. The disconnect
> method can still get
> > called in resume from hibernation, before the
> workqueue gets unfrozen.
> > To be honest, I'm far more interested in
> suspend-to-disk than
> > suspend-to-ram.
>
> Does this patch fix your problem? It works here, but I only
> did one
> test. The patch is for wireless-testing.
BTW, there is already a bug on kernel bugzilla on this - maybe useful to
attach the patch to get the three people to test:
http://bugzilla.kernel.org/show_bug.cgi?id=11887
In fact I'll do this when I get back in a couple of hours. (am going
out soon...). I'll give this a try myself.
>
> Larry
>
>
> Index:
> wireless-testing/drivers/net/wireless/rtl818x/rtl8187_dev.c
> ===================================================================
> ---
> wireless-testing.orig/drivers/net/wireless/rtl818x/rtl8187_dev.c
> +++
> wireless-testing/drivers/net/wireless/rtl818x/rtl8187_dev.c
> @@ -1464,6 +1464,32 @@ static int __devinit
> rtl8187_probe(struc
> return err;
> }
>
> +#ifdef CONFIG_PM
> +
> +static int rtl8187_suspend(struct usb_interface *intf,
> pm_message_t
> state)
> +{
> + struct ieee80211_hw *dev = usb_get_intfdata(intf);
> + struct rtl8187_priv *priv;
> + int time;
> +
> + if (!dev)
> + return 0;
> +
> + priv = dev->priv;
> +
> + time =
> usb_wait_anchor_empty_timeout(&priv->anchored, 1000);
> + if (!time)
> + usb_kill_anchored_urbs(&priv->anchored);
> + return 0;
> +}
> +
> +static int rtl8187_resume(struct usb_interface *intf)
> +{
> + return 0;
> +}
> +
> +#endif /* CONFIG_PM */
> +
> static void __devexit rtl8187_disconnect(struct
> usb_interface *intf)
> {
> struct ieee80211_hw *dev = usb_get_intfdata(intf);
> @@ -1484,6 +1510,10 @@ static struct usb_driver
> rtl8187_driver
> .id_table = rtl8187_table,
> .probe = rtl8187_probe,
> .disconnect = __devexit_p(rtl8187_disconnect),
> +#ifdef CONFIG_PM
> + .suspend = rtl8187_suspend,
> + .resume = rtl8187_resume,
> +#endif /* CONFIG_PM */
> };
>
> static int __init rtl8187_init(void)
next prev parent reply other threads:[~2008-12-30 18:06 UTC|newest]
Thread overview: 29+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-12-30 10:51 rtl8187 usb wifi adaptor causes suspend hang Alan Jenkins
2008-12-30 13:10 ` Alan Jenkins
2008-12-30 15:45 ` [linux-pm] " Alan Stern
2008-12-30 16:45 ` Bob Copeland
2008-12-30 16:48 ` Alan Jenkins
2008-12-30 17:25 ` Alan Stern
2008-12-30 17:31 ` Alan Jenkins
2008-12-30 17:52 ` Larry Finger
2008-12-30 18:05 ` Hin-Tak Leung [this message]
2008-12-30 18:05 ` Oliver Neukum
2008-12-30 18:09 ` Larry Finger
2008-12-31 0:59 ` Hin-Tak Leung
2008-12-31 14:33 ` Alan Jenkins
2008-12-31 15:57 ` Bob Copeland
2008-12-31 17:10 ` Alan Jenkins
2008-12-31 17:16 ` Oliver Neukum
2008-12-31 19:33 ` Larry Finger
2008-12-31 23:00 ` Larry Finger
2008-12-31 23:26 ` Bob Copeland
2009-01-01 0:16 ` Alan Stern
2009-01-01 6:06 ` Hin-Tak Leung
2009-01-01 22:25 ` Alan Stern
2009-01-01 23:42 ` Hin-Tak Leung
2009-01-02 2:24 ` Alan Stern
2009-01-01 6:18 ` Hin-Tak Leung
2009-01-01 13:07 ` Alan Jenkins
2009-01-01 13:40 ` Stefanik Gábor
2009-01-01 14:39 ` Hin-Tak Leung
2009-01-01 16:38 ` Larry Finger
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=226846.55836.qm@web23108.mail.ird.yahoo.com \
--to=htl10@users.sourceforge.net \
--cc=Larry.Finger@lwfinger.net \
--cc=alan-jenkins@tuffmail.co.uk \
--cc=herton@mandriva.com.br \
--cc=linux-pm@lists.linux-foundation.org \
--cc=linux-usb@vger.kernel.org \
--cc=linux-wireless@vger.kernel.org \
--cc=me@bobcopeland.com \
--cc=stern@rowland.harvard.edu \
/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;
as well as URLs for NNTP newsgroup(s).