xfs
[Top] [All Lists]

Re: [3.0-stable PATCH 31/36] xfs: shutdown xfs_sync_worker before the lo

To: Mark Tinguely <tinguely@xxxxxxx>
Subject: Re: [3.0-stable PATCH 31/36] xfs: shutdown xfs_sync_worker before the log
From: Dave Chinner <david@xxxxxxxxxxxxx>
Date: Wed, 12 Dec 2012 10:55:20 +1100
Cc: stable@xxxxxxxxxxxxxxx, xfs@xxxxxxxxxxx
In-reply-to: <20121203144311.665142015@xxxxxxx>
References: <20121203144208.143464631@xxxxxxx> <20121203144311.665142015@xxxxxxx>
User-agent: Mutt/1.5.21 (2010-09-15)
On Mon, Dec 03, 2012 at 05:42:39PM -0600, Mark Tinguely wrote:
> From: Ben Myers <bpm@xxxxxxx>
> 
> Upstream commit: 8866fc6fa55e31b2bce931b7963ff16641b39dc7
> 
> Revert commit 1307bbd, which uses the s_umount semaphore to provide
> exclusion between xfs_sync_worker and unmount, in favor of shutting down
> the sync worker before freeing the log in xfs_log_unmount.  This is a
> cleaner way of resolving the race between xfs_sync_worker and unmount
> than using s_umount.

If you don't include the s_umount patch, then backporting this fix
is just this hunk:

> Index: b/fs/xfs/xfs_log.c
> ===================================================================
> --- a/fs/xfs/xfs_log.c
> +++ b/fs/xfs/xfs_log.c
> @@ -618,6 +618,7 @@ xfs_log_unmount_write(xfs_mount_t *mp)
>  void
>  xfs_log_unmount(xfs_mount_t *mp)
>  {
> +     cancel_delayed_work_sync(&mp->m_sync_work);
>       xfs_trans_ail_destroy(mp);
>       xlog_dealloc_log(mp->m_log);
>  }

i.e. backport the real fixes, not both the buggy ones and their
subsequent fixes...

Cheers,

Dave.
-- 
Dave Chinner
david@xxxxxxxxxxxxx

<Prev in Thread] Current Thread [Next in Thread>