ra8-firmware 0.1.0
Bare-metal firmware for the Renesas RA8 family (RA8D2 / RA8P1)
Loading...
Searching...
No Matches
ra8_eth_internal.h
Go to the documentation of this file.
1
23
24#pragma once
25
26#ifdef __cplusplus
27extern "C" {
28#endif
29
30#include <stdint.h>
31
32#include "ra8_attributes.h"
33#include "ra8_eth.h"
34#include "ra8_rmac.h"
35
62
70extern volatile uint16_t g_ra8_eth_phy_bmsr_after_wait;
71
87
102
118extern bool g_eth_mac_speed_resynced;
119
142
143#ifdef __cplusplus
144}
145#endif
Annotation-attribute framework macros for ra8-firmware.
#define RA8_PRIV
Module-private helper: shared across TUs but only inside one library.
ra8_eth_state_t s_eth_state
Singleton NIC runtime state.
Definition ra8_eth.c:277
bool g_eth_mac_speed_resynced
Latch – true once ra8_eth_link_status has re-programmed MPIC.LSC / MPIC.PIPP to match the PHY's negot...
Definition ra8_eth.c:294
Ethernet Switch Module (ESWM) + frame TX/RX driver.
volatile uint16_t g_ra8_eth_phy_bmsr_after_wait
BMSR snapshot AFTER the auto-neg wait.
ra8_rmac_port_t priv_ra8_eth_channel_to_port(uint8_t channel)
Map a logical channel index to an RMAC port identifier.
Definition ra8_eth.c:347
ra8_eth_phy_t
PHY-side MIIM constants shared by both ra8_eth TUs: the ra8_eth.c open path checks PHY readiness and ...
@ k_ra8_eth_phy_bmsr_link_up
BMSR.LINK_STATUS bit 2.
@ k_ra8_eth_phy_bmcr_duplex
BMCR.DUPLEX_MODE bit 8.
@ k_ra8_eth_phy_anlpar_10h
ANLPAR bit 5: 10BASE-T.
@ k_ra8_eth_phy_addr_default
EK-RA8D2 PHY MDC address.
@ k_ra8_eth_phy_gbsr_1000h
GBSR bit 10: 1000BASE-T HD.
@ k_ra8_eth_phy_speed_100
100 Mbps.
@ k_ra8_eth_phy_bmcr_speed1000
BMCR.SPEED_MS bit 6 (1Gb).
@ k_ra8_eth_phy_reg_anlpar
ANLPAR (10/100 link partner).
@ k_ra8_eth_phy_bmcr_speed100
BMCR.SPEED_SELECT bit 13.
@ k_ra8_eth_phy_reg_bmcr
BMCR (basic mode control).
@ k_ra8_eth_phy_gbsr_1000f
GBSR bit 11: 1000BASE-T FD.
@ k_ra8_eth_phy_reg_gbsr
GBSR (1G link-partner ability).
@ k_ra8_eth_phy_reg_bmsr
BMSR (basic mode status).
@ k_ra8_eth_phy_speed_10
10 Mbps.
@ k_ra8_eth_phy_anlpar_10f
ANLPAR bit 6: 10BASE-T FD.
@ k_ra8_eth_phy_anlpar_100f
ANLPAR bit 8: 100BASE-TX FD.
@ k_ra8_eth_phy_anlpar_100h
ANLPAR bit 7: 100BASE-TX.
@ k_ra8_eth_phy_speed_1000
1 Gbps.
@ k_ra8_eth_phy_bmsr_an_done
BMSR.AUTONEG_COMPLETE bit 5.
Per-port Ethernet MAC (RMAC) driver – HUM Ch 33.
ra8_rmac_port_t
RMAC port index (m = 0, 1).
Per-channel NIC configuration.
Definition ra8_eth.h:228
Driver-private NIC state.
ra8_eth_stats_t stats
Cumulative counters.
uint8_t opened
1 once ra8_eth_open succeeds.
ra8_eth_cfg_t cfg
Captured configuration.
NIC software counters.
Definition ra8_eth.h:260