[U-Boot] checkpatch compliance

Gerlando Falauto gerlando.falauto at keymile.com
Fri Nov 18 08:25:05 CET 2011


On 11/17/2011 09:54 PM, Wolfgang Denk wrote:
> Dear Gerlando Falauto,
>
> In message<4EC56A2E.2000708 at keymile.com>  you wrote:
>>
>> What is wrong with something like:
>>
>> ERROR: do not initialise statics to 0 or NULL
>> #35: FILE: serial.c:32:
>> +static struct serial_device *serial_devices = NULL;
 >
> Why?  Why don't you just follow the advise and remove the redundant
> initializers?

Sorry, I didn't realize it had to do with redundancy, the message was 
somewhat unclear to me.
I thought the complaint meant something like "you should initialize 
statics somewhere else", which, in fact, would not make any sense, in 
ANY context.

I personally would prefer an explicit initialization though, like mama 
told me to ALWAYS do... wash your hands before you eat, brush your teeth 
after. (I also like to believe I'm not the only one who had never read 
ISO/IEC 9899 §6.7.8#2). :-)

Thanks,
Gerlando Falauto


More information about the U-Boot mailing list