From e3afa6f49cd12e746f579d38c081b88f3db855cc Mon Sep 17 00:00:00 2001 From: Bob Glossman Date: Wed, 24 Apr 2013 06:43:35 -0700 Subject: [PATCH] LU-3179 build: fix compilation error with gcc 4.7.2 use cast to resolve build warning from gcc 4.7.2 Signed-off-by: Bob Glossman Change-Id: I4356e621f5b9c687a6b76b12a93b664d542e1c79 Reviewed-on: http://review.whamcloud.com/6141 Reviewed-by: Alex Zhuravlev Tested-by: Hudson Tested-by: Maloo Reviewed-by: Keith Mannthey Reviewed-by: Nikitas Angelinas Reviewed-by: James Simmons Reviewed-by: Oleg Drokin --- lustre/ptlrpc/nrs_crr.c | 2 +- lustre/ptlrpc/nrs_orr.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lustre/ptlrpc/nrs_crr.c b/lustre/ptlrpc/nrs_crr.c index 0335bf9..6545913 100644 --- a/lustre/ptlrpc/nrs_crr.c +++ b/lustre/ptlrpc/nrs_crr.c @@ -278,7 +278,7 @@ int nrs_crrn_ctl(struct ptlrpc_nrs_policy *policy, enum ptlrpc_nrs_ctl opc, { LASSERT(spin_is_locked(&policy->pol_nrs->nrs_lock)); - switch(opc) { + switch((enum nrs_ctl_crr)opc) { default: RETURN(-EINVAL); diff --git a/lustre/ptlrpc/nrs_orr.c b/lustre/ptlrpc/nrs_orr.c index bc4b373..5363629 100644 --- a/lustre/ptlrpc/nrs_orr.c +++ b/lustre/ptlrpc/nrs_orr.c @@ -759,7 +759,7 @@ int nrs_orr_ctl(struct ptlrpc_nrs_policy *policy, enum ptlrpc_nrs_ctl opc, { LASSERT(spin_is_locked(&policy->pol_nrs->nrs_lock)); - switch(opc) { + switch((enum nrs_ctl_orr)opc) { default: RETURN(-EINVAL); -- 1.8.3.1