[lustre-devel] [PATCH 13/27] lustre: convert ec, ldlm functions to static
James Simmons
jsimmons at infradead.org
Fri Mar 21 06:06:56 PDT 2025
From: Timothy Day <timday at amazon.com>
Static analysis shows that a number of functions
could be made static. This patch declares several
functions in ec, and ldlm static.
WC-bug-id: https://jira.whamcloud.com/browse/LU-8191
Lustre-commit: bcc828bdf88f8a19e ("LU-8191 lustre: convert ec,fid,ldlm,quota functions to static")
Signed-off-by: Timothy Day <timday at amazon.com>
Reviewed-on: https://review.whamcloud.com/c/fs/lustre-release/+/51476
Reviewed-by: Neil Brown <neilb at suse.de>
Reviewed-by: Arshad Hussain <arshad.hussain at aeoncomputing.com>
Reviewed-by: jsimmons <jsimmons at infradead.org>
Reviewed-by: Oleg Drokin <green at whamcloud.com>
Signed-off-by: James Simmons <jsimmons at infradead.org>
---
fs/lustre/ec/ec_base.c | 4 ++--
fs/lustre/ldlm/ldlm_request.c | 2 +-
2 files changed, 3 insertions(+), 3 deletions(-)
diff --git a/fs/lustre/ec/ec_base.c b/fs/lustre/ec/ec_base.c
index e5204668eea1..4241659d28de 100644
--- a/fs/lustre/ec/ec_base.c
+++ b/fs/lustre/ec/ec_base.c
@@ -106,7 +106,7 @@ void ec_init_tables(int k, int rows, unsigned char *a, unsigned char *g_tbls)
}
EXPORT_SYMBOL(ec_init_tables);
-unsigned char gf_mul(unsigned char a, unsigned char b)
+static unsigned char gf_mul(unsigned char a, unsigned char b)
{
int i;
@@ -117,7 +117,7 @@ unsigned char gf_mul(unsigned char a, unsigned char b)
return gff_base[i > 254 ? i - 255 : i];
}
-unsigned char gf_inv(unsigned char a)
+static unsigned char gf_inv(unsigned char a)
{
if (a == 0)
return 0;
diff --git a/fs/lustre/ldlm/ldlm_request.c b/fs/lustre/ldlm/ldlm_request.c
index bccce8b8e5e8..127f5777a5a3 100644
--- a/fs/lustre/ldlm/ldlm_request.c
+++ b/fs/lustre/ldlm/ldlm_request.c
@@ -2355,7 +2355,7 @@ static int lock_can_replay(struct obd_import *imp)
1 + min_t(u32, cli->cl_max_rpcs_in_flight, 8);
}
-int __ldlm_replay_locks(struct obd_import *imp, bool rate_limit)
+static int __ldlm_replay_locks(struct obd_import *imp, bool rate_limit)
{
struct ldlm_namespace *ns = imp->imp_obd->obd_namespace;
LIST_HEAD(list);
--
2.39.3
More information about the lustre-devel
mailing list