[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <FCA91A92EE52B041906A0358FC28FCC38EFBE64996@FRE1EXCH02.hq.exar.com>
Date: Mon, 31 Jan 2011 23:26:40 -0800
From: Ramkrishna Vepa <Ramkrishna.Vepa@...r.com>
To: Stefan Weil <weil@...l.berlios.de>
CC: Sivakumar Subramani <Sivakumar.Subramani@...r.com>,
Sreenivasa Honnur <Sreenivasa.Honnur@...r.com>,
"netdev@...r.kernel.org" <netdev@...r.kernel.org>,
"linux-kernel@...r.kernel.org" <linux-kernel@...r.kernel.org>,
Jon Mason <Jon.Mason@...r.com>
Subject: RE: [PATCH] vxge: Fix wrong boolean operator {nodisc}
> This error is reported by cppcheck:
> drivers/net/vxge/vxge-config.c:3693: warning: Mutual exclusion over ||
> always evaluates to true. Did you intend to use && instead?
>
> It looks like cppcheck is correct, so fix this. No test was run.
>
> Signed-off-by: Stefan Weil <weil@...l.berlios.de>
> ---
> drivers/net/vxge/vxge-config.c | 2 +-
> 1 files changed, 1 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/net/vxge/vxge-config.c b/drivers/net/vxge/vxge-
> config.c
> index 01c05f5..228d4f7 100644
> --- a/drivers/net/vxge/vxge-config.c
> +++ b/drivers/net/vxge/vxge-config.c
> @@ -3690,7 +3690,7 @@ __vxge_hw_vpath_rts_table_get(struct
> __vxge_hw_vpath_handle *vp,
> if (status != VXGE_HW_OK)
> goto exit;
>
> - if ((rts_table != VXGE_HW_RTS_ACCESS_STEER_CTRL_DATA_STRUCT_SEL_DA)
> ||
> + if ((rts_table != VXGE_HW_RTS_ACCESS_STEER_CTRL_DATA_STRUCT_SEL_DA)
> &&
> (rts_table !=
> VXGE_HW_RTS_ACS_STEER_CTRL_DATA_STRUCT_SEL_RTH_MULTI_IT))
> *data1 = 0;
> --
Fix looks good. Thanks!
Acked-by: Ram Vepa <ram.vepa@...r.com>
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists