stable.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg KH <gregKH@linuxfoundation.org>
To: Alan Stern <stern@rowland.harvard.edu>
Cc: Oliver Neukum <oneukum@suse.com>,
	linux-usb@vger.kernel.org, stable@vger.kernel.org
Subject: Re: [PATCHv2] USB: usbfs: Filter flags passed in from user space
Date: Tue, 28 Nov 2017 15:02:16 +0100	[thread overview]
Message-ID: <20171128140216.GA29213@kroah.com> (raw)
In-Reply-To: <Pine.LNX.4.44L0.1711231050060.17242-100000@netrider.rowland.org>

On Thu, Nov 23, 2017 at 10:53:13AM -0500, Alan Stern wrote:
> On Thu, 23 Nov 2017, Oliver Neukum wrote:
> 
> > USBDEVFS_URB_ISO_ASAP must be accepted only for ISO endpoints.
> > Improve sanity checking.
> > 
> > Reported-by: andreyknvl@google.com
> 
> This should be
> 
> Reported-by: Andrey Konovalov <andreyknvl@google.com>
> 
> > Signed-off-by: Oliver Neukum <oneukum@suse.com>
> > CC: stable@vger.kernel.org
> > ---
> >  drivers/usb/core/devio.c | 16 ++++++++++------
> >  1 file changed, 10 insertions(+), 6 deletions(-)
> > 
> > diff --git a/drivers/usb/core/devio.c b/drivers/usb/core/devio.c
> > index 705c573d0257..701ddada389a 100644
> > --- a/drivers/usb/core/devio.c
> > +++ b/drivers/usb/core/devio.c
> > @@ -1442,14 +1442,18 @@ static int proc_do_submiturb(struct usb_dev_state *ps, struct usbdevfs_urb *uurb
> >  	int number_of_packets = 0;
> >  	unsigned int stream_id = 0;
> >  	void *buf;
> > -
> > -	if (uurb->flags & ~(USBDEVFS_URB_ISO_ASAP |
> > -				USBDEVFS_URB_SHORT_NOT_OK |
> > +	unsigned long mask =	USBDEVFS_URB_SHORT_NOT_OK |
> >  				USBDEVFS_URB_BULK_CONTINUATION |
> >  				USBDEVFS_URB_NO_FSBR |
> > -				USBDEVFS_URB_ZERO_PACKET |
> > -				USBDEVFS_URB_NO_INTERRUPT))
> > -		return -EINVAL;
> > +				USBDEVFS_URB_ZERO_PACKET | 
> 
> Extra whitespace at end of line (doesn't checkpatch.pl catch this)?

I'll go edit it by hand...

      reply	other threads:[~2017-11-28 14:02 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-11-23 15:39 [PATCHv2] USB: usbfs: Filter flags passed in from user space Oliver Neukum
2017-11-23 15:53 ` Alan Stern
2017-11-28 14:02   ` Greg KH [this message]

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=20171128140216.GA29213@kroah.com \
    --to=gregkh@linuxfoundation.org \
    --cc=linux-usb@vger.kernel.org \
    --cc=oneukum@suse.com \
    --cc=stable@vger.kernel.org \
    --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).