ibmveth: Convert multicast list size for little-endian system
authorThomas Falcon <tlfalcon@linux.ibm.com>
Mon, 12 Aug 2019 21:13:06 +0000 (16:13 -0500)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Tue, 10 Sep 2019 09:33:44 +0000 (10:33 +0100)
commitcc8aa6155611bf5b8ffa4587b0c67f4bf2028d24
treeec9554cdd7c909fba58201325a7446d737341f89
parent32e912b91b5dec5bdf72ed8e61d33035243d83ab
ibmveth: Convert multicast list size for little-endian system

[ Upstream commit 66cf4710b23ab2adda11155684a2c8826f4fe732 ]

The ibm,mac-address-filters property defines the maximum number of
addresses the hypervisor's multicast filter list can support. It is
encoded as a big-endian integer in the OF device tree, but the virtual
ethernet driver does not convert it for use by little-endian systems.
As a result, the driver is not behaving as it should on affected systems
when a large number of multicast addresses are assigned to the device.

Reported-by: Hangbin Liu <liuhangbin@gmail.com>
Signed-off-by: Thomas Falcon <tlfalcon@linux.ibm.com>
Signed-off-by: Jakub Kicinski <jakub.kicinski@netronome.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/net/ethernet/ibm/ibmveth.c