mirror of
https://github.com/AuxXxilium/linux_dsm_epyc7002.git
synced 2024-12-16 08:06:44 +07:00
111cf1ab4d
CPSW switchdev based driver which is operating in dual-emac mode by default, thus working as 2 individual network interfaces. The Switch mode can be enabled by configuring devlink driver parameter "switch_mode" to 1: devlink dev param set platform/48484000.switch \ name switch_mode value 1 cmode runtime This can be done regardless of the state of Port's netdevs - UP/DOWN, but Port's netdev devices have to be UP before joining the bridge to avoid overwriting of bridge configuration as CPSW switch driver completely reloads its configuration when first Port changes its state to UP. When the both interfaces joined the bridge - CPSW switch driver will start marking packets with offload_fwd_mark flag unless "ale_bypass=0". All configuration is implemented via switchdev API and notifiers. Supported: - SWITCHDEV_ATTR_ID_PORT_PRE_BRIDGE_FLAGS - SWITCHDEV_ATTR_ID_PORT_BRIDGE_FLAGS: BR_MCAST_FLOOD - SWITCHDEV_ATTR_ID_PORT_STP_STATE - SWITCHDEV_OBJ_ID_PORT_VLAN - SWITCHDEV_OBJ_ID_PORT_MDB - SWITCHDEV_OBJ_ID_HOST_MDB Hence CPSW switchdev driver supports: - FDB offloading - MDB offloading - VLAN filtering and offloading - STP Signed-off-by: Ilias Apalodimas <ilias.apalodimas@linaro.org> Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: David S. Miller <davem@davemloft.net>
16 lines
465 B
C
16 lines
465 B
C
/* SPDX-License-Identifier: GPL-2.0 */
|
|
/*
|
|
* Texas Instruments Ethernet Switch Driver
|
|
*/
|
|
|
|
#ifndef DRIVERS_NET_ETHERNET_TI_CPSW_SWITCHDEV_H_
|
|
#define DRIVERS_NET_ETHERNET_TI_CPSW_SWITCHDEV_H_
|
|
|
|
#include <net/switchdev.h>
|
|
|
|
bool cpsw_port_dev_check(const struct net_device *dev);
|
|
int cpsw_switchdev_register_notifiers(struct cpsw_common *cpsw);
|
|
void cpsw_switchdev_unregister_notifiers(struct cpsw_common *cpsw);
|
|
|
|
#endif /* DRIVERS_NET_ETHERNET_TI_CPSW_SWITCHDEV_H_ */
|