diff mbox series

[v2] rdma/cxgb4: Simplify a structure initialization

Message ID 20180731155130.29810-1-bart.vanassche@wdc.com (mailing list archive)
State Accepted
Delegated to: Jason Gunthorpe
Headers show
Series [v2] rdma/cxgb4: Simplify a structure initialization | expand

Commit Message

Bart Van Assche July 31, 2018, 3:51 p.m. UTC
This patch avoids that sparse reports the following warning:

drivers/infiniband/hw/cxgb4/qp.c:2269:34: warning: Using plain integer as NULL pointer

Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com>
Acked-by: Steve Wise <swise@opengridcomputing.com>
Cc: Raju Rangoju <rajur@chelsio.com>
---
 drivers/infiniband/hw/cxgb4/qp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Raju Rangoju July 31, 2018, 3:58 p.m. UTC | #1
On Tuesday, July 07/31/18, 2018 at 08:51:30 -0700, Bart Van Assche wrote:
> This patch avoids that sparse reports the following warning:
> 
> drivers/infiniband/hw/cxgb4/qp.c:2269:34: warning: Using plain integer as NULL pointer
> 
> Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com>
> Acked-by: Steve Wise <swise@opengridcomputing.com>
> Cc: Raju Rangoju <rajur@chelsio.com>
> ---
>  drivers/infiniband/hw/cxgb4/qp.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/infiniband/hw/cxgb4/qp.c b/drivers/infiniband/hw/cxgb4/qp.c
> index 62e2c0d899f5..c26086c76f0b 100644
> --- a/drivers/infiniband/hw/cxgb4/qp.c
> +++ b/drivers/infiniband/hw/cxgb4/qp.c
> @@ -2266,7 +2266,7 @@ struct ib_qp *c4iw_get_qp(struct ib_device *dev, int qpn)
>  
>  void c4iw_dispatch_srq_limit_reached_event(struct c4iw_srq *srq)
>  {
> -	struct ib_event event = {0};
> +	struct ib_event event = {};
>  
>  	event.device = &srq->rhp->ibdev;
>  	event.element.srq = &srq->ibsrq;

Thanks Bart.

Acked-by: Raju Rangoju <rajur@chelsio.com>
> -- 
> 2.18.0
> 
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
Jason Gunthorpe July 31, 2018, 11 p.m. UTC | #2
On Tue, Jul 31, 2018 at 08:51:30AM -0700, Bart Van Assche wrote:
> This patch avoids that sparse reports the following warning:
> 
> drivers/infiniband/hw/cxgb4/qp.c:2269:34: warning: Using plain integer as NULL pointer
> 
> Signed-off-by: Bart Van Assche <bart.vanassche@wdc.com>
> Acked-by: Steve Wise <swise@opengridcomputing.com>
> Acked-by: Raju Rangoju <rajur@chelsio.com>
> ---
>  drivers/infiniband/hw/cxgb4/qp.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Applied to for-next

Jason
--
To unsubscribe from this list: send the line "unsubscribe linux-rdma" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html
diff mbox series

Patch

diff --git a/drivers/infiniband/hw/cxgb4/qp.c b/drivers/infiniband/hw/cxgb4/qp.c
index 62e2c0d899f5..c26086c76f0b 100644
--- a/drivers/infiniband/hw/cxgb4/qp.c
+++ b/drivers/infiniband/hw/cxgb4/qp.c
@@ -2266,7 +2266,7 @@  struct ib_qp *c4iw_get_qp(struct ib_device *dev, int qpn)
 
 void c4iw_dispatch_srq_limit_reached_event(struct c4iw_srq *srq)
 {
-	struct ib_event event = {0};
+	struct ib_event event = {};
 
 	event.device = &srq->rhp->ibdev;
 	event.element.srq = &srq->ibsrq;