10 #include <satcat5/ip_core.h>
45 {
return &m_local_port; }
47 {
return &m_local_port; }
49 { m_defer_fwd = fwd; }
51 { m_local_iface = iface; }
53 { m_offload = iface; }
59 { m_port_shdn &= ~mask; }
61 { m_port_shdn |= mask; }
66 {
return m_local_iface; }
85 unsigned process_gateway(
89 unsigned deliver_defer(
91 unsigned deliver_local(
93 unsigned deliver_offload(
A shared-memory Ethernet switch based on the MultiBuffer class.
Abstract API for reading byte-streams and packets.
Abstract API for writing byte-streams and packets.
Protocol handler and dispatch unit for Internet Protocol v4 (IPv4).
Minimalist port adapter with no VLAN conversion.
Deferred packet-forwarding system for the IPv4 router.
Packet-processing pipeline for the IPv4 router.
void port_enable(const SATCAT5_PMASK_TYPE &mask)
Enable or disable specific port(s).
unsigned deliver(satcat5::io::MultiPacket *packet) override
Override the MultiBuffer::deliver() method.
satcat5::io::Readable * get_local_rd()
Link this dispatch unit to other parts of the IP/UDP stack.
void set_local_iface(satcat5::ip::Dispatch *iface)
Link this dispatch unit to other parts of the IP/UDP stack.
void set_offload(satcat5::router2::Offload *iface)
Link this dispatch unit to other parts of the IP/UDP stack.
void set_defer_fwd(satcat5::router2::DeferFwd *fwd)
Link this dispatch unit to other parts of the IP/UDP stack.
void port_disable(const SATCAT5_PMASK_TYPE &mask)
Enable or disable specific port(s).
satcat5::io::Writeable * get_local_wr()
Link this dispatch unit to other parts of the IP/UDP stack.
Dispatch(u8 *buff, unsigned nbytes)
Configure this object and link to the working buffer.
bool decrement_ttl(satcat5::eth::PluginPacket &meta)
Offload port for gateware-accelerated IPv4 routers.
Software-defined Ethernet switch.
#define SATCAT5_PMASK_TYPE
Set the integer type used to identify source and destination ports.
Adapter definitions for using generic I/O objects with eth::SwitchCore.
An Ethernet MAC address (with serializable interface).
Ephemeral data structure provided to plugin callbacks.
A packet is a linked-list of memory blocks, plus metadata.
IPv4 address is a 32-bit unsigned integer.