| To: | xfs-masters@xxxxxxxxxxx |
|---|---|
| Subject: | [xfs-masters] [patch] xfs: bitlock fix |
| From: | Nick Piggin <npiggin@xxxxxxx> |
| Date: | Tue, 20 Nov 2007 06:17:22 +0100 |
| Reply-to: | xfs-masters@xxxxxxxxxxx |
| Sender: | xfs-masters-bounce@xxxxxxxxxxx |
| User-agent: | Mutt/1.5.9i |
XFS's xfs_icsb_unlock_cntr is missing a memory barrier to close the critical
section. Use lock bitops for this.
Signed-off-by: Nick Piggin <npiggin@xxxxxxx>
---
Index: linux-2.6/fs/xfs/xfs_mount.c
===================================================================
--- linux-2.6.orig/fs/xfs/xfs_mount.c
+++ linux-2.6/fs/xfs/xfs_mount.c
@@ -2035,7 +2035,7 @@ STATIC_INLINE void
xfs_icsb_lock_cntr(
xfs_icsb_cnts_t *icsbp)
{
- while (test_and_set_bit(XFS_ICSB_FLAG_LOCK, &icsbp->icsb_flags)) {
+ while (test_and_set_bit_lock(XFS_ICSB_FLAG_LOCK, &icsbp->icsb_flags)) {
ndelay(1000);
}
}
@@ -2044,7 +2044,7 @@ STATIC_INLINE void
xfs_icsb_unlock_cntr(
xfs_icsb_cnts_t *icsbp)
{
- clear_bit(XFS_ICSB_FLAG_LOCK, &icsbp->icsb_flags);
+ clear_bit_unlock(XFS_ICSB_FLAG_LOCK, &icsbp->icsb_flags);
}
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| ||
| Previous by Date: | [xfs-masters] [Bug 765] xfs_force_shutdown(dm-0,0x8) called from line 1091 of file fs/xfs/xfs_trans.c, bugzilla-daemon |
|---|---|
| Next by Date: | [xfs-masters] [Bug 8144] raid5 disk failure followed by xfs filesystem corruption, bugme-daemon |
| Previous by Thread: | [xfs-masters] [Bug 9400] New: nfsd gets stuck when underlying filesystem is XFS, bugme-daemon |
| Next by Thread: | [xfs-masters] [Bug 8144] raid5 disk failure followed by xfs filesystem corruption, bugme-daemon |
| Indexes: | [Date] [Thread] [Top] [All Lists] |