linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Joe Thornber <thornber@sistina.com>
To: Joe Thornber <thornber@sistina.com>
Cc: Marcelo Tosatti <marcelo.tosatti@cyclades.com>,
	Linux Mailing List <linux-kernel@vger.kernel.org>
Subject: [Patch 1/4] fs.h: b_journal_head
Date: Tue, 9 Dec 2003 12:24:18 +0000	[thread overview]
Message-ID: <20031209122418.GC472@reti> (raw)
In-Reply-To: <20031209115806.GA472@reti>

Add a new member to struct buffer_head called b_journal_head.  This is
for jbd to use, rather than have it peeking at b_private for in flight
ios.
--- diff/fs/buffer.c	2003-12-09 10:25:27.000000000 +0000
+++ source/fs/buffer.c	2003-12-09 10:32:41.000000000 +0000
@@ -763,6 +763,7 @@
 	bh->b_list = BUF_CLEAN;
 	bh->b_end_io = handler;
 	bh->b_private = private;
+	bh->b_journal_head = NULL;
 }
 
 static void end_buffer_io_async(struct buffer_head * bh, int uptodate)
--- diff/fs/jbd/journal.c	2003-12-09 10:25:27.000000000 +0000
+++ source/fs/jbd/journal.c	2003-12-09 10:32:41.000000000 +0000
@@ -1802,9 +1802,9 @@
 
 		if (buffer_jbd(bh)) {
 			/* Someone did it for us! */
-			J_ASSERT_BH(bh, bh->b_private != NULL);
+ 			J_ASSERT_BH(bh, bh->b_journal_head != NULL);
 			journal_free_journal_head(jh);
-			jh = bh->b_private;
+ 			jh = bh->b_journal_head;
 		} else {
 			/*
 			 * We actually don't need jh_splice_lock when
@@ -1812,7 +1812,7 @@
 			 */
 			spin_lock(&jh_splice_lock);
 			set_bit(BH_JBD, &bh->b_state);
-			bh->b_private = jh;
+			bh->b_journal_head = jh;
 			jh->b_bh = bh;
 			atomic_inc(&bh->b_count);
 			spin_unlock(&jh_splice_lock);
@@ -1821,7 +1821,7 @@
 	}
 	jh->b_jcount++;
 	spin_unlock(&journal_datalist_lock);
-	return bh->b_private;
+	return bh->b_journal_head;
 }
 
 /*
@@ -1854,7 +1854,7 @@
 			J_ASSERT_BH(bh, jh2bh(jh) == bh);
 			BUFFER_TRACE(bh, "remove journal_head");
 			spin_lock(&jh_splice_lock);
-			bh->b_private = NULL;
+			bh->b_journal_head = NULL;
 			jh->b_bh = NULL;	/* debug, really */
 			clear_bit(BH_JBD, &bh->b_state);
 			__brelse(bh);
--- diff/include/linux/fs.h	2003-12-09 10:25:27.000000000 +0000
+++ source/include/linux/fs.h	2003-12-09 10:32:41.000000000 +0000
@@ -265,7 +265,7 @@
 	struct page *b_page;		/* the page this bh is mapped to */
 	void (*b_end_io)(struct buffer_head *bh, int uptodate); /* I/O completion */
  	void *b_private;		/* reserved for b_end_io */
-
+ 	void *b_journal_head;		/* ext3 journal_heads */
 	unsigned long b_rsector;	/* Real buffer location on disk */
 	wait_queue_head_t b_wait;
 
--- diff/include/linux/jbd.h	2003-06-16 09:56:12.000000000 +0100
+++ source/include/linux/jbd.h	2003-12-09 10:32:41.000000000 +0000
@@ -311,7 +311,7 @@
 
 static inline struct journal_head *bh2jh(struct buffer_head *bh)
 {
-	return bh->b_private;
+	return bh->b_journal_head;
 }
 
 #define HAVE_JOURNAL_CALLBACK_STATUS

  reply	other threads:[~2003-12-09 12:44 UTC|newest]

Thread overview: 54+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-12-09 11:58 Device-mapper submission for 2.4 Joe Thornber
2003-12-09 12:24 ` Joe Thornber [this message]
2003-12-09 23:46   ` [Patch 1/4] fs.h: b_journal_head Nathan Scott
2003-12-10  8:46     ` Joe Thornber
2003-12-10 12:06       ` Nathan Scott
2003-12-09 12:25 ` [Patch 2/4] dm: mempool backport Joe Thornber
2003-12-09 12:26 ` [Patch 3/4] dm: core files Joe Thornber
2003-12-09 12:26 ` [Patch 4/4] dm: ioctl interface Joe Thornber
2003-12-09 13:15 ` Device-mapper submission for 2.4 Marcelo Tosatti
2003-12-09 13:45   ` Joe Thornber
2003-12-09 14:00     ` Måns Rullgård
2003-12-09 14:10       ` Muli Ben-Yehuda
2003-12-09 14:21         ` Måns Rullgård
2003-12-09 14:16       ` Joe Thornber
2003-12-09 14:24       ` Stefan Smietanowski
2003-12-09 14:10     ` Marcelo Tosatti
2003-12-09 14:34       ` Joe Thornber
2003-12-09 21:07         ` Paul Jakma
2003-12-09 22:26           ` Joe Thornber
2003-12-09 22:48             ` Marcelo Tosatti
2003-12-09 23:46               ` Paul Jakma
2003-12-09 23:58                 ` William Lee Irwin III
2003-12-10  0:15                   ` Paul Jakma
2003-12-10 11:49                     ` Stephan von Krawczynski
2003-12-10 23:15                     ` Dave Jones
2003-12-10  0:27                 ` Jose Luis Domingo Lopez
2003-12-10  0:59                   ` Tupshin Harper
2003-12-10  9:40                     ` Wichert Akkerman
2003-12-10  2:44                 ` Martin J. Bligh
2003-12-10 15:55                   ` Paul Jakma
2003-12-10 16:54                     ` venom
2003-12-10 17:00                       ` Paul Jakma
2003-12-10 17:14                         ` venom
2003-12-10 23:40                         ` Mike Fedyk
2003-12-11 19:48                           ` Alasdair G Kergon
2003-12-16 19:15                     ` bill davidsen
2003-12-16 19:01                 ` bill davidsen
2003-12-10  8:45             ` Jens Axboe
2003-12-10 17:30               ` Paul Jakma
2003-12-10 17:44                 ` Joe Thornber
2003-12-10 17:48                   ` venom
2003-12-10 18:07                   ` Paul Jakma
2003-12-10 19:30                   ` Jens Axboe
2003-12-09 17:02       ` Bill Rugolsky Jr.
2003-12-09 22:53         ` Ciaran McCreesh
2003-12-10  3:38         ` Lincoln Dale
2003-12-10  6:12           ` Willy Tarreau
2003-12-10  6:35             ` viro
2003-12-09 17:45       ` Kevin Corry
2003-12-09 19:47         ` Paul P Komkoff Jr
2003-12-09 14:23     ` Stefan Smietanowski
2003-12-09 14:36       ` Joe Thornber
2003-12-09 19:50 ` William Lee Irwin III
2003-12-09 21:13   ` Paul Jakma

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=20031209122418.GC472@reti \
    --to=thornber@sistina.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=marcelo.tosatti@cyclades.com \
    /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;
as well as URLs for NNTP newsgroup(s).