public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Philippe Troin <phil@fifi.org>
To: Kiko Piris <kernel@pirispons.net>
Cc: Cristiano De Michele <demichel@na.infn.it>, linux-kernel@vger.kernel.org
Subject: Re: laptop mode in 2.4.24
Date: 20 Feb 2004 11:15:25 -0800	[thread overview]
Message-ID: <87vfm136lu.fsf@ceramic.fifi.org> (raw)
In-Reply-To: <20040220134218.GA15112@fpirisp.portsdebalears.com>

[-- Attachment #1: Type: text/plain, Size: 582 bytes --]

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).
> 
> You need to remount your filesystems with appropate commit option. You
> can see the updated control script that's in 2.6.*-mm* trees.

Or use this patch...


[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: linux-2.4.24-09-laptop-mode.patch.bz2 --]
[-- Type: text/x-patch, Size: 690 bytes --]

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. */

[-- Attachment #3: Type: text/plain, Size: 7 bytes --]


Phil.

  reply	other threads:[~2004-02-20 19:44 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 [this message]
2004-02-21  4:02     ` Micha Feigin
     [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=87vfm136lu.fsf@ceramic.fifi.org \
    --to=phil@fifi.org \
    --cc=demichel@na.infn.it \
    --cc=kernel@pirispons.net \
    --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