linux/drivers/net/ethernet
Ido Schimmel e5ec6a2513 mlxsw: spectrum_router: Fix IPv4 nexthop gateway indication
mlxsw needs to distinguish nexthops with a gateway from connected
nexthops in order to write the former to the adjacency table of the
device. The check used to rely on the fact that nexthops with a gateway
have a 'link' scope whereas connected nexthops have a 'host' scope. This
is no longer correct after commit 747c143072 ("ip: fix dflt addr
selection for connected nexthop").

Fix that by instead checking the address family of the gateway IP. This
is a more direct way and also consistent with the IPv6 counterpart in
mlxsw_sp_rt6_is_gateway().

Cc: stable@vger.kernel.org
Fixes: 747c143072 ("ip: fix dflt addr selection for connected nexthop")
Fixes: 597cfe4fc3 ("nexthop: Add support for IPv4 nexthops")
Signed-off-by: Ido Schimmel <idosch@nvidia.com>
Reviewed-by: Amit Cohen <amcohen@nvidia.com>
Reviewed-by: Nicolas Dichtel <nicolas.dichtel@6wind.com>
Reviewed-by: David Ahern <dsahern@kernel.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
2022-07-20 11:00:46 +01:00
..
3com eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
8390
actions
adaptec eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
aeroflex
agere
alacritech slic: remove a copy of the NAPI_POLL_WEIGHT define 2022-04-29 11:56:41 +01:00
allwinner
alteon
altera net: altera: Fix refcount leak in altera_tse_mdio_create 2022-06-08 20:52:41 -07:00
amazon eth: remove remaining copies of the NAPI_POLL_WEIGHT define 2022-04-30 14:00:45 +01:00
amd amd-xgbe: Use platform_irq_count() 2022-06-13 23:12:39 -07:00
apm
apple net: ethernet: Prepare cleanup of powerpc's asm/prom.h 2022-05-05 15:53:02 -07:00
aquantia net: atlantic: remove aq_nic_deinit() when resume 2022-07-14 13:03:21 +02:00
arc eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
asix
atheros eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
broadcom bnxt_en: Fix bnxt_refclk_read() 2022-07-12 20:35:56 -07:00
brocade eth: remove remaining copies of the NAPI_POLL_WEIGHT define 2022-04-30 14:00:45 +01:00
cadence Merge git://git.kernel.org/pub/scm/linux/kernel/git/netdev/net 2022-05-23 21:19:17 -07:00
calxeda net: calxedaxgmac: Fix typo (doubled "the") 2022-04-11 20:49:21 -07:00
cavium net: thunderx: remove null check after call container_of() 2022-05-17 17:39:49 -07:00
chelsio tcp: Fix data-races around sysctl knobs related to SYN option. 2022-07-20 10:14:49 +01:00
cirrus cirrus: cs89x0: fix typo in comment 2022-05-22 20:44:29 +01:00
cisco
cortina eth: remove copies of the NAPI_POLL_WEIGHT define 2022-04-29 11:56:41 +01:00
davicom
dec eth: de4x5: remove support for Generic DECchip & DIGITAL EtherWORKS PCI/EISA 2022-05-23 11:43:51 +01:00
dlink
emulex be2net: Fix buffer overflow in be_get_module_eeprom 2022-07-19 11:51:16 +02:00
engleder tsnep: Add free running cycle counter support 2022-05-10 09:48:09 +02:00
ezchip eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
faraday net: ftgmac100: Hold reference returned by of_get_child_by_name() 2022-07-13 13:29:07 +01:00
freescale net: enetc: Use pci_release_region() to release some resources 2022-05-28 20:20:42 +01:00
fujitsu
fungible net: switch to netif_napi_add_tx() 2022-05-05 15:54:12 -07:00
google
hisilicon net: hns3: fix tm port shapping of fibre port is incorrect after driver initialization 2022-06-13 11:56:01 +01:00
huawei hinic: Replace memcpy() with direct assignment 2022-06-22 11:04:32 -07:00
i825xx
ibm ibmvnic: Properly dispose of all skbs during a failover. 2022-07-04 11:09:57 +01:00
intel Merge branch '40GbE' of git://git.kernel.org/pub/scm/linux/kernel/git/tnguy/net-queue 2022-07-19 17:43:02 -07:00
litex
marvell net: prestera: acl: use proper mask for port selector 2022-07-18 11:44:32 +01:00
mediatek net: ethernet: mtk_ppe: fix possible NULL pointer dereference in mtk_flow_get_wdma_info 2022-07-19 17:27:18 -07:00
mellanox mlxsw: spectrum_router: Fix IPv4 nexthop gateway indication 2022-07-20 11:00:46 +01:00
micrel net: micrel: Fix KS8851 Kconfig 2022-04-05 17:32:05 -07:00
microchip net: lan966x: Fix usage of lan966x->mac_lock when used by FDB 2022-07-18 20:00:00 -07:00
microsoft eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
moxa eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
mscc net: ocelot: fix wrong time_after usage 2022-07-07 18:05:36 -07:00
myricom eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
natsemi net: remove comments that mention obsolete __SLOW_DOWN_IO 2022-04-26 17:09:24 -07:00
neterion Revert "drivers/net/ethernet/neterion/vxge: Fix a use-after-free bug in vxge-main.c" 2022-06-22 13:15:49 +01:00
netronome ip: Fix data-races around sysctl_ip_default_ttl. 2022-07-15 11:49:55 +01:00
ni
nvidia eth: remove remaining copies of the NAPI_POLL_WEIGHT define 2022-04-30 14:00:45 +01:00
nxp eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
oki-semi eth: pch_gbe: remove a copy of the NAPI_POLL_WEIGHT define 2022-04-29 11:56:41 +01:00
packetengines
pasemi
pensando ionic: fix missing pci_release_regions() on error in ionic_probe() 2022-05-09 15:49:12 -07:00
qlogic Bitmap patches for 5.19-rc1 2022-06-04 14:04:27 -07:00
qualcomm
rdc
realtek r8169: fix accessing unset transport header 2022-07-06 19:53:21 -07:00
renesas ravb: Add support for RZ/V2M 2022-05-16 10:14:27 +01:00
rocker net: switch to netif_napi_add_tx() 2022-05-05 15:54:12 -07:00
samsung
seeq
sfc sfc: fix kernel panic when creating VF 2022-07-14 12:46:56 +02:00
sgi
silan
sis
smsc epic100: fix use after free on rmmod 2022-06-27 21:48:51 -07:00
socionext net: switch to netif_napi_add_tx() 2022-05-05 15:54:12 -07:00
stmicro net: stmmac: remove redunctant disable xPCS EEE call 2022-07-18 20:15:45 -07:00
sun net: sunhme: output link status with a single print. 2022-07-13 14:53:48 +01:00
sunplus net: ethernet: SP7021: fix a use after free of skb->len 2022-05-19 17:46:56 -07:00
synopsys net: allow gso_max_size to exceed 65536 2022-05-16 10:18:55 +01:00
tehuti
ti net: ethernet: ti: am65-cpsw: Fix devlink port register sequence 2022-07-07 17:21:44 -07:00
toshiba eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
tundra
vertexcom
via eth: velocity: remove a copy of the NAPI_POLL_WEIGHT define 2022-04-29 11:56:42 +01:00
wiznet eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
xilinx net: axienet: add missing error return code in axienet_probe() 2022-06-16 11:08:38 -07:00
xircom
xscale eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
dnet.c
dnet.h
ec_bhf.c
ethoc.c
fealnx.c
jme.c jme: remove an unnecessary indirection 2022-05-05 15:53:28 -07:00
jme.h jme: remove an unnecessary indirection 2022-05-05 15:53:28 -07:00
Kconfig net: ethernet: Add driver for Sunplus SP7021 2022-05-10 11:31:32 +02:00
korina.c
lantiq_etop.c eth: switch to netif_napi_add_weight() 2022-05-08 11:33:57 +01:00
lantiq_xrx200.c net: switch to netif_napi_add_tx() 2022-05-05 15:54:12 -07:00
Makefile net: ethernet: Add driver for Sunplus SP7021 2022-05-10 11:31:32 +02:00