* [PATCH] Fix unused variable warnings for pl_index, sg_l
@ 2016-05-18 17:08 Jarod Wilson
[not found] ` <1463591298-30102-1-git-send-email-jarod-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
0 siblings, 1 reply; 2+ messages in thread
From: Jarod Wilson @ 2016-05-18 17:08 UTC (permalink / raw)
To: linux-rdma-u79uwXL29TY76Z2rM5mHXA; +Cc: Jarod Wilson
These variables will be unused if certain #define's aren't set, so wrap
them with the same #ifdef's as the places they're used.
Signed-off-by: Jarod Wilson <jarod-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
---
src/perftest_resources.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/src/perftest_resources.c b/src/perftest_resources.c
index 71a1541..4071989 100755
--- a/src/perftest_resources.c
+++ b/src/perftest_resources.c
@@ -2778,8 +2778,12 @@ int run_iter_bw(struct pingpong_context *ctx,struct perftest_parameters *user_pa
int cpu_mhz = 0;
int return_value = 0;
int wc_id;
+ #ifdef HAVE_VERBS_EXP
+ #ifdef HAVE_ACCL_VERBS
int pl_index;
struct ibv_sge *sg_l;
+ #endif
+ #endif
ALLOCATE(wc ,struct ibv_wc ,CTX_POLL_BATCH);
--
1.8.3.1
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH] Fix unused variable warnings for pl_index, sg_l
[not found] ` <1463591298-30102-1-git-send-email-jarod-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
@ 2016-05-26 5:08 ` Leon Romanovsky
0 siblings, 0 replies; 2+ messages in thread
From: Leon Romanovsky @ 2016-05-26 5:08 UTC (permalink / raw)
To: Jarod Wilson; +Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA
[-- Attachment #1: Type: text/plain, Size: 1265 bytes --]
On Wed, May 18, 2016 at 01:08:18PM -0400, Jarod Wilson wrote:
> These variables will be unused if certain #define's aren't set, so wrap
> them with the same #ifdef's as the places they're used.
>
> Signed-off-by: Jarod Wilson <jarod-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
> ---
> src/perftest_resources.c | 4 ++++
> 1 file changed, 4 insertions(+)
>
> diff --git a/src/perftest_resources.c b/src/perftest_resources.c
> index 71a1541..4071989 100755
> --- a/src/perftest_resources.c
> +++ b/src/perftest_resources.c
> @@ -2778,8 +2778,12 @@ int run_iter_bw(struct pingpong_context *ctx,struct perftest_parameters *user_pa
> int cpu_mhz = 0;
> int return_value = 0;
> int wc_id;
> + #ifdef HAVE_VERBS_EXP
> + #ifdef HAVE_ACCL_VERBS
Maybe "#if defined(HAVE_VERBS_EXP) && defined(HAVE_ACCL_VERBS)" will be
better?
Anyway, it is the same.
> int pl_index;
> struct ibv_sge *sg_l;
> + #endif
> + #endif
>
> ALLOCATE(wc ,struct ibv_wc ,CTX_POLL_BATCH);
>
> --
> 1.8.3.1
>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
> the body of a message to majordomo-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
> More majordomo info at http://vger.kernel.org/majordomo-info.html
[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2016-05-26 5:08 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2016-05-18 17:08 [PATCH] Fix unused variable warnings for pl_index, sg_l Jarod Wilson
[not found] ` <1463591298-30102-1-git-send-email-jarod-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>
2016-05-26 5:08 ` Leon Romanovsky
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox