From: Micha Feigin <michf@post.tau.ac.il>
To: linux-kernel@vger.kernel.org
Subject: Re: laptop mode in 2.4.24
Date: Sat, 21 Feb 2004 06:02:39 +0200 [thread overview]
Message-ID: <20040221040239.GH18007@luna.mooo.com> (raw)
In-Reply-To: <87vfm136lu.fsf@ceramic.fifi.org>
On Fri, Feb 20, 2004 at 11:15:25AM -0800, Philippe Troin wrote:
> Kiko Piris <kernel@pirispons.net> writes:
>
> > On 20/02/2004 at 12:32, Cristiano De Michele wrote:
> >
> > > that is only journaling is writing to my HD
> > > and anyway every minute more or less something
> > > gets written to HD preventing it from being spinned down
> >
> > IIRC, laptop-mode included in mainline 2.4 does not reset commit
> > interval of ext3 filesystems (as surely did the patch you applied to
> > older kernels).
> >
Yes, there was a bug with the version included in the official kernel
that it updates the value in the wrong place.
> > You need to remount your filesystems with appropate commit option. You
> > can see the updated control script that's in 2.6.*-mm* trees.
>
There is one problem with the commit option that you have to reset the
default option manually because there is currently no reset option (you
need to change the script to do a commit=30 when leaving laptop mode).
> Or use this patch...
>
The problem with this patch is that it overrides the built in commit
option that existed before the laptop mode patch was introduced.
> diff -ruN linux-2.4.24.orig/fs/jbd/transaction.c linux-2.4.24/fs/jbd/transaction.c
> --- linux-2.4.24.orig/fs/jbd/transaction.c Fri Nov 28 10:26:21 2003
> +++ linux-2.4.24/fs/jbd/transaction.c Mon Jan 12 12:01:54 2004
> @@ -56,7 +56,11 @@
> transaction->t_journal = journal;
> transaction->t_state = T_RUNNING;
> transaction->t_tid = journal->j_transaction_sequence++;
> - transaction->t_expires = jiffies + journal->j_commit_interval;
> + /*
> + * have to do it here, otherwise changed age_buffers since boot
> + * wont have any effect
> + */
> + transaction->t_expires = jiffies + get_buffer_flushtime();
> INIT_LIST_HEAD(&transaction->t_jcb);
>
> /* Set up the commit timer for the new transaction. */
>
> Phil.
next prev parent reply other threads:[~2004-02-21 4:03 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2004-02-20 11:32 laptop mode in 2.4.24 Cristiano De Michele
2004-02-20 13:42 ` Kiko Piris
2004-02-20 19:15 ` Philippe Troin
2004-02-21 4:02 ` Micha Feigin [this message]
[not found] ` <20040221182921.GF1162@laptop.localdomain.>
2004-02-24 1:46 ` Micha Feigin
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=20040221040239.GH18007@luna.mooo.com \
--to=michf@post.tau.ac.il \
--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