]> git.baikalelectronics.ru Git - kernel.git/commit
net/mlx4_en: Fix panic on xmit while port is down
authorMoshe Shemesh <moshe@mellanox.com>
Sun, 11 Sep 2016 07:56:20 +0000 (10:56 +0300)
committerDavid S. Miller <davem@davemloft.net>
Mon, 12 Sep 2016 02:40:26 +0000 (19:40 -0700)
commitacfe9ddca6dd1840371a6f6b381a9d92514cca71
treef7908527ba24428c8426aae21a6343939b2795ae
parenta26039eb8a605ea3d7321b9d5218751ee5c96a29
net/mlx4_en: Fix panic on xmit while port is down

When port is down, tx drop counter update is not needed.
Updating the counter in this case can cause a kernel
panic as when the port is down, ring can be NULL.

Fixes: 9f9eda7f97cf ("net/mlx4_en: fix tx_dropped bug")
Signed-off-by: Moshe Shemesh <moshe@mellanox.com>
Signed-off-by: Tariq Toukan <tariqt@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/mellanox/mlx4/en_tx.c