Message ID | 20211110023405.GY24307@magnolia (mailing list archive) |
---|---|
State | Accepted, archived |
Headers | show |
Series | xfs: #ifdef out perag code for userspace | expand |
On 11/9/21 8:34 PM, Darrick J. Wong wrote: > From: Darrick J. Wong <djwong@kernel.org> > > Sync this one last bit of discrepancy between kernel and userspace > libxfs. > > Signed-off-by: Darrick J. Wong <djwong@kernel.org> I was #ifdef before #ifdef was cool, man. Reviewed-by: Eric Sandeen <sandeen@redhat.com> (tiny thing see below, use your discretion) > --- > fs/xfs/libxfs/xfs_btree.c | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/fs/xfs/libxfs/xfs_btree.c b/fs/xfs/libxfs/xfs_btree.c > index b4e19aacb9de..d8a859bc797a 100644 > --- a/fs/xfs/libxfs/xfs_btree.c > +++ b/fs/xfs/libxfs/xfs_btree.c > @@ -2785,6 +2785,7 @@ __xfs_btree_split( > return error; > } > > +#ifdef __KERNEL__ > struct xfs_btree_split_args { > struct xfs_btree_cur *cur; > int level; > @@ -2870,6 +2871,9 @@ xfs_btree_split( > destroy_work_on_stack(&args.work); > return args.result; > } > +#else /* !KERNEL */ If you wanted to change this to /* !__KERNEL__ */ to be spot-on, I wouldn't complain, and could just sync that up in userspace. > +#define xfs_btree_split __xfs_btree_split > +#endif and maybe #endif /* __KERNEL__ */ Up to you. > > > /* >
diff --git a/fs/xfs/libxfs/xfs_btree.c b/fs/xfs/libxfs/xfs_btree.c index b4e19aacb9de..d8a859bc797a 100644 --- a/fs/xfs/libxfs/xfs_btree.c +++ b/fs/xfs/libxfs/xfs_btree.c @@ -2785,6 +2785,7 @@ __xfs_btree_split( return error; } +#ifdef __KERNEL__ struct xfs_btree_split_args { struct xfs_btree_cur *cur; int level; @@ -2870,6 +2871,9 @@ xfs_btree_split( destroy_work_on_stack(&args.work); return args.result; } +#else /* !KERNEL */ +#define xfs_btree_split __xfs_btree_split +#endif /*