Re: [PATCH] staging: comedi: dt282x: tidy up register bit defines

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

 



On Thursday 17 March 2016 10:10:40 H Hartley Sweeten wrote:
> Arnd Bergmann pointed out that gcc-6 warns about passing negative signed
> integer into swab16() due to the macro expansion of 'outw'.
> 
> It appears that the register map constants are causing the warnings.
> Actually, it might just be the (1 << 15) ones...
> 
> Convert all the constants as suggested by checkpatch.pl:
> CHECK: Prefer using the BIT macro
> 
> The BIT() macro will make all the constants explicitly 'unsigned', which
> helps to avoid the warning.
> 
> Fix the, unsused, DT2821_CHANCSR_PRESLA() macro. The "Present List
> Address" (PRESLA) bits in the CHANCSR register are read only. This
> define was meant to extract the bits from the read value.
> 
> Signed-off-by: H Hartley Sweeten <hsweeten@xxxxxxxxxxxxxxxxxxx>
> Reported-by: Arnd Bergmann <arnd@xxxxxxxx>
> Cc: Ian Abbott <abbotti@xxxxxxxxx>
> Cc: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
> 

Tested-by: Arnd Bergmann <arnd@xxxxxxxx>
_______________________________________________
devel mailing list
devel@xxxxxxxxxxxxxxxxxxxxxx
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel



[Index of Archives]     [Linux Driver Backports]     [DMA Engine]     [Linux GPIO]     [Linux SPI]     [Video for Linux]     [Linux USB Devel]     [Linux Coverity]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Yosemite Backpacking]
  Powered by Linux