Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1711126

[PATCH 02/64] staging: lustre: uapi: remove unused functions for lustre_fid.h

From James Simmons <jsimmons@infradead.org>
Newsgroups linux.kernel
Subject [PATCH 02/64] staging: lustre: uapi: remove unused functions for lustre_fid.h
Date 2017-08-14 18:10 +0200
Message-ID <ueq6f-6jm-45@gated-at.bofh.it> (permalink)
References <uepMR-5WA-3@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


The inline function fid_is_namespace_visible and ost_fid_from_resid
are only used for server code so we can remove it.

Signed-off-by: James Simmons <jsimmons@infradead.org>
---
 drivers/staging/lustre/lustre/include/lustre_fid.h | 29 ----------------------
 1 file changed, 29 deletions(-)

diff --git a/drivers/staging/lustre/lustre/include/lustre_fid.h b/drivers/staging/lustre/lustre/include/lustre_fid.h
index 6dc24a7..681f698 100644
--- a/drivers/staging/lustre/lustre/include/lustre_fid.h
+++ b/drivers/staging/lustre/lustre/include/lustre_fid.h
@@ -288,18 +288,6 @@ static inline int fid_is_quota(const struct lu_fid *fid)
 	       fid_seq(fid) == FID_SEQ_QUOTA_GLB;
 }
 
-static inline int fid_is_namespace_visible(const struct lu_fid *fid)
-{
-	const __u64 seq = fid_seq(fid);
-
-	/* Here, we cannot distinguish whether the normal FID is for OST
-	 * object or not. It is caller's duty to check more if needed.
-	 */
-	return (!fid_is_last_id(fid) &&
-		(fid_seq_is_norm(seq) || fid_seq_is_igif(seq))) ||
-	       fid_is_root(fid) || fid_is_dot_lustre(fid);
-}
-
 static inline int fid_seq_in_fldb(__u64 seq)
 {
 	return fid_seq_is_igif(seq) || fid_seq_is_norm(seq) ||
@@ -522,23 +510,6 @@ static inline void ost_fid_build_resid(const struct lu_fid *fid,
 	}
 }
 
-static inline void ost_fid_from_resid(struct lu_fid *fid,
-				      const struct ldlm_res_id *name,
-				      int ost_idx)
-{
-	if (fid_seq_is_mdt0(name->name[LUSTRE_RES_ID_VER_OID_OFF])) {
-		/* old resid */
-		struct ost_id oi;
-
-		ostid_set_seq(&oi, name->name[LUSTRE_RES_ID_VER_OID_OFF]);
-		ostid_set_id(&oi, name->name[LUSTRE_RES_ID_SEQ_OFF]);
-		ostid_to_fid(fid, &oi, ost_idx);
-	} else {
-		/* new resid */
-		fid_extract_from_res_name(fid, name);
-	}
-}
-
 /**
  * Flatten 128-bit FID values into a 64-bit value for use as an inode number.
  * For non-IGIF FIDs this starts just over 2^32, and continues without
-- 
1.8.3.1

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH 00/64] staging: lustre: uapi: normalize the lustre headers James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  [PATCH 12/64] staging: lustre: uapi: move lustre_ioctl.h to uapi directory James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  [PATCH 10/64] staging: lustre: uapi: move obd_ioctl_getdata() declaration James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  [PATCH 06/64] staging: lustre: uapi: remove unused function in lustre_disk.h James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  [PATCH 14/64] staging: lustre: uapi: cleanup headers for lustre_ioctl.h James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  [PATCH 04/64] staging: lustre: uapi: update URL doc link in lustre_fid.h James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  [PATCH 02/64] staging: lustre: uapi: remove unused functions for lustre_fid.h James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  [PATCH 16/64] staging: lustre: uapi: move kernel only prototypes out of lustre_param.h James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  [PATCH 05/64] staging: lustre: uapi: move lu_fid, ost_id funcs out of lustre_idl.h James Simmons <jsimmons@infradead.org> - 2017-08-14 18:10 +0200
  Re: [PATCH 00/64] staging: lustre: uapi: normalize the lustre headers Greg Kroah-Hartman <gregkh@linuxfoundation.org> - 2017-08-17 18:30 +0200

csiph-web