Re: [PATCH, RFC] usb devio: Use get_user() instead of __get_user()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 19 Jul 2009 23:24:20 -0700, Greg KH <gregkh@xxxxxxx> wrote:

> Pete would know best, as he added this code way back in 2005 in commit
> c36fc889.

This may be an instance of cargo cult programming on my part
or just a thinko.

> Pete, any thoughts on the patch below?

> > +++ linux-2.6/drivers/usb/core/devio.c
> > @@ -1531,21 +1531,21 @@ static int proc_ioctl_default(struct dev

> >  	uioc = compat_ptr((long)arg);
> >  	if (get_user(ctrl.ifno, &uioc->ifno) ||
> >  	    get_user(ctrl.ioctl_code, &uioc->ioctl_code) ||
> > -	    __get_user(udata, &uioc->data))
> > +	    get_user(udata, &uioc->data))
> >  		return -EFAULT;
> >  	ctrl.data = compat_ptr(udata);

I don't see why not.

-- Pete
--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux