linux-usb.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Oliver Neukum <oneukum@suse.com>
To: Alan Stern <stern@rowland.harvard.edu>, Greg KH <greg@kroah.com>,
	Mayuresh Kulkarni <mkulkarni@opensource.cirrus.com>
Cc: USB list <linux-usb@vger.kernel.org>
Subject: Re: [PATCH] usbfs: Add ioctls for runtime power management
Date: Wed, 07 Aug 2019 09:37:45 +0200	[thread overview]
Message-ID: <1565163465.8136.36.camel@suse.com> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1908061542140.1571-100000@iolanthe.rowland.org>

Am Dienstag, den 06.08.2019, 15:46 -0400 schrieb Alan Stern:
> +static int proc_wait_for_resume(struct usb_dev_state *ps)
> +{
> +       int ret;
> +
> +       usb_unlock_device(ps->dev);
> +       ret = wait_event_interruptible(ps->wait_for_resume,
> +                       READ_ONCE(ps->not_yet_resumed) == 0);
> +       usb_lock_device(ps->dev);
> +
> +       if (ret != 0)
> +               return ret;
> +       return proc_forbid_suspend(ps);

One nitpick, this seems to return raw -ERESTARTSYS in the interrupt
case. Should it?

	Regards
		Oliver


  reply	other threads:[~2019-08-07  7:37 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-08-06 19:46 [PATCH] usbfs: Add ioctls for runtime power management Alan Stern
2019-08-07  7:37 ` Oliver Neukum [this message]
2019-08-07 14:29   ` [PATCH v2] " Alan Stern
2019-08-08 15:37     ` Greg KH

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=1565163465.8136.36.camel@suse.com \
    --to=oneukum@suse.com \
    --cc=greg@kroah.com \
    --cc=linux-usb@vger.kernel.org \
    --cc=mkulkarni@opensource.cirrus.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).