public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
* review: use correct buffer flags when reading superblock
@ 2007-10-10  8:37 Lachlan McIlroy
  2007-10-10  9:34 ` Christoph Hellwig
  2007-10-10 11:28 ` David Chinner
  0 siblings, 2 replies; 10+ messages in thread
From: Lachlan McIlroy @ 2007-10-10  8:37 UTC (permalink / raw)
  To: xfs-dev, xfs-oss

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

When reading the superblock during log recovery we are not setting
the correct buffer flags.  Specifically we are not turning off flags
we do not need such as XBF_ASYNC that is causing the synchronous
xfs_iowait() to hang.  We should also turn off XBF_WRITE and remove
the buffer from the delay write queue just to be safe.

Lachlan

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

--- fs/xfs/xfs_log_recover.c_1.329	2007-10-10 15:59:18.000000000 +1000
+++ fs/xfs/xfs_log_recover.c	2007-10-10 16:03:08.000000000 +1000
@@ -3824,7 +3824,10 @@ xlog_do_recover(
 	 */
 	bp = xfs_getsb(log->l_mp, 0);
 	XFS_BUF_UNDONE(bp);
+	XFS_BUF_UNWRITE(bp);
+	XFS_BUF_UNDELAYWRITE(bp);
 	XFS_BUF_READ(bp);
+	XFS_BUF_UNASYNC(bp);
 	xfsbdstrat(log->l_mp, bp);
 	if ((error = xfs_iowait(bp))) {
 		xfs_ioerror_alert("xlog_do_recover",

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

end of thread, other threads:[~2007-10-19  2:14 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-10-10  8:37 review: use correct buffer flags when reading superblock Lachlan McIlroy
2007-10-10  9:34 ` Christoph Hellwig
2007-10-10 11:25   ` David Chinner
2007-10-18 15:46     ` Christoph Hellwig
2007-10-19  1:32       ` Lachlan McIlroy
2007-10-19  2:14         ` David Chinner
2007-10-10 11:28 ` David Chinner
2007-10-11  2:42   ` Lachlan McIlroy
2007-10-11  3:30     ` David Chinner
2007-10-11  7:23       ` Lachlan McIlroy

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