Re: [KJ] [PATCH] dm: uninitialize static variables

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

 



On Mon, Dec 05, 2005 at 01:28:00PM +0100, Nicolas Kaiser wrote:
> uninitialize static variables initialized to 0, to make them go
> to .bss instead of .data.

>  dm.c     |    4 ++--
>  kcopyd.c |    2 +-

diffstat -p1 ;-)

> --- a/drivers/md/dm.c
> +++ b/drivers/md/dm.c
> @@ -20,8 +20,8 @@
>
>  static const char *_name = DM_NAME;
>
> -static unsigned int major = 0;
> -static unsigned int _major = 0;
> +static unsigned int major; /* = 0 */
> +static unsigned int _major; /* = 0 */

Drop the comments. major goes into .bss. .bss is initialized to 0.

> --- a/drivers/md/kcopyd.c
> +++ b/drivers/md/kcopyd.c

> -static int kcopyd_clients = 0;
> +static int kcopyd_clients; /* = 0 */

--

dm-devel@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/dm-devel

[Index of Archives]     [DM Crypt]     [Fedora Desktop]     [ATA RAID]     [Fedora Marketing]     [Fedora Packaging]     [Fedora SELinux]     [Yosemite Discussion]     [KDE Users]     [Fedora Docs]

  Powered by Linux