xfs
[Top] [All Lists]

Re: [PATCH v2 2/2] xfs: disable log force in xfs_buf_item_push() to avoi

To: Brian Foster <bfoster@xxxxxxxxxx>
Subject: Re: [PATCH v2 2/2] xfs: disable log force in xfs_buf_item_push() to avoid xa_lock recursion
From: Mark Tinguely <tinguely@xxxxxxx>
Date: Wed, 06 Feb 2013 14:25:21 -0600
Cc: xfs@xxxxxxxxxxx
Delivered-to: xfs@xxxxxxxxxxx
In-reply-to: <1360154681-28246-3-git-send-email-bfoster@xxxxxxxxxx>
References: <1360154681-28246-1-git-send-email-bfoster@xxxxxxxxxx> <1360154681-28246-3-git-send-email-bfoster@xxxxxxxxxx>
User-agent: Mozilla/5.0 (X11; FreeBSD amd64; rv:9.0) Gecko/20120122 Thunderbird/9.0
On 02/06/13 06:44, Brian Foster wrote:
If the trylock fails and the buffer is pinned and stale, the
resulting xfs_log_force() can lead to lock recursion on the ailp
xa_lock. Call __xfs_buf_trylock() to attempt the buf lock with
xa_lock held, but to avoid the log force. If the trylock had raced
with the buffer being pinned, return XFS_ITEM_PINNED such that
xfsaild will pend up a log force on the next scan.

Signed-off-by: Brian Foster<bfoster@xxxxxxxxxx>
---
  fs/xfs/xfs_buf_item.c |   14 +++++++++++++-
  1 files changed, 13 insertions(+), 1 deletions(-)

Looks good.

Reviewed-by: Mark Tinguely <tinguely@xxxxxxx>

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