Re: Less strict requirement for USB_REQUEST ioctl

2015-08-10 Thread Theo de Raadt
> ludovic coues schreef op 2015-08-10 23:29: > > 2015-08-10 22:56 GMT+02:00 Martin Pieuchot : > >> On 30/07/15(Thu) 12:18, Ludovic Coues wrote: > >>> Right now, an USB_REQUEST ioctl will fail with an EBADF error if done > >>> on a device opened as read-only. With this patch, the ioctl will fail > >

Re: Less strict requirement for USB_REQUEST ioctl

2015-08-10 Thread Mark Kettenis
ludovic coues schreef op 2015-08-10 23:29: 2015-08-10 22:56 GMT+02:00 Martin Pieuchot : On 30/07/15(Thu) 12:18, Ludovic Coues wrote: Right now, an USB_REQUEST ioctl will fail with an EBADF error if done on a device opened as read-only. With this patch, the ioctl will fail only if the USB_REQUES

Re: Less strict requirement for USB_REQUEST ioctl

2015-08-10 Thread ludovic coues
2015-08-10 22:56 GMT+02:00 Martin Pieuchot : > On 30/07/15(Thu) 12:18, Ludovic Coues wrote: >> Right now, an USB_REQUEST ioctl will fail with an EBADF error if done >> on a device opened as read-only. With this patch, the ioctl will fail >> only if the USB_REQUEST is a write request. > > Do you nee

Re: Less strict requirement for USB_REQUEST ioctl

2015-08-10 Thread Martin Pieuchot
On 30/07/15(Thu) 12:18, Ludovic Coues wrote: > Right now, an USB_REQUEST ioctl will fail with an EBADF error if done > on a device opened as read-only. With this patch, the ioctl will fail > only if the USB_REQUEST is a write request. Do you need this to be able to use your usbdevs-like tool as a

Less strict requirement for USB_REQUEST ioctl

2015-07-30 Thread Ludovic Coues
Right now, an USB_REQUEST ioctl will fail with an EBADF error if done on a device opened as read-only. With this patch, the ioctl will fail only if the USB_REQUEST is a write request. Index: sys/dev/usb/usb.c === RCS file: /cvs/src/sys