public inbox for linux-rdma@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH v1 rdma-next] bnxt_re: Fix -Wimplicit-fallthrough warnings in GCC 7.1
@ 2017-07-13 15:47 Leon Romanovsky
       [not found] ` <20170713154722.10294-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
  0 siblings, 1 reply; 3+ messages in thread
From: Leon Romanovsky @ 2017-07-13 15:47 UTC (permalink / raw)
  To: Devesh Sharma
  Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA, Leon Romanovsky,
	Bart Van Assche

From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>

[59/189] Building C object providers/bnxt_re/CMakeFiles/bnxt_re-rdmav2.dir/verbs.c.o
../providers/bnxt_re/verbs.c: In function ‘bnxt_re_post_send’:
../providers/bnxt_re/verbs.c:1222:18: warning: this statement may fall through [-Wimplicit-fallthrough=]
    hdr->key_immd = htole32(be32toh(wr->imm_data));
                  ^
../providers/bnxt_re/verbs.c:1223:3: note: here
   case IBV_WR_SEND:
   ^~~~
../providers/bnxt_re/verbs.c:1232:18: warning: this statement may fall through [-Wimplicit-fallthrough=]
    hdr->key_immd = htole32(be32toh(wr->imm_data));
                  ^
../providers/bnxt_re/verbs.c:1233:3: note: here
   case IBV_WR_RDMA_WRITE:

Cc: Bart Van Assche <Bart.VanAssche-Sjgp3cTcYWE@public.gmane.org>
Signed-off-by: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
---
Changelog from v0:
 * Used commonly used in rdma-core annotation to mark fail through.
---
 providers/bnxt_re/verbs.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/providers/bnxt_re/verbs.c b/providers/bnxt_re/verbs.c
index 1fe79671..b89bcbaa 100644
--- a/providers/bnxt_re/verbs.c
+++ b/providers/bnxt_re/verbs.c
@@ -1220,6 +1220,7 @@ int bnxt_re_post_send(struct ibv_qp *ibvqp, struct ibv_send_wr *wr,
 			 * LE platform be32toh will do the job.
 			 */
 			hdr->key_immd = htole32(be32toh(wr->imm_data));
+			/* fall through */
 		case IBV_WR_SEND:
 			if (qp->qptyp == IBV_QPT_UD)
 				bytes = bnxt_re_build_ud_sqe(qp, sqe, wr,
@@ -1230,6 +1231,7 @@ int bnxt_re_post_send(struct ibv_qp *ibvqp, struct ibv_send_wr *wr,
 			break;
 		case IBV_WR_RDMA_WRITE_WITH_IMM:
 			hdr->key_immd = htole32(be32toh(wr->imm_data));
+			/* fall through */
 		case IBV_WR_RDMA_WRITE:
 			bytes = bnxt_re_build_rdma_sqe(qp, sqe, wr, is_inline);
 			break;
--
2.13.2

--
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] 3+ messages in thread

* Re: [PATCH v1 rdma-next] bnxt_re: Fix -Wimplicit-fallthrough warnings in GCC 7.1
       [not found] ` <20170713154722.10294-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
@ 2017-07-13 15:49   ` Leon Romanovsky
  2017-07-13 15:52   ` Bart Van Assche
  1 sibling, 0 replies; 3+ messages in thread
From: Leon Romanovsky @ 2017-07-13 15:49 UTC (permalink / raw)
  To: Devesh Sharma; +Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA, Bart Van Assche

