From a40fdacb5f386768f6f2c7f9477e6af73640e166 Mon Sep 17 00:00:00 2001 From: Bart Van Assche Date: Sat, 11 Sep 2010 08:21:35 +0000 Subject: [PATCH] Pre-2.6.31 kernel compiler warning fix. git-svn-id: http://svn.code.sf.net/p/scst/svn/trunk@2092 d57e44dd-8a1f-0410-8b47-8ef2f437770f --- srpt/src/ib_srpt.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/srpt/src/ib_srpt.c b/srpt/src/ib_srpt.c index 204bef89a..0d85e409b 100644 --- a/srpt/src/ib_srpt.c +++ b/srpt/src/ib_srpt.c @@ -136,7 +136,7 @@ module_param(srpt_sq_size, int, 0444); MODULE_PARM_DESC(srpt_sq_size, "Per-channel send queue (SQ) size."); -#if LINUX_VERSION_CODE <= KERNEL_VERSION(2, 6, 27) \ +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 31) \ || defined(RHEL_MAJOR) && RHEL_MAJOR -0 <= 5 static int srpt_autodetect_cred_req; module_param(srpt_autodetect_cred_req, int, 0444); @@ -148,7 +148,12 @@ MODULE_PARM_DESC(srpt_autodetect_cred_req, "Whether or not to autodetect whether the initiator supports" " SRP_CRED_REQ."); +#if LINUX_VERSION_CODE < KERNEL_VERSION(2, 6, 31) \ + || defined(RHEL_MAJOR) && RHEL_MAJOR -0 <= 5 static int use_port_guid_in_session_name; +#else +static bool use_port_guid_in_session_name; +#endif module_param(use_port_guid_in_session_name, bool, 0444); MODULE_PARM_DESC(use_port_guid_in_session_name, "Use target port ID in the SCST session name such that"