Re: [PATCH] i2c: i2c-dev: Add __user annotation

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

 



On Thu, Jun 24, 2021 at 05:25:35PM +0200, Andreas Hecht wrote:
> Fix Sparse warnings:
> drivers/i2c/i2c-dev.c:546:19: warning: incorrect type in assignment (different address spaces)
> drivers/i2c/i2c-dev.c:549:53: warning: incorrect type in argument 2 (different address spaces)
> 
> compat_ptr() returns a pointer tagged __user which gets assigned to a
> pointer missing the __user annotation. The same pointer is passed to
> copy_from_user() as an argument where it is expected to have the __user
> annotation. Fix both by adding the __user annotation to the pointer.
> 
> Signed-off-by: Andreas Hecht <andreas.e.hecht@xxxxxxxxx>

Nice catch. Applied to for-current, thanks!

Attachment: signature.asc
Description: PGP signature


[Index of Archives]     [Linux GPIO]     [Linux SPI]     [Linux Hardward Monitoring]     [LM Sensors]     [Linux USB Devel]     [Linux Media]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux