Re: [PATCH] media: v4l2-compat-ioctl32: simplify casts

2018-04-18 Thread Mauro Carvalho Chehab
Em Wed, 18 Apr 2018 11:57:13 +0300 Sakari Ailus escreveu: > Hi Mauro, > > On Tue, Apr 17, 2018 at 10:25:37AM -0400, Mauro Carvalho Chehab wrote: > > Making the cast right for get_user/put_user is not trivial, as > > it needs to ensure that the types are the correct ones. > > > > Improve it by u

Re: [PATCH] media: v4l2-compat-ioctl32: simplify casts

2018-04-18 Thread Sakari Ailus
Hi Mauro, On Tue, Apr 17, 2018 at 10:25:37AM -0400, Mauro Carvalho Chehab wrote: > Making the cast right for get_user/put_user is not trivial, as > it needs to ensure that the types are the correct ones. > > Improve it by using macros. > > Tested with vivid with: > $ sudo modprobe vivid no

[PATCH] media: v4l2-compat-ioctl32: simplify casts

2018-04-17 Thread Mauro Carvalho Chehab
Making the cast right for get_user/put_user is not trivial, as it needs to ensure that the types are the correct ones. Improve it by using macros. Tested with vivid with: $ sudo modprobe vivid no_error_inj=1 $ v4l2-compliance-32bits -a -s10 >32bits && v4l2-compliance-64bits -a -s