net: ethtool: Initialize buffer when querying device channel settings
authorEran Ben Elisha <eranbe@mellanox.com>
Tue, 17 Jan 2017 17:19:17 +0000 (19:19 +0200)
committerRaspbian kernel package updater <root@raspbian.org>
Sun, 23 Jul 2017 03:04:59 +0000 (03:04 +0000)
commit9513a2503f17b1f10adcff85e04f0eb61a5cb006
treee3f26db6653429c63dc765ff2b0cd49a1db7463b
parent1fddafde6a8951556cab2f440aaed2f61d94ea03
net: ethtool: Initialize buffer when querying device channel settings

[ Upstream commit 31a86d137219373c3222ca5f4f912e9a4d8065bb ]

Ethtool channels respond struct was uninitialized when querying device
channel boundaries settings. As a result, unreported fields by the driver
hold garbage.  This may cause sending unsupported params to driver.

Fixes: 8bf368620486 ('ethtool: ensure channel counts are within bounds ...')
Signed-off-by: Eran Ben Elisha <eranbe@mellanox.com>
Signed-off-by: Tariq Toukan <tariqt@mellanox.com>
CC: John W. Linville <linville@tuxdriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Sasha Levin <alexander.levin@verizon.com>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
net/core/ethtool.c