From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from cuda.sgi.com (cuda1.sgi.com [192.48.157.11]) by oss.sgi.com (8.14.3/8.14.3/SuSE Linux 0.8) with ESMTP id o11M75cf136973 for ; Mon, 1 Feb 2010 16:07:07 -0600 Received: from bombadil.infradead.org (localhost [127.0.0.1]) by cuda.sgi.com (Spam Firewall) with ESMTP id 0429B136BC8C for ; Mon, 1 Feb 2010 14:08:13 -0800 (PST) Received: from bombadil.infradead.org (bombadil.infradead.org [18.85.46.34]) by cuda.sgi.com with ESMTP id XdvGi3IpadFmJoY3 for ; Mon, 01 Feb 2010 14:08:13 -0800 (PST) Received: from hch by bombadil.infradead.org with local (Exim 4.69 #1 (Red Hat Linux)) id 1Nc4RJ-00014e-Eo for xfs@oss.sgi.com; Mon, 01 Feb 2010 22:08:13 +0000 Date: Mon, 1 Feb 2010 17:08:13 -0500 From: Christoph Hellwig Subject: [PATCH for-2.6.33] xfs: flush all log buffers in xlog_dealloc_log Message-ID: <20100201220813.GA3519@infradead.org> MIME-Version: 1.0 Content-Disposition: inline List-Id: XFS Filesystem from SGI List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: xfs-bounces@oss.sgi.com Errors-To: xfs-bounces@oss.sgi.com To: xfs@oss.sgi.com Make sure all log buffers have made it to disk before we free them. Otherwise we might reference freed buffers or a NULL mp->m_log from the I/O completion handlers. This fixes kernel.org bz #15150. Signed-off-by: Christoph Hellwig Reported-by: Ed Cashin Reported-by: ghani Tested-by: ghani Index: linux-2.6/fs/xfs/xfs_log.c =================================================================== --- linux-2.6.orig/fs/xfs/xfs_log.c 2009-11-09 22:09:08.858026060 +0100 +++ linux-2.6/fs/xfs/xfs_log.c 2009-11-09 22:13:13.958255857 +0100 @@ -1602,6 +1602,8 @@ xlog_dealloc_log(xlog_t *log) xlog_in_core_t *iclog, *next_iclog; int i; + xfs_flush_buftarg(log->l_mp->m_logdev_targp, 1); + iclog = log->l_iclog; for (i=0; il_iclog_bufs; i++) { sv_destroy(&iclog->ic_force_wait); _______________________________________________ xfs mailing list xfs@oss.sgi.com http://oss.sgi.com/mailman/listinfo/xfs