84 VlanPolicy* vptr,
unsigned vmax,
bool lockdown);
91 const unsigned m_vmax;
100 template <
unsigned VMAX = 4095>
Ethernet switch plugin API.
Ethernet port plugin API.
A shared-memory Ethernet switch based on the MultiBuffer class.
Generic packetized I/O interface for use with SwitchCore.
Port plugin for egress formatting of Virtual-LAN tags.
void egress(PluginPacket &pkt) override
Packet-transmit callback.
SwitchVlanEgress(satcat5::eth::SwitchPort *port)
Constructor links to a specified port.
Wrapper for SwitchVlanInner with statically-allocated working memory.
SwitchVlan(satcat5::eth::SwitchCore *sw, bool lockdown=false)
Create this plugin and link it to the designated switch.
Switch plugin for Virtual-LAN connectivity and rate-limiting rules.
void timer_event() override
Child class MUST override this method.
void vlan_reset(bool lockdown=false)
Revert to default VLAN settings for all ports and VIDs.
VtagPolicy vlan_get_port(unsigned port) const
Query a port's tag policy and other VLAN settings.
SATCAT5_PMASK_TYPE vlan_get_mask(u16 vid)
Get allowed-connectivity port-mask for designated VID.
void vlan_leave(u16 vid, unsigned port)
Port should leave VLAN, updating vlan_get_mask.
void vlan_set_port(const VtagPolicy &cfg)
Set a port's tag policy and other VLAN settings.
void vlan_join(u16 vid, unsigned port)
Port should join VLAN, updating vlan_get_mask.
void vlan_set_rate(u16 vid, const satcat5::eth::VlanRate &cfg)
Set rate-limiting options for the designated VID.
void vlan_set_mask(u16 vid, SATCAT5_PMASK_TYPE mask)
Limit the specified VID to the designated port(s).
void query(PluginPacket &pkt) override
Packet-received callback.
Timer objects are polled after a fixed delay or at a regular interval.
Plugins for the software-defined Ethernet switch and IPv4 router.
#define SATCAT5_PMASK_TYPE
Set the integer type used to identify source and destination ports.
Ephemeral data structure provided to plugin callbacks.
Data structure for configuring VLAN rate-limiter parameters.
Data structure for configuring VLAN tagging policy of each port.