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  linux-hardening  linux-cve-announce  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:	Thu, 30 Jul 2009 12:00:35 -0600
From:	Andreas Dilger <adilger@....com>
To:	Jan Kara <jack@...e.cz>
Cc:	linux-ext4@...r.kernel.org, "Theodore Ts'o" <tytso@....edu>,
	Alex Zhuravlev <Alex.Zhuravlev@....com>
Subject: Re: [PATCH] JBD2: round commit timer up to avoid uncommitted
	transaction

On Jul 30, 2009  19:47 +0200, Jan Kara wrote:
> > jbd and jbd2 fixes: fix jiffie rounding in jbd commit timer setup code.
> > Rounding down could cause the timer to be fired before the corresponding
> > transaction has expired.  That transaction can stay not committed forever if
> > no new transaction is created or expicit sync/umount happens.
> > 
> > Signed-off-by: Alex Zhuravlev (Tomas) <alex.zhuravlev@....com>
> > Signed-off-by: Andreas Dilger <adilger@....com>
>
>   Looks fine. You can add:
> Acked-by: Jan Kara <jack@...e.cz>
>   How about a similar JBD fix?

Index: linux-2.6.27.21-0.1/fs/jbd/transaction.c
===================================================================
--- linux-2.6.27.21-0.1.orig/fs/jbd/transaction.c	2009-06-10 11:11:41.000000000 -0600
+++ linux-2.6.27.21-0.1/fs/jbd/transaction.c	2009-06-10 11:12:32.000000000 -0600
@@ -54,7 +54,7 @@
 	spin_lock_init(&transaction->t_inode_list);
 
 	/* Set up the commit timer for the new transaction. */
-	journal->j_commit_timer.expires = round_jiffies(transaction->t_expires);
+	journal->j_commit_timer.expires = round_jiffies_up(transaction->t_expires);
 	add_timer(&journal->j_commit_timer);
 
 	J_ASSERT(journal->j_running_transaction == NULL);

Cheers, Andreas
--
Andreas Dilger
Sr. Staff Engineer, Lustre Group
Sun Microsystems of Canada, Inc.

--
To unsubscribe from this list: send the line "unsubscribe linux-ext4" 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

Powered by Openwall GNU/*/Linux Powered by OpenVZ