linux/net/dsa
Florian Fainelli faf3a932fb net: dsa: Ensure validity of dst->ds[0]
It is perfectly possible to have non zero indexed switches being present
in a DSA switch tree, in such a case, we will be deferencing a NULL
pointer while dsa_cpu_port_ethtool_{setup,restore}. Be more defensive
and ensure that dst->ds[0] is valid before doing anything with it.

Fixes: 0c73c523cf ("net: dsa: Initialize CPU port ethtool ops per tree")
Signed-off-by: Florian Fainelli <f.fainelli@gmail.com>
Reviewed-by: Vivien Didelot <vivien.didelot@savoirfairelinux.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-01-10 20:18:52 -05:00
..
Kconfig net-next: dsa: add Qualcomm tag RX/TX handler 2016-09-16 04:31:51 -04:00
Makefile net-next: dsa: add Qualcomm tag RX/TX handler 2016-09-16 04:31:51 -04:00
dsa.c of_mdio: add helper to deregister fixed-link PHYs 2016-11-29 23:17:02 -05:00
dsa2.c net: dsa: Ensure validity of dst->ds[0] 2017-01-10 20:18:52 -05:00
dsa_priv.h net-next: dsa: add Qualcomm tag RX/TX handler 2016-09-16 04:31:51 -04:00
slave.c Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2016-12-03 12:29:53 -05:00
tag_brcm.c net: dsa: Add a ports structure and use it in the switch structure 2016-06-04 14:29:53 -07:00
tag_dsa.c net: dsa: Add a ports structure and use it in the switch structure 2016-06-04 14:29:53 -07:00
tag_edsa.c net: dsa: Add a ports structure and use it in the switch structure 2016-06-04 14:29:53 -07:00
tag_qca.c net-next: dsa: add Qualcomm tag RX/TX handler 2016-09-16 04:31:51 -04:00
tag_trailer.c net: dsa: Add a ports structure and use it in the switch structure 2016-06-04 14:29:53 -07:00