Le vendredi 13 janvier 2017 17:48:50 UTC+1, Arnd Bergmann a écrit : > > On Fri, Jan 13, 2017 at 4:56 PM, Amelie DELAUNAY <[email protected] > <javascript:>> wrote: > > On 01/13/2017 04:32 PM, Arnd Bergmann wrote: > >> > >> Using the ~ operator on a BIT() constant results in a large 'unsigned > >> long' > >> constant that won't fit into an 'unsigned int' function argument on > 64-bit > >> architectures, resulting in a harmless build warning in x86 > allmodconfig: > >> > >> drivers/rtc/rtc-stm32.c: In function 'stm32_rtc_probe': > >> drivers/rtc/rtc-stm32.c:651:51: error: large integer implicitly > truncated > >> to unsigned type [-Werror=overflow] > >> regmap_update_bits(rtc->dbp, PWR_CR, PWR_CR_DBP, ~PWR_CR_DBP); > > > > I thought I would fix this warning by replacing all ~PWR_CR_DBP by 0, > > because the mask PWR_CR_DBP prevents other bits to be cleared. > > In this way, I avoid the ugly cast... > > Good idea, much nicer than mine! Can you send that patch? > > Arnd
If it can wait Monday, yes. Amelie -- You received this message because you are subscribed to "rtc-linux". Membership options at http://groups.google.com/group/rtc-linux . Please read http://groups.google.com/group/rtc-linux/web/checklist before submitting a driver. --- You received this message because you are subscribed to the Google Groups "rtc-linux" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
