Re: [PATCH v3] ata: libata-scsi: fix result type of ata_ioc32()

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

 



On 6/24/22 11:39 PM, Sergey Shtylyov wrote:

> While ata_ioc32() returns 'int', its result gets assigned to and compared
> with the 'unsigned long' variable 'val' in ata_sas_scsi_ioctl(), its only
> caller, which implies a problematic implicit cast (with sign extension).
> Fix this by returning 'bool' instead -- the implicit cast then implies
> zero extension which is OK.  Note that actually the object code doesn't
> change because ata_ioc32() is always inlined -- I can see the expected
> code changes with 'noinline')...

   Leftover paren, could this be fixed while applying?

> 
> Found by Linux Verification Center (linuxtesting.org) with the SVACE static
> analysis tool.
> 
> Signed-off-by: Sergey Shtylyov <s.shtylyov@xxxxxx>

[...]

MBR, Sergey



[Index of Archives]     [Linux Filesystems]     [Linux SCSI]     [Linux RAID]     [Git]     [Kernel Newbies]     [Linux Newbie]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Samba]     [Device Mapper]

  Powered by Linux