RZT Flexible Software Package Documentation
Release v2.2.0
|
|
Provides API for using Ethernet Switch. It implements the Ethernet Switch Interface.
With the ethernet switch function, this LSI enables to build the network topology such as line type without external switching hub.
Configuration | Options | Default | Description |
---|---|---|---|
Parameter Checking |
| Default (BSP) | If selected code for parameter checking is included in the build. |
Configuration | Options | Default | Description |
---|---|---|---|
Management > Management port specific tag |
| Disabled | Enable or Disable management port specific tag. |
Management > Management port specific tag ID | Specify a value between 0x1 and 0xFFFF. | 0xE001 | Select management port specific tag ID. |
Interrupts > Interrupt Priority | MCU Specific Options | Select the interrupt priority. | |
Interrupts > Callback | Name must be a valid C symbol | NULL | Select the callback function provided when an interrupt occurs |
Interrupts > Context | Name must be a valid C symbol | NULL | Select the argument of callback, is void* type |
Name | Name must be a valid C symbol | g_ethsw0 | Module name. |
Channel | 0 | 0 | Select the Ethernet controller channel number. |
Link signal change |
| Disable | Enable or disable callback by PHYLINK change. |
Developers should be aware of the following limitations when using the ETHSW:
Macros | |
#define | ETHSW_PORT_MGMT |
Management port number. More... | |
#define | ETHER_SWITCH_TDMA_GPIO_COUNT |
Noumber of TDMA_GPIO. | |
#define | ETHSW_QUEUE_COUNT |
Number of queues ETHSW has. | |
#define | ETHSW_QUEUE_COUNT |
Number of queues ETHSW has. | |
#define | ETHSW_TDMA_GPIO_COUNT |
Number of TDMA_GPIO. | |
Typedefs | |
typedef uint8_t | ethsw_mac_addr_t[ETHSW_MAC_ADDR_LENGTH] |
typedef uint8_t | ethsw_mmctl_qclosed_nonempty_t[4] |
Enumerations | |
enum | ethsw_specific_tag_t |
enum | ethsw_phylink_t |
enum | ethsw_link_speed_t |
enum | ethsw_mac_table_clear_mode_t |
enum | ethsw_link_status_t |
enum | ethsw_dlr_event_t |
enum | ethsw_dlr_beacon_state_t |
enum | ethsw_dlr_node_state_t |
enum | ethsw_rx_pattern_mode_t |
enum | ethsw_rx_pattern_event_t |
enum | ethsw_preempt_verify_status_t |
enum | ethsw_mmctl_qgate_action_t |
enum | ethsw_mmctl_pool_id_t |
enum | ethsw_queu_flush_action_t |
enum | ethsw_snoop_offset_type_t |
enum | ethsw_snoop_comp_type_t |
enum | ethsw_snoop_action_t |
enum | ethsw_snoop_operat_t |
enum | ethsw_mirr_mode_t |
enum | ethsw_vlan_in_mode_t |
enum | ethsw_vlan_out_mode_t |
enum | ethsw_tdma_event_t |
enum | ethsw_tdma_gpio_mode_t |
enum | ethsw_time_event_t |
struct ethsw_instance_ctrl_t |
ETHER SWITCH control block. DO NOT INITIALIZE. Initialization occurs when ether_switch_api_t::open is called.
Data Fields | ||
---|---|---|
uint32_t | open | Used to determine if the channel is configured. |
ether_switch_cfg_t const * | p_switch_cfg | Pointer to initial configurations. |
R_ETHSW_Type * | p_reg_switch | Pointer to Ethernet Switch peripheral registers. |
R_ETHSS_Type * | p_reg_ethss | Pointer to Ethernet Subsystem peripheral registers. |
R_ETHSW_PTP_Type * | p_reg_ethsw_ptp | Pointer to PTP Timer Pulse Control Registers. |
struct ethsw_extend_cfg_t |
Extend Configuration parameters.
Data Fields | ||
---|---|---|
ethsw_specific_tag_t | specific_tag | Enable or Disable Management port specific frmame tag. |
uint16_t | specific_tag_id | Management port specific frmame tag ID, when specific_tag is enable. |
ethsw_phylink_t | phylink |
struct ethsw_port_mask_t |
struct ethsw_mac_table_entry_addr_t |
Address in MAC table entry
Data Fields | ||
---|---|---|
ethsw_mac_addr_t * | mac_addr | MAC address pointer. |
uint16_t | vlan_id | VLAN ID. |
struct ethsw_mac_table_entry_info_t |
Information in MAC table entry
Data Fields | ||
---|---|---|
ethsw_port_mask_t | port_mask | port mask |
uint32_t | priority | switching priority |
struct ethsw_mac_table_config_t |
MAC table config
struct ethsw_flood_unknown_config_t |
Flood domain configuration for unknown frames
Data Fields | ||
---|---|---|
ethsw_port_mask_t | port_mask_bcast | flood domain port mask for broadcasts with unkown destination |
ethsw_port_mask_t | port_mask_mcast | flood domain port mask for multicasts with unkown destination |
ethsw_port_mask_t | port_mask_ucast | flood domain port mask for unicasts with unkown destination |
struct ethsw_dlr_init_t |
DLR initilize
Data Fields | |
ethsw_mac_addr_t * | p_host_addr |
host MAC address pointer | |
struct ethsw_rx_pattern_ctrl_t |
RX Pattern Matcher Function Control
Data Fields | ||
---|---|---|
bool | match_not | The functions of this control are executed if the pattern does not match. |
bool | mgmt_fwd | The frame is forwarded to the management port only. |
bool | discard | The frame is discarded. |
bool | set_prio | Set frame priority, overriding normal classification. |
ethsw_rx_pattern_mode_t | mode | Operating mode. |
bool | timer_sel_ovr | Overrides the default timer to use by timestamp operations. |
bool | force_forward | The frame is forwarded to the ports indicated in PORTMASK,. |
bool | hub_trigger | The port defined in the PORTMASK setting is allowed for transmitting one frame. Usable for Hub mode only. |
bool | match_red | Enable the pattern matcher only when the TDMA indicates that this is the RED period. |
bool | match_not_red | Enable the pattern matcher only when the TDMA indicates that this is not the RED period. |
bool | vlan_skip | Skips VLAN tag (4 bytes) |
uint8_t | priority | Priority of the frame used when SET_PRIO is set. |
bool | learning_dis | The hardware learning function is not executed. |
ethsw_port_mask_t | port_mask | A port mask used depending on the control bits (for example, HUBTRIGGER). |
bool | imc_trigger | The ports defined in the PORTMASK setting are allowed for transmitting one frame from the queues indicated by QUEUESEL. |
bool | imc_trigger_dely | The ports defined in the PORTMASK setting are allowed for transmitting one frame from the queues indicated by QUEUESEL. Delayed by the value programmed in MMCTL_DLY_QTRIGGER_CTRL. |
bool | swap_bytes | The byte order is swapped from the order received by the frame. |
bool | match_lt | The Length/Type field in the frame is compared against the value in length_type in the compare register. |
uint8_t | timer_sel | Override value to use when TIMER_SEL_OVR is set to 1 for selecting the timer for this frame. |
uint8_t | queue_sel | A queue selector for the HUBTRIGGER function. |
union ethsw_rx_pattern_data_t |
RX Pattern Matcher Function Data
struct ethsw_rx_pattern_matcher_t |
The parameter for set/get the Rx pattern matcher function
Data Fields | ||
---|---|---|
uint16_t | pattern_sel | Pattern matcher number (0..11) |
ethsw_port_mask_t | pattern_port_mask | Port mask. |
bool | pattern_int | When true, called back from ISR. |
ethsw_rx_pattern_ctrl_t * | p_pattern_ctrl | RX Pattern Matcher Function Control. |
ethsw_rx_pattern_data_t * | p_pattern_data | RX Pattern Matcher Function Data. |
struct ethsw_rx_pattern_event_data_t |
struct ethsw_preempt_queue_t |
The parameter for set preemptable queue
struct ethsw_preempt_port_ctrl_config_t |
The parameter for set frame configuration of frame preemption for each ports
struct ethsw_preempt_status_t |
The parameter for get preemption status
Data Fields | ||
---|---|---|
ethsw_preempt_verify_status_t | verify_status | |
bool | preempt_state | A per-port bit that indicates if a port is in a preempted state. This is a real-time indication meant for debugging. |
bool | hold_req_state | A per-port bit that indicates if a port is preempted using MM_CTL.request (hold_req). This isa real-time indication meant for debugging. |
uint8_t | min_pfrm_adj | Adjust the minimum mPacket length, in increments of 4 bytes. |
uint8_t | last_pfrm_adj | Adjust the preemptable threshold when reaching the end of the frame, in increments of 4 bytes. Incrementing this value increments the length of the last mPacket. |
struct ethsw_mmclt_qgate_t |
queue gate
Data Fields | ||
---|---|---|
ethsw_port_mask_t | port_mask | Per-port bit mask. |
ethsw_mmctl_qgate_action_t | action[ETHSW_QUEUE_COUNT] | Gate action for queue number 0..7. |
struct ethsw_mmctl_pool_size_t |
The parameter for set/get memory pool size function
Data Fields | ||
---|---|---|
ethsw_mmctl_pool_id_t | pool_id | MMCTL pool ID. |
uint16_t | cells | Memory pool size, in sells. |
struct ethsw_mmctl_queue_assign_t |
The parameter for function that assins a memory pool for a queue.
Data Fields | ||
---|---|---|
uint8_t | queue_num | Queue number. |
ethsw_mmctl_pool_id_t | pool_id | MMCTL pool ID. |
struct ethsw_yellow_length_t |
struct ethsw_queue_flush_event_t |
The parameter for set / get queue flush event.
Data Fields | ||
---|---|---|
ethsw_port_mask_t | port_mask | Per-port bit mask. |
uint8_t | queue_mask | 1 bit per queue indicating for which queues of the ports indicated by port_mask the flush state is changed as indicated in action. |
ethsw_queu_flush_action_t | action | Selects the flush state for the queues indicated by queue_mask in the ports indicated by port_mask. |
struct ethsw_cqf_enable_t |
The parameter for set CQF enable configuration
Data Fields | ||
---|---|---|
union ethsw_cqf_enable_t | __unnamed__ | |
uint8_t | cqf_queue | Select which two physical queues are used for CQF. The queues used are QUEUE_SEL0 and QUEUE_SEL0 + 1. Frames are written into QUEUE_SEL0 when the gate control selected with GATE_SEL0 is 0, and into QUEUE_SEL0 + 1 when the gate control is 1. |
uint8_t | cqf_gate_sel | Select which gate control signal is used for selecting the output queue (these signals are the same as the ETHSW_TDMAOUT pins). |
bool | use_sop | When set to 1, the CFQ queue is determined when the SOP is received at the frame writerin the memory controller. When set to 0, the queue is determined when the EOP is received at the frame writer. |
bool | cqf_gate_ref_sel | Select whether the gate control signal used for the CQF group is based on the egress port when set to 0, or the ingress port when set to 1. |
struct ethsw_snoop_parser_config_t |
Snoop parser config
Data Fields | ||
---|---|---|
uint8_t | arith_block | Arithmetic blkoc ID (0..1). |
uint8_t | parser_id | Parser ID (0..3). |
bool | enable | true:enble, false:disable. |
ethsw_snoop_offset_type_t | offs_type | Snooping mode. |
ethsw_snoop_comp_type_t | comp_type | How to handle matched frames. |
uint8_t | offset | An offset in bytes to locate the data for comparison within the frame. |
uint8_t | comp_value | The value to compare the frame data with at the given offset. |
uint8_t | mask_value2 | When ETHSW_SNOOP_COMP_8, bitmask for single byte compares. When ETHSW_SNOOP_COMP_8OR, 2nd compare value. When ETHSW_SNOOP_COMP_16 or ETHSW_SNOOP_COMP_16PLUS, least significant bits of a 16-bit compare value. |
struct ethsw_snoop_arith_config_t |
Snoop arithmetic config
Data Fields | ||
---|---|---|
uint8_t | arith_block | Arithmetic blkoc ID (0..1). |
ethsw_snoop_operat_t | operat | Operation of paraser result. |
ethsw_snoop_action_t | action | Arithmetic action. |
struct ethsw_eee_t |
struct ethsw_qos_mode_t |
struct ethsw_qos_prio_ip_t |
struct ethsw_qos_prio_type_t |
QoS Ethertype priority
struct ethsw_mirror_conf_t |
mirror port config
Data Fields | ||
---|---|---|
uint32_t | mirror_port | The port id that will received all mirrored frames. |
ethsw_mirr_mode_t | mirror_mode | The mode of mirroring to configure. |
ethsw_port_mask_t | port_map | The port map to which the mirror configuration will be applied to. |
ethsw_mac_addr_t * | mac_addr | MAC address pointer. |
struct ethsw_ts_pulse_generator_t |
The parameter for set/get pulse generator.
union ethsw_tdma_callback_data_t |
struct ethsw_tdma_enable_t |
tdma enable parameter
Data Fields | |
bool | enable |
True is enable, false:disabel. | |
uint8_t | time_num |
Timer number to use as TDMA time source. | |
ethsw_port_mask_t | port_mask |
Port mask that TDMA operat. | |
uint32_t | tdma_start |
Start nano time for the first cycle of TDMA. | |
uint32_t | tdma_modulo |
System timer modulo for 1 second. | |
uint32_t | tdma_cycle |
Periodic cycle time for TDMA scheduler. | |
struct ethsw_tdma_schedule_entry_t |
TDMA schedule entry parameter
Data Fields | ||
---|---|---|
uint32_t | time_offset | Time offset from the TDMA Cycle Start. |
ethsw_port_mask_t | port_mask | Bit mask (one per output port) that controls which queues of the ports are gated, triggered, hold request generation, and which ports change their Cut-Through mode setting. |
uint8_t | gate_state | Bit mask, gate state of queue 0 to 7 (bit0:queue0, bit1:queue1, .., bit7:queue7). Value 0 is close, value 1 is open. |
uint8_t | gpio_mask | Generic bits that control the output pins ETHSW_TDMAOUT0..3. |
bool | interrupt | Indicates this entry generates an interrupt to the CPU when activated. |
bool | hold_req | Preemption hold request. Generates a hold request to ports enabled in port_mask. |
bool | gate_mode | Gate mode enable when set to 1. |
bool | trigger_mode | Trigger mode enable when set to 1. GATE_MODE must be 0, otherwise, GATE_MODE has precedence. |
bool | in_ct_ena | Input Cut-Through Enable. |
bool | out_ct_ena | Output Cut-Through Enable. |
bool | red_period | Period Color Control (for Profinet IRT) |
bool | inc_crt1 | Increment Control for Counter 1. |
bool | inc_crt0 | Increment Control for Counter 0. |
struct ethsw_tdma_counter1_t |
The parameter for set/get TDMA counter 1 function
struct ethsw_time_enable_t |
struct ethsw_timestamp_t |
struct ethsw_time_transmit_t |
Transmit timestamp parameter
Data Fields | |
ethsw_port_mask_t | port_mask |
(Bit0=Port0, Bit1=Port1, Bit2=Port2) More... | |
void(* | p_time_callback )(ethsw_time_event_t event, uint32_t port, ethsw_timestamp_t *p_timestamp) |
Pointer to the timestamp parameter. | |
ethsw_port_mask_t ethsw_time_transmit_t::port_mask |
(Bit0=Port0, Bit1=Port1, Bit2=Port2)
Per Port Transmit Timestamp Capture Interrupt Enable.
struct ethsw_time_peerdelay_t |
struct ethsw_time_offset_correction_t |
struct ethsw_time_rate_correction_t |
#define ETHSW_PORT_MGMT |
Management port number.
Ethernet port macros
typedef uint8_t ethsw_mac_addr_t[ETHSW_MAC_ADDR_LENGTH] |
MAC address
typedef uint8_t ethsw_mmctl_qclosed_nonempty_t[4] |
The parameter for QclosedNonempty status
enum ethsw_specific_tag_t |
enum ethsw_phylink_t |
enum ethsw_link_speed_t |
Speed and duplex of the port
enum ethsw_link_status_t |
enum ethsw_dlr_event_t |
DLR events for the DLR State Machine
Operating mode of RX Pattern Matcher
Port status of verification for frame preemption
queue gate action
The action of queue flush event.
enum ethsw_snoop_action_t |
enum ethsw_snoop_operat_t |
enum ethsw_mirr_mode_t |
port mirroring modes
enum ethsw_vlan_in_mode_t |
enum ethsw_tdma_event_t |
enum ethsw_time_event_t |
Timer callback event
fsp_err_t R_ETHSW_Open | ( | ether_switch_ctrl_t *const | p_ctrl, |
ether_switch_cfg_t const *const | p_cfg | ||
) |
Open the switch ports and gets it ready to pass through the frames.
FSP_SUCCESS | Channel opened successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER SWITCH control block or configuration structure is NULL. |
FSP_ERR_ALREADY_OPEN | Control block has already been opened or channel is being used by another instance. Call close() then open() to reconfigure. |
FSP_ERR_INVALID_CHANNEL | Invalid channel number is given. |
FSP_ERR_INVALID_ARGUMENT | Interrupt is not enabled. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_Close | ( | ether_switch_ctrl_t *const | p_ctrl | ) |
Close the switch ports
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened |
fsp_err_t R_ETHSW_SpeedCfg | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t const | port, | ||
ethsw_link_speed_t const | speed | ||
) |
Configs speed and duplex of the port
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_MacTableSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mac_table_entry_addr_t * | p_mac_entry_addr, | ||
ethsw_mac_table_entry_info_t * | p_mac_entry_info | ||
) |
Sets the static MAC address entry for the given MAC address.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_TIMEOUT | Timeout error |
fsp_err_t R_ETHSW_MacTableGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mac_table_entry_addr_t * | p_mac_entry_addr, | ||
ethsw_mac_table_entry_info_t * | p_mac_entry_info | ||
) |
Retrieves the port mask for the given MAC address from the static MAC table.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_TIMEOUT | Timeout error |
fsp_err_t R_ETHSW_MacTableConfigSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mac_table_config_t * | p_mac_table_config | ||
) |
Configures the MAC learning and aging parameters of MAC table.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_MacTableClear | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mac_table_clear_mode_t * | p_mac_table_clear | ||
) |
Clears specific types of entries from the MAC table or clears the whole table.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
FSP_ERR_TIMEOUT | Timeout error |
fsp_err_t R_ETHSW_LearningSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
bool | enable | ||
) |
Sets learning state for the given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PortForwardAdd | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port | ||
) |
Enables the forwarding of incoming frames on a port for RSTP.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PortForwardDel | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port | ||
) |
Disables the forwarding of incoming frames on a port for RSTP
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_FloodUnknownSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_flood_unknown_config_t * | p_flood_config | ||
) |
Set the flood domain port masks for frames with unknown destinations
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_LinkStateGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_link_status_t * | p_state_link | ||
) |
Return link state for given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_FrameSizeMaxSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
uint32_t | frame_size_max | ||
) |
Sets maximum frame size of given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_DlrInitSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_dlr_init_t * | p_dlr_init | ||
) |
Initialize DLR module
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_TIMEOUT | Timeout error |
fsp_err_t R_ETHSW_DlrUninitSet | ( | ether_switch_ctrl_t *const | p_ctrl | ) |
Uninitialize DLR module
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_TIMEOUT | Timeout error |
fsp_err_t R_ETHSW_DlrEnableSet | ( | ether_switch_ctrl_t *const | p_ctrl | ) |
Enable DLR module
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_DlrDisableSet | ( | ether_switch_ctrl_t *const | p_ctrl | ) |
Disable DLR module.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_DlrBeaconStateGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_dlr_beacon_state_t * | p_beacon_state | ||
) |
Gets the beacon receive status of the specified port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_DlrNodeStateGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_dlr_node_state_t * | p_node_state | ||
) |
Gets DLR node status.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_DlrSvIpGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t * | p_ip_addr | ||
) |
Gets IP address of DLR supervisor.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_DlrSvPriorityGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint8_t * | p_priority | ||
) |
Gets preference of DLR supervisor.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_DlrVlanGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint16_t * | p_vlan_info | ||
) |
Gets VLAN ID of DLR beacon frame.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_DlrSvMacGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mac_addr_t * | pp_addr_mac | ||
) |
Gets MAC address of DLR beacon frame.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_RxPatternMatcherSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_rx_pattern_matcher_t * | p_rx_pattern_matcher | ||
) |
Sets Rx pattern matcher
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_RxPatternMatcherCallback | ( | ether_switch_ctrl_t *const | p_ctrl, |
void(*)(ethsw_rx_pattern_event_t event, ethsw_rx_pattern_event_data_t *p_data) | p_rx_pattern_callback_func | ||
) |
Register the callback function for getting events from Rx pattern matcher. Unregister if NULL is specified in the callback function.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_PreemptQueueSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_preempt_queue_t * | p_preempt_queue | ||
) |
Set Preemptable queues configures
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_PreemptPortControlConfigSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_preempt_port_ctrl_config_t * | p_preempt_port_ctrl | ||
) |
Set Qbu frame configuration of each ports
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PreemptPortControlEnableSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
bool | frame_preempt_enable | ||
) |
Enable/Disable Qbu frame preempt at each ports
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PreemptHoldReqForceSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_port_mask_t | holdreq_request_port_mask | ||
) |
forces a preempt request using MM_CTL.request(hold_req).
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PreemptHoldReqReleaseSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_port_mask_t | holdreq_release_port_mask | ||
) |
forces a release of preemption request using MM_CTL.request(hold_req).
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PreemptStatusGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_preempt_status_t * | p_preempt_status | ||
) |
Get a status of frame preemption
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_MmctlQgateSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mmclt_qgate_t * | p_mmctl_qgate | ||
) |
Sets queue gate.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_MmctlPoolSizeSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mmctl_pool_size_t * | p_pool_size | ||
) |
Sets memory pool size, in sells
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_MmctlQueueAssignSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mmctl_queue_assign_t * | p_queue_assign | ||
) |
Assigns a pool to the specified queue.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_MmctlYellowLengthSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_yellow_length_t * | p_yellow_length | ||
) |
Sets length in bytes of the YELLOW period for specified port.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_QueueFlushEventSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_queue_flush_event_t * | p_queue_flush_event | ||
) |
Sets Queue Flush Event.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_MmctlQueueClosedNonemptyStatusGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mmctl_qclosed_nonempty_t * | p_qclosed_nonempty | ||
) |
Get the status shows whether there are frames left in the closed queue.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_StatisticsSwitchGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
bool | clear, | ||
ethsw_statistics_switch_base_t * | p_statistics_switch | ||
) |
Gets Switch Base Statistics counters.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_StatisticsMacGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_statistics_mac_t * | p_statistics_mac | ||
) |
Gets MAC Statistics counters for the specified port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_StatisticsMacClear | ( | ether_switch_ctrl_t *const | p_ctrl | ) |
Clears MAC Statistics counters for all ports.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_Statistics8023brGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
bool | clear, | ||
ethsw_statistics_8023br_t * | p_statistics_8023br | ||
) |
Gets Global Discard and 802.3br Statistics counters.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_StatisticsDlrGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_statistics_dlr_t * | p_statistics_dlr | ||
) |
Gets DLR Statistics counters for the specified port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_CqfEnableSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_cqf_enable_t * | p_cqf_enable | ||
) |
Sets enable CQF.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_SnoopParserSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_snoop_parser_config_t * | p_parser_cnf | ||
) |
Sets a snooping parser configuration
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_SnoopArithSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_snoop_arith_config_t * | p_arith_cnf | ||
) |
Sets snooping arithmetic configuration
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_EeeSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_eee_t * | p_cnf_eee | ||
) |
Enables/disables and configure the Energy Efficient Ethernet Mode of the switch.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_StormTimeSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint16_t | storm_time | ||
) |
Sets the timeframe for the broadcast/multicast rate limiting in ms.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_BcastLimitSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint16_t | storm_frames | ||
) |
Sets the max. allowed broadcast frames that can be received in a given time.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_McastLimitSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint16_t | storm_frames | ||
) |
Sets the max. allowed multicast frames that can be received in a given time.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_TxRateSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
float | rate | ||
) |
Sets the max. allowed bandwidth for the given port in percent.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_QosModeSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_qos_mode_t * | p_qos_mode | ||
) |
Sets the priority resolution mode to use for a specific port. It also defines the default priority if no priority resolution produced a result.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_QosPrioValnSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_qos_prio_vlan_t * | p_qos_prio_vlan | ||
) |
Sets the priority mapping between VLAN tag priorities and the switch core priorities.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_QosPrioIpSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_qos_prio_ip_t * | p_qos_prio_ip | ||
) |
Sets the priority for the given DiffServ field of an IP packet for the given port. Up to 64 different DiffServ entries may be defined per port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_QosPrioTypeSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_qos_prio_type_t * | p_qos_prio_ethtype | ||
) |
Sets the priority for the given Ethertypes to the given values.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_MirrorSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_mirror_conf_t * | p_mirror_conf | ||
) |
Sets the dedicated port that will received all frames that are mirrored as well as the type of mirrored frames.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_CtEnableSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_port_mask_t | port_mask | ||
) |
Sets enable cut-through for the specified port.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_CtDelaySet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
uint32_t | ct_delay | ||
) |
Sets the cut-through delay for the specified port, delay Value in 400 ns / 40 ns / 8 ns increments (fequency of the MII PHY interface). This is a programmable value in MII clock cycles that can delay the assertion of the cut-through flag to the forwarding engine in order to hide the variable latency of the forwarding decision.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PulseGeneratorInit | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | time_num | ||
) |
Initilize pulse generator.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PulseGeneratorSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_ts_pulse_generator_t * | p_pulse | ||
) |
Sets pulse generator.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PortAuthSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
bool | auth_state | ||
) |
Sets authorization state for given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PortCtrlDirSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
bool | dir_state | ||
) |
Sets controlled direction for given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_PortEapolSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
bool | eapol_state | ||
) |
Sets EAPOL reception mode for given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_BpduSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
bool | bpdu_state | ||
) |
Sest Bridge Protocol Frame (BPDU) forwarding mode. Enabling the BPDU forwarding mode this function will also disable the unchecked dropping of BPDU frames.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_VlanDefaultSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
uint16_t | vlan_id | ||
) |
Sets the default VLAN for input/output processing for the specified port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_VlanPortAdd | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
uint16_t | vlan_id | ||
) |
Adds a VLAN for a given port to the VLAN domain table.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_VlanPortRemove | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
uint16_t | vlan_id | ||
) |
Removes a VLAN for a given port to the VLAN domain table.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_VlanInModeSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_vlan_in_mode_t | vlan_in_mode | ||
) |
Sets the mode of VLAN input operations for the given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_VlanOutModeSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_vlan_out_mode_t | vlan_out_mode | ||
) |
Sets the mode of VLAN output operations for the given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_VlanVerifySet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
bool | enable | ||
) |
Set VLAN verification for the given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_VlanDiscardUnknownSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
bool | enable | ||
) |
Set VLAN discartion of unknown frames for the given port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TdmaEnableSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_tdma_enable_t * | p_tdma_enable | ||
) |
Enable or disable the TDMA scheduler.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TdmaScheduleSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_tdma_schedule_entry_t * | p_tdma_schedule_entry, | ||
uint16_t | tdma_schedule_entry_count | ||
) |
Sets the TDMA scheduler entry.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TdmaGpioModeSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint8_t | gpio_num, | ||
ethsw_tdma_gpio_mode_t | gpio_mode | ||
) |
Sets the operation mode for the specified TDMA_GPIO number.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TdmaCounter0Set | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | tdma_counter0 | ||
) |
Sets TDMA counter 0 The Counter 0 is 32-bit counter that is incremented when the TCV field INC_CTR0 is set to 1.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_TdmaCounter0Get | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t * | p_tdma_counter0 | ||
) |
Gets TDMA counter 0 The Counter 0 is 32-bit counter that is incremented when the TCV field INC_CTR0 is set to 1.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_TdmaCounter1Set | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_tdma_counter1_t * | p_tdma_counter1 | ||
) |
Sets TDMA counter 1 The counter 1 is an 8-bit counter that is incremented when the TCV field INC_CTR1 is set to 1.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_TdmaCounter1Get | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_tdma_counter1_t * | p_tdma_counter1 | ||
) |
Gets TDMA counter 1 The counter 1 is an 8-bit counter that is incremented when the TCV field INC_CTR1 is set to 1.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_TdmaHoldReqClear | ( | ether_switch_ctrl_t *const | p_ctrl | ) |
Clear the TDMA hold request
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
fsp_err_t R_ETHSW_TimeEnableSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_time_enable_t * | p_time_enable | ||
) |
Enables or disables the timer with the specified timer number.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TimeTransmitTimestampSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_time_transmit_t * | p_time_transmit | ||
) |
Enable Tx timestamping for an external port.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
fsp_err_t R_ETHSW_TimeValueSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_timestamp_t * | p_timestamp | ||
) |
Sets the current time value to the timer with the specified timer number.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TimeValueGet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_timestamp_t * | p_timestamp | ||
) |
Gets the current time value to the timer with the specified timer number.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
FSP_ERR_TIMEOUT | Timeout error |
fsp_err_t R_ETHSW_TimeValueGetAll | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_timestamp_t * | p_timer0, | ||
ethsw_timestamp_t * | p_timer1 | ||
) |
Gets the current time value to all timer (timer number 0 and 1).
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_TIMEOUT | Timeout error |
fsp_err_t R_ETHSW_TimePeerDelaySet | ( | ether_switch_ctrl_t *const | p_ctrl, |
uint32_t | port, | ||
ethsw_time_peerdelay_t * | p_peerdelay | ||
) |
Sets the peer delay value for the specified timer number of the specified port number.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TimeOffsetSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_time_offset_correction_t * | p_offset | ||
) |
Sets the offset correction for the specified timer number.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TimeRateSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_time_rate_correction_t * | p_rate | ||
) |
Sets clock rate corection for the specified timer.
FSP_SUCCESS | Channel successfully closed. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |
fsp_err_t R_ETHSW_TimeDomainSet | ( | ether_switch_ctrl_t *const | p_ctrl, |
ethsw_time_domain_t * | p_domain | ||
) |
Sets the domain number for the specified timer.
FSP_SUCCESS | Command successfully. |
FSP_ERR_ASSERTION | Pointer to ETHER control block is NULL. |
FSP_ERR_NOT_OPEN | The control block has not been opened. |
FSP_ERR_INVALID_POINTER | Pointer to arguments are NULL. |
FSP_ERR_INVALID_ARGUMENT | Invalid input parameter. |