lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Sat, 19 Apr 2008 18:12:45 +0200
From:	Pavel Machek <pavel@....cz>
To:	Marcel Holtmann <marcel@...tmann.org>
Cc:	akpm@...ux-foundation.org, hidave.darkstar@...il.com,
	linux-bluetooth@...r.kernel.org, netdev@...r.kernel.org
Subject: Re: [patch 1/3] hci_usb: do not initialize static variables to 0

On Fri 2008-04-18 23:04:57, Marcel Holtmann wrote:
> Hi Andrew,
>
>> hci_usb: do not initialize static variables to 0.
>>
>> Signed-off-by: Pavel Machek <pavel@...e.cz>
>> Cc: Marcel Holtmann <marcel@...tmann.org>
>> Cc: Dave Young <hidave.darkstar@...il.com>
>> Signed-off-by: Andrew Morton <akpm@...ux-foundation.org>
>> ---
>>
>> drivers/bluetooth/hci_usb.c |   14 +++++++-------
>> 1 file changed, 7 insertions(+), 7 deletions(-)
>>
>> diff -puN 
>> drivers/bluetooth/hci_usb.c~hci_usb-do-not-initialize-static-variables-to-0 
>> drivers/bluetooth/hci_usb.c
>> --- 
>> a/drivers/bluetooth/hci_usb.c~hci_usb-do-not-initialize-static-variables-to-0
>> +++ a/drivers/bluetooth/hci_usb.c
>> @@ -62,13 +62,13 @@
>> #define URB_ZERO_PACKET 0
>> #endif
>>
>> -static int ignore = 0;
>> -static int ignore_dga = 0;
>> -static int ignore_csr = 0;
>> -static int ignore_sniffer = 0;
>> -static int disable_scofix = 0;
>> -static int force_scofix = 0;
>> -static int reset = 0;
>> +static int ignore;
>> +static int ignore_dga;
>> +static int ignore_csr;
>> +static int ignore_sniffer;
>> +static int disable_scofix;
>> +static int force_scofix;
>> +static int reset;
>
> I know that some people don't like to do it and I agree, but in case of 
> module parameters, I prefer to have them clearly indicate what the default 
> value is. It is a lot easier to read for other people looking at the code. 
> So that one is a NAK from my side.

According to you noone should read this one, anyway :-)... and this
wastes space in vmlinux.
									Pavel	

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists