|
ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
|
NSC veneer: ethernet frame TX / RX. More...
#include <stdint.h>#include "ra8_check.h"#include "ra8_err.h"#include "ra8_net_pal.h"#include "ra8_nsc.h"#include "ra8_nsc_veneer.h"Go to the source code of this file.
Functions | |
| ra8_err_t | ra8_nsc_eth_send (const uint8_t *ns_frame, uint16_t len) |
| NSC veneer: transmit an Ethernet frame from Non-Secure code. | |
| ra8_err_t | ra8_nsc_eth_recv (uint8_t *ns_buf, uint16_t *inout_len) |
| NSC veneer: receive an Ethernet frame into a Non-Secure buffer. | |
Variables | |
| static const char * | s_tag = "NSCETH" |
NSC veneer: ethernet frame TX / RX.
scaffold. The veneers delegate to ra8_net_pal which, in turn, delegates to ra8_eth. adds __attribute__((cmse_nonsecure_entry)) and runtime address checks via cmse_check_address_range.
Definition in file ra8_nsc_eth.c.
|
nodiscard |
NSC veneer: receive an Ethernet frame into a Non-Secure buffer.
NSC veneer: pull the next received frame to NS memory.
Validates capacity and pointer ranges, then forwards to ra8_net_pal_recv_frame.
| [out] | ns_buf | Non-Secure destination buffer. |
| [in,out] | inout_len | In: capacity; out: bytes written. |
| k_ra8_ok | Frame copied; *inout_len updated. |
| k_ra8_err_null_ptr | A pointer argument was NULL. |
| k_ra8_err_invalid_arg | Capacity below the frame max. |
Definition at line 82 of file ra8_nsc_eth.c.
References k_ra8_err_invalid_arg, k_ra8_nsc_eth_frame_max, RA8_CHECK_NULL_PTR, ra8_net_pal_recv_frame(), RA8_NSC_CHECK_NS_RANGE_RW, RA8_NSC_VENEER, and s_tag.
|
nodiscard |
NSC veneer: transmit an Ethernet frame from Non-Secure code.
NSC veneer: hand a frame to the secure ESWM transmit path.
Validates the NS-side pointer/length, runs cmse_check_address_range (TZ builds), and forwards to ra8_net_pal_send_frame.
| [in] | ns_frame | Non-Secure source buffer holding the L2 frame. |
| [in] | len | Frame length in bytes; 1..k_ra8_nsc_eth_frame_max. |
| k_ra8_ok | Frame queued for TX. |
| k_ra8_err_null_ptr | ns_frame was NULL. |
| k_ra8_err_invalid_arg | len out of range. |
Definition at line 50 of file ra8_nsc_eth.c.
References k_ra8_err_invalid_arg, k_ra8_nsc_eth_frame_max, RA8_CHECK_NULL_PTR, ra8_net_pal_send_frame(), RA8_NSC_CHECK_NS_RANGE_R, RA8_NSC_VENEER, and s_tag.
|
static |
Definition at line 26 of file ra8_nsc_eth.c.