public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] Turn off XBF_READ_AHEAD in io completion
@ 2007-11-01  6:19 Lachlan McIlroy
  2007-11-01 10:00 ` Christoph Hellwig
  0 siblings, 1 reply; 4+ messages in thread
From: Lachlan McIlroy @ 2007-11-01  6:19 UTC (permalink / raw)
  To: xfs-dev, xfs-oss

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

Read-ahead of an inode cluster will set XBF_READ_AHEAD in the buffer.
If we don't remove the flag it will still be set when we flush the
buffer back to disk.  Not sure if leaving this flag set causes any
serious problems but it does trigger an assert.

[-- Attachment #2: readahead.diff --]
[-- Type: text/x-patch, Size: 371 bytes --]

--- fs/xfs/linux-2.6/xfs_buf.c_1.247	2007-10-29 16:01:29.000000000 +1100
+++ fs/xfs/linux-2.6/xfs_buf.c	2007-10-29 14:00:53.000000000 +1100
@@ -1032,7 +1032,7 @@ xfs_buf_ioend(
 	xfs_buf_t		*bp,
 	int			schedule)
 {
-	bp->b_flags &= ~(XBF_READ | XBF_WRITE);
+	bp->b_flags &= ~(XBF_READ | XBF_WRITE | XBF_READ_AHEAD);
 	if (bp->b_error == 0)
 		bp->b_flags |= XBF_DONE;
 

^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2007-11-21 15:22 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-11-01  6:19 [PATCH] Turn off XBF_READ_AHEAD in io completion Lachlan McIlroy
2007-11-01 10:00 ` Christoph Hellwig
2007-11-09  1:03   ` Lachlan McIlroy
2007-11-21 15:21     ` Christoph Hellwig

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox