xfs
[Top] [All Lists]

Re: [PATCH 05/13] xfs: sync work is now only periodic log work

To: Dave Chinner <david@xxxxxxxxxxxxx>
Subject: Re: [PATCH 05/13] xfs: sync work is now only periodic log work
From: Mark Tinguely <tinguely@xxxxxxx>
Date: Tue, 04 Sep 2012 11:14:51 -0500
Cc: xfs@xxxxxxxxxxx
In-reply-to: <1346328017-2795-6-git-send-email-david@xxxxxxxxxxxxx>
References: <1346328017-2795-1-git-send-email-david@xxxxxxxxxxxxx> <1346328017-2795-6-git-send-email-david@xxxxxxxxxxxxx>
User-agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:9.0) Gecko/20120122 Thunderbird/9.0
On 08/30/12 07:00, Dave Chinner wrote:
+ * Every sync period we need to unpin all items in the AIL and push them to
+ * disk. If there is nothing dirty, then we might need to cover the log to
+ * indicate that the filesystem is idle.
+ */
+void
+xfs_log_worker(
+       struct work_struct      *work)
+{
+       struct xlog             *log = container_of(to_delayed_work(work),
+                                               struct xlog, l_work);
+       struct xfs_mount        *mp = log->l_mp;
+
+       /* dgc: errors ignored - not fatal and nowhere to report them */
+       if (xfs_log_need_covered(mp))
+               xfs_fs_log_dummy(mp);
+       else
+               xfs_log_force(mp, 0);
+
+       /* start pushing all the metadata that is currently dirty */
+       xfs_ail_push_all(mp->m_ail);
+
+       /* queue us up again */
+       xfs_log_work_queue(mp);
+}

Having log space for the xfs_fs_log_dummy() is the weak point in the remaining log hang problems.

I agree with Dave and the above should remain in this series and log issue handled in another series.

Reviewed-by: Mark Tinguely <tinguely@xxxxxxx>

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