drivers: infiniband: Fix compiler warning
Subsystems (2)
PATCH 1/1 drivers: infiniband: Fix compiler warning
This patch fixes the following compiler warning of uninitialized variable
drivers/infiniband/hw/mlx4/qp.c: In function ‘mlx4_ib_post_send’:drivers/infiniband/hw/mlx4/qp.c:1862:62: warning: ‘vlan’ may be used uninitialized in this function [-Wmaybe-uninitialized] drivers/infiniband/hw/mlx4/qp.c:1752:6: note: ‘vlan’ was declared here
Signed-off-by Stratos Karafotis <[email protected]>
--- drivers/infiniband/hw/mlx4/qp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/infiniband/hw/mlx4/qp.c +1 -1
@@ -1749,7 +1749,7 @@ static int build_mlx_header(struct mlx4_ib_sqp *sqp, struct ib_send_wr *wr,int is_eth;int is_vlan =0 ;int is_grh; -u16 vlan; +u16 vlan =0 ;int err =0 ; send_size =0 ;
Signature · 1 line
1.8.1