net/mlx5: Avoid dereferencing uninitialized pointer
authorTalat Batheesh <talatb@mellanox.com>
Tue, 28 Mar 2017 13:13:41 +0000 (16:13 +0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 29 Mar 2017 01:07:15 +0000 (18:07 -0700)
commite497ec680c4cd51e76bfcdd49363d9ab8d32a757
treea640dc269b2ded61147fd5fb391d5bfafb30c68b
parentc2b341a620018d4eaeb0e85c16274ac4e5f153d4
net/mlx5: Avoid dereferencing uninitialized pointer

In NETDEV_CHANGEUPPER event the upper_info field is valid
only when linking is true. Otherwise it should be ignored.

Fixes: 7907f23adc18 (net/mlx5: Implement RoCE LAG feature)
Signed-off-by: Talat Batheesh <talatb@mellanox.com>
Reviewed-by: Aviv Heller <avivh@mellanox.com>
Reviewed-by: Moni Shoua <monis@mellanox.com>
Signed-off-by: Saeed Mahameed <saeedm@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx5/core/lag.c