Review: fix block reservation to work with per-cpu counters
This fails to build on non-SMP systems:
CC [M] fs/xfs/xfs_fsops.ofs/xfs/xfs_fsops.c: In function 'xfs_fs_counts':fs/xfs/xfs_fsops.c:463: warning: implicit declaration of function 'xfs_icsb_sync_counters_flags' fs/xfs/xfs_fsops.c:463: error: 'XFS_ICSB_LAZY_COUNT' undeclared (first use in this function) fs/xfs/xfs_fsops.c:463: error: (Each undeclared identifier is reported only once fs/xfs/xfs_fsops.c:463: error: for each function it appears in.) fs/xfs/xfs_fsops.c: In function 'xfs_reserve_blocks':fs/xfs/xfs_fsops.c:525: error: 'XFS_ICSB_SB_LOCKED' undeclared (first use in this function) make[1]: *** [fs/xfs/xfs_fsops.o] Error 1
make: *** [fs/xfs/xfs.ko] Error 2
The define for not HAVE_PERCPU_SB needs to be changed:
Index: fs/xfs/xfs_mount.h
===================================================================
RCS file: /cvs/linux-2.6-xfs/fs/xfs/xfs_mount.h,v
retrieving revision 1.232
xfs/xfs_mount.h +0 -0
@@ -311,7 +311,7 @@
#else
#define xfs_icsb_init_counters(mp) (0)
-#define xfs_icsb_sync_counters_lazy(mp) do { } while (0)
+#define xfs_icsb_sync_counters_flags(mp, flags) do { } while (0)
#endif
typedef struct xfs_mount {
Quoted 18 lines · Kevin Jamieson
This fails to build on non-SMP systems:
CC [M]
fs/xfs/xfs_fsops.ofs/xfs/xfs_fsops.c: In function 'xfs_fs_counts':fs/xfs/xfs_fsops.c:463: warning: implicit declaration of function 'xfs_icsb_sync_counters_flags'fs/xfs/xfs_fsops.c:463: error: 'XFS_ICSB_LAZY_COUNT' undeclared (first use in this function)fs/xfs/xfs_fsops.c:463: error: (Each undeclared identifier is reported only oncefs/xfs/xfs_fsops.c:463: error: for each function it appears in.)fs/xfs/xfs_fsops.c: In function 'xfs_reserve_blocks':fs/xfs/xfs_fsops.c:525: error: 'XFS_ICSB_SB_LOCKED' undeclared (first use in this function)
make[1]: *** [fs/xfs/xfs_fsops.o] Error 1
make: *** [fs/xfs/xfs.ko] Error 2
Quoted 1 line
The define for not
HAVE_PERCPU_SBneeds to be changed:
Sorry about that - my fault. This fix looks good - I'll try to find some time to check this in (I'm at LCA right now and have limited net access).
Chatz, maybe you could check this in?
Cheers,
Dave.
Signature · 3 lines
Dave Chinner Principal Engineer SGI Australian Software Group
Quoted 19 lines · David Chinner
Quoted 18 lines · Kevin Jamieson
This fails to build on non-SMP systems:
CC [M]
fs/xfs/xfs_fsops.ofs/xfs/xfs_fsops.c: In function 'xfs_fs_counts':fs/xfs/xfs_fsops.c:463: warning: implicit declaration of function 'xfs_icsb_sync_counters_flags'fs/xfs/xfs_fsops.c:463: error: 'XFS_ICSB_LAZY_COUNT' undeclared (first use in this function)fs/xfs/xfs_fsops.c:463: error: (Each undeclared identifier is reported only oncefs/xfs/xfs_fsops.c:463: error: for each function it appears in.)fs/xfs/xfs_fsops.c: In function 'xfs_reserve_blocks':fs/xfs/xfs_fsops.c:525: error: 'XFS_ICSB_SB_LOCKED' undeclared (first use in this function)
make[1]: *** [fs/xfs/xfs_fsops.o] Error 1
make: *** [fs/xfs/xfs.ko] Error 2
Quoted 8 lines
Quoted 1 line
The define for not
HAVE_PERCPU_SBneeds to be changed:Sorry about that - my fault. This fix looks good - I'll try to find some time to check this in (I'm at LCA right now and have limited net access).
Chatz, maybe you could check this in?
Done.
David
Signature · 3 lines
David Chatterton XFS Engineering Manager SGI Australia