Move the duplicate fid_is_fs_root() functions to the
lustre_fid.h header.
Test-Parameters: trivial
Signed-off-by: Timothy Day <timday@amazon.com>
Change-Id: I43d914dc28cf653deb0fa48228877c9dae503383
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/57743
Tested-by: jenkins <devops@whamcloud.com>
Tested-by: Maloo <maloo@whamcloud.com>
Reviewed-by: Oleg Drokin <green@whamcloud.com>
Reviewed-by: Alex Zhuravlev <bzzz@whamcloud.com>
Reviewed-by: James Simmons <jsimmons@infradead.org>
fid_seq_is_root(seq) || fid_seq_is_dot(seq);
}
+static inline int fid_is_fs_root(const struct lu_fid *fid)
+{
+ return (unlikely(fid_seq(fid) == FID_SEQ_LOCAL_FILE &&
+ fid_oid(fid) == OSD_FS_ROOT_OID));
+}
+
#ifdef HAVE_SERVER_SUPPORT
static inline int fid_is_namespace_visible(const struct lu_fid *fid)
{
osd->od_oi_table = NULL;
}
-static inline int fid_is_fs_root(const struct lu_fid *fid)
-{
- /* Map root inode to special local object FID */
- return (unlikely(fid_seq(fid) == FID_SEQ_LOCAL_FILE &&
- fid_oid(fid) == OSD_FS_ROOT_OID));
-}
-
static int osd_oi_iam_lookup(struct osd_thread_info *oti,
struct osd_oi *oi, struct dt_rec *rec,
const struct dt_key *key)
return zapid;
}
-static inline int fid_is_fs_root(const struct lu_fid *fid)
-{
- /* Map root inode to special local object FID */
- return fid_seq(fid) == FID_SEQ_LOCAL_FILE &&
- fid_oid(fid) == OSD_FS_ROOT_OID;
-}
-
int osd_fid_lookup(const struct lu_env *env, struct osd_device *dev,
const struct lu_fid *fid, uint64_t *oid)
{