[-- Attachment #1: Type: text/plain, Size: 2369 bytes --]

Something was broken in my scripts, it should be rdma-core and not rdma-next.

Sorry.

On Thu, Jul 13, 2017 at 06:47:22PM +0300, Leon Romanovsky wrote:
> From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
>
> [59/189] Building C object providers/bnxt_re/CMakeFiles/bnxt_re-rdmav2.dir/verbs.c.o
> ../providers/bnxt_re/verbs.c: In function ‘bnxt_re_post_send’:
> ../providers/bnxt_re/verbs.c:1222:18: warning: this statement may fall through [-Wimplicit-fallthrough=]
>     hdr->key_immd = htole32(be32toh(wr->imm_data));
>                   ^
> ../providers/bnxt_re/verbs.c:1223:3: note: here
>    case IBV_WR_SEND:
>    ^~~~
> ../providers/bnxt_re/verbs.c:1232:18: warning: this statement may fall through [-Wimplicit-fallthrough=]
>     hdr->key_immd = htole32(be32toh(wr->imm_data));
>                   ^
> ../providers/bnxt_re/verbs.c:1233:3: note: here
>    case IBV_WR_RDMA_WRITE:
>
> Cc: Bart Van Assche <Bart.VanAssche-Sjgp3cTcYWE@public.gmane.org>
> Signed-off-by: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
> ---
> Changelog from v0:
>  * Used commonly used in rdma-core annotation to mark fail through.
> ---
>  providers/bnxt_re/verbs.c | 2 ++
>  1 file changed, 2 insertions(+)
>
> diff --git a/providers/bnxt_re/verbs.c b/providers/bnxt_re/verbs.c
> index 1fe79671..b89bcbaa 100644
> --- a/providers/bnxt_re/verbs.c
> +++ b/providers/bnxt_re/verbs.c
> @@ -1220,6 +1220,7 @@ int bnxt_re_post_send(struct ibv_qp *ibvqp, struct ibv_send_wr *wr,
>  			 * LE platform be32toh will do the job.
>  			 */
>  			hdr->key_immd = htole32(be32toh(wr->imm_data));
> +			/* fall through */
>  		case IBV_WR_SEND:
>  			if (qp->qptyp == IBV_QPT_UD)
>  				bytes = bnxt_re_build_ud_sqe(qp, sqe, wr,
> @@ -1230,6 +1231,7 @@ int bnxt_re_post_send(struct ibv_qp *ibvqp, struct ibv_send_wr *wr,
>  			break;
>  		case IBV_WR_RDMA_WRITE_WITH_IMM:
>  			hdr->key_immd = htole32(be32toh(wr->imm_data));
> +			/* fall through */
>  		case IBV_WR_RDMA_WRITE:
>  			bytes = bnxt_re_build_rdma_sqe(qp, sqe, wr, is_inline);
>  			break;
> --
> 2.13.2
>
> --
> 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: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v1 rdma-next] bnxt_re: Fix -Wimplicit-fallthrough warnings in GCC 7.1
       [not found] ` <20170713154722.10294-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
  2017-07-13 15:49   ` Leon Romanovsky
@ 2017-07-13 15:52   ` Bart Van Assche
  1 sibling, 0 replies; 3+ messages in thread
From: Bart Van Assche @ 2017-07-13 15:52 UTC (permalink / raw)
  To: Leon Romanovsky, Devesh Sharma
  Cc: linux-rdma-u79uwXL29TY76Z2rM5mHXA, Leon Romanovsky,
	Bart Van Assche

On 07/13/17 08:47, Leon Romanovsky wrote:
> From: Leon Romanovsky <leonro-VPRAkNaXOzVWk0Htik3J/w@public.gmane.org>
> 
> [59/189] Building C object providers/bnxt_re/CMakeFiles/bnxt_re-rdmav2.dir/verbs.c.o
> ../providers/bnxt_re/verbs.c: In function ‘bnxt_re_post_send’:
> ../providers/bnxt_re/verbs.c:1222:18: warning: this statement may fall through [-Wimplicit-fallthrough=]
>     hdr->key_immd = htole32(be32toh(wr->imm_data));
>                   ^
> ../providers/bnxt_re/verbs.c:1223:3: note: here
>    case IBV_WR_SEND:
>    ^~~~
> ../providers/bnxt_re/verbs.c:1232:18: warning: this statement may fall through [-Wimplicit-fallthrough=]
>     hdr->key_immd = htole32(be32toh(wr->imm_data));
>                   ^
> ../providers/bnxt_re/verbs.c:1233:3: note: here
>    case IBV_WR_RDMA_WRITE:

Reviewed-by: Bart Van Assche <Bart.VanAssche-Sjgp3cTcYWE@public.gmane.org>

--
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	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2017-07-13 15:52 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-07-13 15:47 [PATCH v1 rdma-next] bnxt_re: Fix -Wimplicit-fallthrough warnings in GCC 7.1 Leon Romanovsky
     [not found] ` <20170713154722.10294-1-leon-DgEjT+Ai2ygdnm+yROfE0A@public.gmane.org>
2017-07-13 15:49   ` Leon Romanovsky
2017-07-13 15:52   ` Bart Van Assche

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox