From f737a745b54c2dffe5e3e3203cea1eecf1c7ecf1 Mon Sep 17 00:00:00 2001 From: Yaniv Kaul Date: Fri, 13 Sep 2019 21:27:44 +0300 Subject: rpc: align structs squash tens of warnings on padding of structs in afr structures. The warnings were found by manually added '-Wpadded' to the GCC command line. Also made relevant structs and definitions static, where it was applicable. Change-Id: Ib71a7e9c6179378f072d796d11172d086c343e53 updates: bz#1193929 Signed-off-by: Yaniv Kaul --- xlators/nfs/server/src/nlm4.c | 52 +++++++++++++++++++++---------------------- 1 file changed, 26 insertions(+), 26 deletions(-) (limited to 'xlators/nfs/server/src/nlm4.c') diff --git a/xlators/nfs/server/src/nlm4.c b/xlators/nfs/server/src/nlm4.c index 957f424fd42..ef65d7f55f8 100644 --- a/xlators/nfs/server/src/nlm4.c +++ b/xlators/nfs/server/src/nlm4.c @@ -2505,39 +2505,39 @@ out: return ret; } -rpcsvc_actor_t nlm4svc_actors[NLM4_PROC_COUNT] = { +static rpcsvc_actor_t nlm4svc_actors[NLM4_PROC_COUNT] = { /* 0 */ - {"NULL", NLM4_NULL, nlm4svc_null, NULL, 0, DRC_IDEMPOTENT}, - {"TEST", NLM4_TEST, nlm4svc_test, NULL, 0, DRC_IDEMPOTENT}, - {"LOCK", NLM4_LOCK, nlm4svc_lock, NULL, 0, DRC_NON_IDEMPOTENT}, - {"CANCEL", NLM4_CANCEL, nlm4svc_cancel, NULL, 0, DRC_NON_IDEMPOTENT}, - {"UNLOCK", NLM4_UNLOCK, nlm4svc_unlock, NULL, 0, DRC_NON_IDEMPOTENT}, + {"NULL", nlm4svc_null, NULL, NLM4_NULL, DRC_IDEMPOTENT, 0}, + {"TEST", nlm4svc_test, NULL, NLM4_TEST, DRC_IDEMPOTENT, 0}, + {"LOCK", nlm4svc_lock, NULL, NLM4_LOCK, DRC_IDEMPOTENT, 0}, + {"CANCEL", nlm4svc_cancel, NULL, NLM4_CANCEL, DRC_NON_IDEMPOTENT, 0}, + {"UNLOCK", nlm4svc_unlock, NULL, NLM4_UNLOCK, DRC_NON_IDEMPOTENT, 0}, /* 5 */ - {"GRANTED", NLM4_GRANTED, NULL, NULL, 0, DRC_NA}, - {"TEST", NLM4_TEST_MSG, NULL, NULL, 0, DRC_NA}, - {"LOCK", NLM4_LOCK_MSG, NULL, NULL, 0, DRC_NA}, - {"CANCEL", NLM4_CANCEL_MSG, NULL, NULL, 0, DRC_NA}, - {"UNLOCK", NLM4_UNLOCK_MSG, NULL, NULL, 0, DRC_NA}, + {"GRANTED", NULL, NULL, NLM4_GRANTED, DRC_NA, 0}, + {"TEST", NULL, NULL, NLM4_TEST_MSG, DRC_NA, 0}, + {"LOCK", NULL, NULL, NLM4_LOCK_MSG, DRC_NA, 0}, + {"CANCEL", NULL, NULL, NLM4_CANCEL_MSG, DRC_NA, 0}, + {"UNLOCK", NULL, NULL, NLM4_UNLOCK_MSG, DRC_NA, 0}, /* 10 */ - {"GRANTED", NLM4_GRANTED_MSG, NULL, NULL, 0, DRC_NA}, - {"TEST", NLM4_TEST_RES, NULL, NULL, 0, DRC_NA}, - {"LOCK", NLM4_LOCK_RES, NULL, NULL, 0, DRC_NA}, - {"CANCEL", NLM4_CANCEL_RES, NULL, NULL, 0, DRC_NA}, - {"UNLOCK", NLM4_UNLOCK_RES, NULL, NULL, 0, DRC_NA}, + {"GRANTED", NULL, NULL, NLM4_GRANTED_MSG, DRC_NA, 0}, + {"TEST", NULL, NULL, NLM4_TEST_RES, DRC_NA, 0}, + {"LOCK", NULL, NULL, NLM4_LOCK_RES, DRC_NA, 0}, + {"CANCEL", NULL, NULL, NLM4_CANCEL_RES, DRC_NA, 0}, + {"UNLOCK", NULL, NULL, NLM4_UNLOCK_RES, DRC_NA, 0}, /* 15 ; procedures 17,18,19 are not defined by nlm */ - {"GRANTED", NLM4_GRANTED_RES, NULL, NULL, 0, DRC_NA}, - {"SM_NOTIFY", NLM4_SM_NOTIFY, NULL, NULL, 0, DRC_NA}, - {"SEVENTEEN", NLM4_SEVENTEEN, NULL, NULL, 0, DRC_NA}, - {"EIGHTEEN", NLM4_EIGHTEEN, NULL, NULL, 0, DRC_NA}, - {"NINETEEN", NLM4_NINETEEN, NULL, NULL, 0, DRC_NA}, + {"GRANTED", NULL, NULL, NLM4_GRANTED_RES, DRC_NA, 0}, + {"SM_NOTIFY", NULL, NULL, NLM4_SM_NOTIFY, DRC_NA, 0}, + {"SEVENTEEN", NULL, NULL, NLM4_SEVENTEEN, DRC_NA, 0}, + {"EIGHTEEN", NULL, NULL, NLM4_EIGHTEEN, DRC_NA, 0}, + {"NINETEEN", NULL, NULL, NLM4_NINETEEN, DRC_NA, 0}, /* 20 */ - {"SHARE", NLM4_SHARE, nlm4svc_share, NULL, 0, DRC_NON_IDEMPOTENT}, - {"UNSHARE", NLM4_UNSHARE, nlm4svc_unshare, NULL, 0, DRC_NON_IDEMPOTENT}, - {"NM_LOCK", NLM4_NM_LOCK, nlm4svc_nm_lock, NULL, 0, DRC_NON_IDEMPOTENT}, - {"FREE_ALL", NLM4_FREE_ALL, nlm4svc_free_all, NULL, 0, DRC_IDEMPOTENT}, + {"SHARE", nlm4svc_share, NULL, NLM4_SHARE, DRC_NON_IDEMPOTENT, 0}, + {"UNSHARE", nlm4svc_unshare, NULL, NLM4_UNSHARE, DRC_NON_IDEMPOTENT, 0}, + {"NM_LOCK", nlm4svc_nm_lock, NULL, NLM4_NM_LOCK, DRC_NON_IDEMPOTENT, 0}, + {"FREE_ALL", nlm4svc_free_all, NULL, NLM4_FREE_ALL, DRC_IDEMPOTENT, 0}, }; -rpcsvc_program_t nlm4prog = { +static rpcsvc_program_t nlm4prog = { .progname = "NLM4", .prognum = NLM_PROGRAM, .progver = NLM_V4, -- cgit