diff mbox series

[for-next] IB/hfi1: Fix a build warning for TID RDMA READ

Message ID 20190215214523.11005.36331.stgit@scvm10.sc.intel.com (mailing list archive)
State Mainlined
Commit e50838c27ff7e1438ea2f9ab4bfcb227f90a107f
Delegated to: Jason Gunthorpe
Headers show
Series [for-next] IB/hfi1: Fix a build warning for TID RDMA READ | expand

Commit Message

Dennis Dalessandro Feb. 15, 2019, 9:45 p.m. UTC
From: Kaike Wan <kaike.wan@intel.com>

The following build warning was produced for the TID RDMA READ
patch ("IB/hfi1: Enable TID RDMA READ protocol"):

drivers/infiniband/hw/hfi1/qp.c: In function 'hfi1_setup_wqe':
drivers/infiniband/hw/hfi1/qp.c:328:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
   hfi1_setup_tid_rdma_wqe(qp, wqe);
   ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/infiniband/hw/hfi1/qp.c:329:2: note: here
  case IB_QPT_UC:
  ^~~~

This patch will fix the issue by adding the "fall through" comment.

Fixes: f1ab4efa6d32 ("IB/hfi1: Enable TID RDMA READ protocol")
Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
Signed-off-by: Kaike Wan <kaike.wan@intel.com>
Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
---
 drivers/infiniband/hw/hfi1/qp.c |    1 +
 1 files changed, 1 insertions(+), 0 deletions(-)

Comments

Jason Gunthorpe Feb. 15, 2019, 11:05 p.m. UTC | #1
On Fri, Feb 15, 2019 at 01:45:30PM -0800, Dennis Dalessandro wrote:
> From: Kaike Wan <kaike.wan@intel.com>
> 
> The following build warning was produced for the TID RDMA READ
> patch ("IB/hfi1: Enable TID RDMA READ protocol"):
> 
> drivers/infiniband/hw/hfi1/qp.c: In function 'hfi1_setup_wqe':
> drivers/infiniband/hw/hfi1/qp.c:328:3: warning: this statement may fall through [-Wimplicit-fallthrough=]
>    hfi1_setup_tid_rdma_wqe(qp, wqe);
>    ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
> drivers/infiniband/hw/hfi1/qp.c:329:2: note: here
>   case IB_QPT_UC:
>   ^~~~
> 
> This patch will fix the issue by adding the "fall through" comment.
> 
> Fixes: f1ab4efa6d32 ("IB/hfi1: Enable TID RDMA READ protocol")
> Reviewed-by: Mike Marciniszyn <mike.marciniszyn@intel.com>
> Signed-off-by: Kaike Wan <kaike.wan@intel.com>
> Signed-off-by: Dennis Dalessandro <dennis.dalessandro@intel.com>
> ---
>  drivers/infiniband/hw/hfi1/qp.c |    1 +
>  1 files changed, 1 insertions(+), 0 deletions(-)

Applied to for-next, thanks

Jason
diff mbox series

Patch

diff --git a/drivers/infiniband/hw/hfi1/qp.c b/drivers/infiniband/hw/hfi1/qp.c
index d8f7add..9b643c2 100644
--- a/drivers/infiniband/hw/hfi1/qp.c
+++ b/drivers/infiniband/hw/hfi1/qp.c
@@ -326,6 +326,7 @@  int hfi1_setup_wqe(struct rvt_qp *qp, struct rvt_swqe *wqe, bool *call_send)
 	switch (qp->ibqp.qp_type) {
 	case IB_QPT_RC:
 		hfi1_setup_tid_rdma_wqe(qp, wqe);
+		/* fall through */
 	case IB_QPT_UC:
 		if (wqe->length > 0x80000000U)
 			return -EINVAL;