public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Lachlan McIlroy <lachlan@sgi.com>
To: xfs-dev <xfs-dev@sgi.com>, xfs-oss <xfs@oss.sgi.com>
Subject: [PATCH] Turn off XBF_READ_AHEAD in io completion
Date: Thu, 01 Nov 2007 17:19:35 +1100	[thread overview]
Message-ID: <47296FF7.8080607@sgi.com> (raw)

[-- 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;
 

             reply	other threads:[~2007-11-01  6:19 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-11-01  6:19 Lachlan McIlroy [this message]
2007-11-01 10:00 ` [PATCH] Turn off XBF_READ_AHEAD in io completion Christoph Hellwig
2007-11-09  1:03   ` Lachlan McIlroy
2007-11-21 15:21     ` Christoph Hellwig

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=47296FF7.8080607@sgi.com \
    --to=lachlan@sgi.com \
    --cc=xfs-dev@sgi.com \
    --cc=xfs@oss.sgi.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