]> git.baikalelectronics.ru Git - kernel.git/commit
net: phy: don't allow __set_phy_supported to add unsupported modes
authorHeiner Kallweit <hkallweit1@gmail.com>
Mon, 3 Dec 2018 07:04:57 +0000 (08:04 +0100)
committerDavid S. Miller <davem@davemloft.net>
Mon, 3 Dec 2018 21:50:06 +0000 (13:50 -0800)
commitff123bbff3cb33c2538a2d44f9ea39d3eed01b6d
tree225feb5451fe4f67fe29c12524766ab925d6e27f
parent9ec54efe168ac11c1cfd1ab702c2beeb0d38d0ba
net: phy: don't allow __set_phy_supported to add unsupported modes

Currently __set_phy_supported allows to add modes w/o checking whether
the PHY supports them. This is wrong, it should never add modes but
only remove modes we don't want to support.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/phy/phy_device.c