public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Arnaldo Carvalho de Melo <acme@conectiva.com.br>
To: Bart Samwel <bart@samwel.tk>
Cc: Jens Axboe <axboe@suse.de>, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] laptop-mode for 2.6, version 3
Date: Thu, 25 Dec 2003 08:06:48 -0200	[thread overview]
Message-ID: <20031225100648.GB13382@conectiva.com.br> (raw)
In-Reply-To: <3FE9AFFC.2080302@samwel.tk>

Minor nitpicks below

Em Wed, Dec 24, 2003 at 04:25:48PM +0100, Bart Samwel escreveu:
> diff -baur --speed-large-files linux-2.6.0/mm/page-writeback.c linux-2.6.0-withlaptopmode/mm/page-writeback.c
> --- linux-2.6.0/mm/page-writeback.c	2003-12-24 05:19:46.000000000 +0100
> +++ linux-2.6.0-withlaptopmode/mm/page-writeback.c	2003-12-24 15:49:55.000000000 +0100
> @@ -28,6 +28,7 @@
>  #include <linux/smp.h>
>  #include <linux/sysctl.h>
>  #include <linux/cpu.h>
> +#include <linux/quotaops.h>
>  
>  /*
>   * The maximum number of pages to writeout in a single bdflush/kupdate
> @@ -81,6 +82,16 @@
>   */
>  int dirty_expire_centisecs = 30 * 100;
>  
> +/*
> + * Flag that makes the machine dump writes/reads and block dirtyings.
> + */
> +int block_dump = 0;
> +
> +/*
> + * Flag that puts the machine in "laptop mode".
> + */
> +int laptop_mode = 0;
> +

No need to set a global variable to 0, if you don't set it'll go to the
.bss section and the kernel will zero it out for us, and we reclaim 
2 * sizeof(int) from the kernel image. This is common style in most parts
of the kernel.

- Arnaldo

  reply	other threads:[~2003-12-25  9:56 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-12-24  5:33 [PATCH] laptop-mode for 2.6, version 2 Bart Samwel
2003-12-24 11:16 ` Jens Axboe
2003-12-24 15:25   ` [PATCH] laptop-mode for 2.6, version 3 Bart Samwel
2003-12-25 10:06     ` Arnaldo Carvalho de Melo [this message]
2003-12-25 15:12       ` [PATCH] laptop-mode for 2.6, version 4 + smart_spindown Bart Samwel
2003-12-25 17:04         ` John Bradford
2003-12-25 21:39           ` Bart Samwel
2003-12-27 10:57         ` A couple of questions about laptop-mode for 2.6, version 4 Kiko Piris
2003-12-24 13:51 ` [PATCH] laptop-mode for 2.6, version 2 Hugang
2003-12-24 14:24   ` Nikita Danilov
2003-12-25  2:59     ` Hugang
     [not found]       ` <16362.43831.569086.825899@laputa.namesys.com>
2003-12-25  9:40         ` Hugang
2003-12-25 10:27           ` Nikita Danilov
2003-12-25 10:59             ` Hugang

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20031225100648.GB13382@conectiva.com.br \
    --to=acme@conectiva.com.br \
    --cc=axboe@suse.de \
    --cc=bart@samwel.tk \
    --cc=linux-kernel@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox