Skip to contentSkip to conversation

RT: unwritten_done_lock to DEFINE_SPINLOCK

PATCH Applied Daniel Walker 3 participants 4 messages Sep 27, 2005 – Sep 28, 2005 XFS filesystem

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 RT: unwritten_done_lock to DEFINE_SPINLOCK

Convert unwritten_done_lock xfs lock to the new syntax.

fs/xfs/linux-2.6/xfs_aops.c +1 -1
Index: linux-2.6.13/fs/xfs/linux-2.6/xfs_aops.c
===================================================================
@@ -192,7 +192,7 @@ linvfs_unwritten_done(
 	int			uptodate)
 {
 	xfs_ioend_t		*ioend = bh->b_private;
-	static spinlock_t	unwritten_done_lock = SPIN_LOCK_UNLOCKED;
+	static DECLARE_SPINLOCK(unwritten_done_lock);
 	unsigned long		flags;
 
 	ASSERT(buffer_unwritten(bh));
#1 lore raw
Quoted 9 lines · Daniel Walker

Convert unwritten_done_lock xfs lock to the new syntax.

Index: linux-2.6.13/fs/xfs/linux-2.6/xfs_aops.c
===================================================================

fs/xfs/linux-2.6/xfs_aops.c linvfs_unwritten_done( · line 196

Quoted 6 lines
fs/xfs/linux-2.6/xfs_aops.c +1 -1
@@ -192,7 +192,7 @@ linvfs_unwritten_done(
 	int			uptodate)
 {
 	xfs_ioend_t		*ioend = bh->b_private;
-	static spinlock_t	unwritten_done_lock = SPIN_LOCK_UNLOCKED;
+	static DECLARE_SPINLOCK(unwritten_done_lock);
 	unsigned long		flags;

Did you actually compile this ?

tglx

fs/xfs/linux-2.6/xfs_aops.c +1 -1
@@ -192,7 +192,7 @@ linvfs_unwritten_done(
        int                     uptodate)
 {
        xfs_ioend_t             *ioend = bh->b_private;
-       static spinlock_t       unwritten_done_lock = SPIN_LOCK_UNLOCKED;
+       static DEFINE_SPINLOCK(unwritten_done_lock);
        unsigned long           flags;
 
        ASSERT(buffer_unwritten(bh));
Applied
#2 lore raw
In reply to Daniel Walker
Quoted 9 lines · Daniel Walker

Convert unwritten_done_lock xfs lock to the new syntax.

Index: linux-2.6.13/fs/xfs/linux-2.6/xfs_aops.c
===================================================================

fs/xfs/linux-2.6/xfs_aops.c linvfs_unwritten_done( · line 195

Quoted 5 lines
fs/xfs/linux-2.6/xfs_aops.c +1 -1
@@ -192,7 +192,7 @@ linvfs_unwritten_done(
 	int			uptodate)
 {
 	xfs_ioend_t		*ioend = bh->b_private;
-	static spinlock_t	unwritten_done_lock = SPIN_LOCK_UNLOCKED;
+	static DECLARE_SPINLOCK(unwritten_done_lock);

applied, with the additional detail that it's DEFINE, not DECLARE.

Ingo

#3 lore raw
Quoted 6 lines · Ingo Molnar
Quoted 4 lines · Daniel Walker

Convert unwritten_done_lock xfs lock to the new syntax.

Quoted 12 lines

fs/xfs/linux-2.6/xfs_aops.c linvfs_unwritten_done( · line 195

Quoted 10 lines

Index: linux-2.6.13/fs/xfs/linux-2.6/xfs_aops.c
===================================================================

fs/xfs/linux-2.6/xfs_aops.c +1 -1
@@ -192,7 +192,7 @@ linvfs_unwritten_done(
 	int			uptodate)
 {
 	xfs_ioend_t		*ioend = bh->b_private;
-	static spinlock_t	unwritten_done_lock = SPIN_LOCK_UNLOCKED;
+	static DECLARE_SPINLOCK(unwritten_done_lock);

applied, with the additional detail that it's DEFINE, not DECLARE.

Yeah, thanks .

Daniel