2
0
mirror of https://github.com/edk2-porting/linux-next.git synced 2024-12-28 07:04:00 +08:00
linux-next/drivers/net/ethernet
Petr Machata 35225e4740 mlxsw: spectrum_router: Make nexthops typed
In the router, some next hops may reference an encapsulating netdevice,
such as GRE or IPIP. To properly offload these next hops, mlxsw needs to
keep track of whether a given next hop is a regular Ethernet entry, or
an IP-in-IP tunneling entry.

To facilitate this book-keeping, add a type field to struct
mlxsw_sp_nexthop. There is, as of this patch, only one next hop type:
MLXSW_SP_NEXTHOP_TYPE_ETH. Follow-up patches will introduce the IP-in-IP
variant.

There are several places where next hops are initialized in the IPv4
path. Instead of replicating the logic at every one of them, factor it
out to a function mlxsw_sp_nexthop4_type_init(). The corresponding fini
is actually protocol-neutral, so put it to mlxsw_sp_nexthop_type_fini(),
but create a corresponding protocoled _fini function that dispatches to
the protocol-neutral one.

The IPv6 path is simpler, but for symmetry with IPv4, create the same
suite of functions with corresponding logic.

Signed-off-by: Petr Machata <petrm@mellanox.com>
Reviewed-by: Ido Schimmel <idosch@mellanox.com>
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2017-09-03 20:23:25 -07:00
..
3com net: 3c59x: constify eisa_device_id 2017-08-19 17:13:41 -07:00
8390 net: ethernet: ax88796: make mdiobb_ops const 2017-08-22 14:20:54 -07:00
adaptec
adi net: ethernet: make ptp_clock_info const 2017-08-22 11:04:51 -07:00
aeroflex networking: introduce and use skb_put_data() 2017-06-16 11:48:37 -04:00
agere networking: introduce and use skb_put_data() 2017-06-16 11:48:37 -04:00
alacritech
allwinner networking: make skb_put & friends return void pointers 2017-06-16 11:48:39 -04:00
alteon
altera
amazon net: ena: update ena driver to version 1.2.0 2017-06-23 14:15:11 -04:00
amd amd-xgbe: Interrupt summary bits are h/w version dependent 2017-08-29 15:31:10 -07:00
apm drivers: net: xgene: Correct probe sequence handling 2017-08-29 16:13:08 -07:00
apple net: Convert to using %pOF instead of full_name 2017-07-24 13:41:48 -07:00
aquantia Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-09-01 17:42:05 -07:00
arc net: arc_emac: Add support for ndo_do_ioctl net_device_ops operation 2017-08-03 15:14:34 -07:00
atheros net: atl1c: fix spelling mistake: "droppted" -> "dropped" 2017-06-29 12:24:26 -04:00
aurora net: ethernet: nb8800: Handle all 4 RGMII modes identically 2017-07-25 21:27:01 -07:00
broadcom net: systemport: Correctly set TSB endian for host 2017-09-01 20:19:32 -07:00
brocade
cadence net: ethernet: make ptp_clock_info const 2017-08-22 11:04:51 -07:00
calxeda
cavium liquidio: fix crash in presence of zeroed-out base address regs 2017-08-30 22:07:09 -07:00
chelsio Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-09-01 17:42:05 -07:00
cirrus networking: introduce and use skb_put_data() 2017-06-16 11:48:37 -04:00
cisco cisco: enic: Fic an error handling path in 'vnic_dev_init_devcmd2()' 2017-07-11 10:54:15 -07:00
davicom networking: make skb_put & friends return void pointers 2017-06-16 11:48:39 -04:00
dec net: de4x5: constify eisa_device_id 2017-08-19 17:13:41 -07:00
dlink
emulex benet: fix set but not used warning 2017-07-25 12:31:37 -07:00
ezchip
faraday Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-09-01 17:42:05 -07:00
freescale fsl/fman: make arrays port_ids static, reduces object code size 2017-09-01 18:21:09 -07:00
fujitsu
hisilicon net: hns3: Fixes the wrong IS_ERR check on the returned phydev value 2017-08-30 15:29:42 -07:00
hp net: hp100: constify eisa_device_id 2017-08-19 17:13:41 -07:00
huawei hinic: don't build the module by default 2017-08-28 21:39:52 -07:00
i825xx networking: introduce and use skb_put_data() 2017-06-16 11:48:37 -04:00
ibm net: ibm: emac: Fix some error handling path in 'emac_probe()' 2017-08-20 19:53:08 -07:00
intel i40e/i40evf: avoid dynamic ITR updates when polling or low packet rate 2017-08-27 16:15:24 -07:00
marvell net: mvpp2: fallback using h/w and random mac if the dt one isn't valid 2017-09-03 20:16:55 -07:00
mediatek net-next: mediatek: bring up QDMA RX ring 0 2017-08-09 22:45:36 -07:00
mellanox mlxsw: spectrum_router: Make nexthops typed 2017-09-03 20:23:25 -07:00
micrel networking: make skb_put & friends return void pointers 2017-06-16 11:48:39 -04:00
microchip
moxa net: moxa: Add spaces preferred around that '{+,-}' 2017-07-29 14:02:07 -07:00
myricom
natsemi
neterion s2io: Remove UFO support. 2017-07-17 09:52:57 -07:00
netronome Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-09-01 17:42:05 -07:00
nuvoton net/{mii, smsc}: Make mii_ethtool_get_link_ksettings and smc_netdev_get_ecmd return void 2017-06-05 11:00:42 -04:00
nvidia forcedeth: replace init_timer_deferrable with setup_deferrable_timer 2017-08-11 14:25:35 -07:00
nxp net: manual clean code which call skb_put_[data:zero] 2017-06-20 13:30:15 -04:00
oki-semi net/{mii, smsc}: Make mii_ethtool_get_link_ksettings and smc_netdev_get_ecmd return void 2017-06-05 11:00:42 -04:00
packetengines net: manual clean code which call skb_put_[data:zero] 2017-06-20 13:30:15 -04:00
pasemi
qlogic Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-09-01 17:42:05 -07:00
qualcomm net: qualcomm: rmnet: remove unused variable priv 2017-09-01 18:34:36 -07:00
rdc
realtek r8169: Be drop monitor friendly 2017-08-25 19:13:27 -07:00
renesas net: sh_eth: constify platform_device_id 2017-08-13 20:12:23 -07:00
rocker rocker: Ignore address families other than IPv4 2017-08-03 15:35:59 -07:00
samsung net: sxgbe: check memory allocation failure 2017-08-25 20:07:07 -07:00
seeq
sfc Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-08-15 20:23:23 -07:00
sgi ioc3-eth: store pointer to net_device for priviate area 2017-07-15 14:28:56 -07:00
silan networking: introduce and use skb_put_data() 2017-06-16 11:48:37 -04:00
sis net/{mii, smsc}: Make mii_ethtool_get_link_ksettings and smc_netdev_get_ecmd return void 2017-06-05 11:00:42 -04:00
smsc smsc911x: Add check for ioremap_nocache() return code 2017-07-12 14:35:43 -07:00
stmicro Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-09-01 17:42:05 -07:00
sun Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-08-01 10:07:50 -07:00
synopsys drivers: net: add missing interrupt.h include 2017-07-18 11:13:41 -07:00
tehuti net: tehuti: don't process data if it has not been copied from userspace 2017-07-19 22:48:02 -07:00
ti Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net 2017-09-01 17:42:05 -07:00
tile net: ethernet: make ptp_clock_info const 2017-08-22 11:04:51 -07:00
toshiba net: tc35815: fix spelling mistake: "Intterrupt" -> "Interrupt" 2017-07-29 15:22:08 -07:00
tundra net/{mii, smsc}: Make mii_ethtool_get_link_ksettings and smc_netdev_get_ecmd return void 2017-06-05 11:00:42 -04:00
via net/{mii, smsc}: Make mii_ethtool_get_link_ksettings and smc_netdev_get_ecmd return void 2017-06-05 11:00:42 -04:00
wiznet
xilinx net: Convert to using %pOF instead of full_name 2017-07-24 13:41:48 -07:00
xircom ethernet: xircom: small clean up in setup_xirc2ps_cs() 2017-08-22 10:30:00 -07:00
xscale
dnet.c networking: make skb_put & friends return void pointers 2017-06-16 11:48:39 -04:00
dnet.h
ec_bhf.c net: ec_bhf: constify pci_device_id. 2017-07-17 13:37:15 -07:00
ethoc.c net: ethoc: enable NAPI before poll may be scheduled 2017-06-06 16:22:51 -04:00
fealnx.c networking: introduce and use skb_put_data() 2017-06-16 11:48:37 -04:00
jme.c net/{mii, smsc}: Make mii_ethtool_get_link_ksettings and smc_netdev_get_ecmd return void 2017-06-05 11:00:42 -04:00
jme.h
Kconfig net-next/hinic: Initialize hw interface 2017-08-22 10:48:52 -07:00
korina.c net/{mii, smsc}: Make mii_ethtool_get_link_ksettings and smc_netdev_get_ecmd return void 2017-06-05 11:00:42 -04:00
lantiq_etop.c
Makefile net-next/hinic: Initialize hw interface 2017-08-22 10:48:52 -07:00
netx-eth.c