Регистры Allwinner H616

Сокращения  |  Дерево шин  |  Карта памяти

Контроллер Ethernet ( Руководство )

Имя модуля: EMAC0 , базовый адрес: 0x05020000

Имя модуля: EMAC1 , базовый адрес: 0x05030000

Руководство п. 6.1


Регистров: 27

Имя регистра | Смещение


  • 1) EMAC_BASIC_CTL0 | 0x0000

    typedef union  emac_basic_ctl0
    {
      struct
      {
       unsigned duplex : 1;
       unsigned loopback : 1;
       unsigned speed : 2;
       unsigned unused0 : 28;
      } b;
       unsigned long w;
    } EMAC_BASIC_CTL0
       

  • 2) EMAC_BASIC_CTL1 | 0x0004

    typedef union  emac_basic_ctl1
    {
      struct
      {
       unsigned soft_rst : 1;
       unsigned rx_tx_pri : 1;
       unsigned unused0 : 22;
       unsigned burst_len : 6;
       unsigned unused1 : 2;
      } b;
       unsigned long w;
    } EMAC_BASIC_CTL1
       

  • 3) EMAC_INT_STA | 0x0008

    typedef union  emac_int_sta
    {
      struct
      {
       unsigned tx_p : 1;
       unsigned tx_dma_stopped_p : 1;
       unsigned tx_buf_ua_p : 1;
       unsigned tx_timeout_p : 1;
       unsigned tx_underflow_p : 1;
       unsigned tx_early_p : 1;
       unsigned unused0 : 2;
       unsigned rx_p : 1;
       unsigned rx_buf_ua_p : 1;
       unsigned rx_dma_stopped_p : 1;
       unsigned rx_timeout_p : 1;
       unsigned rx_overflow_p : 1;
       unsigned rx_early_p : 1;
       unsigned unused1 : 2;
       unsigned rgmii_link_sta_p : 1;
       unsigned unused2 : 15;
      } b;
       unsigned long w;
    } EMAC_INT_STA
       

  • 4) EMAC_INT_EN | 0x000C

    typedef union  emac_int_en
    {
      struct
      {
       unsigned tx_int_en : 1;
       unsigned tx_dma_stopped_int_en : 1;
       unsigned tx_buf_ua_int_en : 1;
       unsigned tx_timeout_int_en : 1;
       unsigned tx_underflow_int_en : 1;
       unsigned tx_early_int_en : 1;
       unsigned unused0 : 2;
       unsigned rx_int_en : 1;
       unsigned rx_buf_ua_int_en : 1;
       unsigned rx_dma_stopped_int_en : 1;
       unsigned rx_timeout_int_en : 1;
       unsigned rx_overflow_int_en : 1;
       unsigned rx_early_int_en : 1;
       unsigned unused1 : 18;
      } b;
       unsigned long w;
    } EMAC_INT_EN
       

  • 5) EMAC_TX_CTL0 | 0x0010

    typedef union  emac_tx_ctl0
    {
      struct
      {
       unsigned unused0 : 30;
       unsigned tx_frm_len_ctl : 1;
       unsigned tx_en : 1;
      } b;
       unsigned long w;
    } EMAC_TX_CTL0
       

  • 6) EMAC_TX_CTL1 | 0x0014

    typedef union  emac_tx_ctl1
    {
      struct
      {
       unsigned flush_tx_fifo : 1;
       unsigned tx_md : 1;
       unsigned unused0 : 6;
       unsigned tx_th : 3;
       unsigned unused1 : 19;
       unsigned tx_dma_en : 1;
       unsigned tx_dma_start : 1;
      } b;
       unsigned long w;
    } EMAC_TX_CTL1
       

  • 7) EMAC_TX_FLOW_CTL | 0x001C

    typedef union  emac_tx_flow_ctl
    {
      struct
      {
       unsigned tx_flow_ctl_en : 1;
       unsigned zqp_frm_en : 1;
       unsigned unused0 : 2;
       unsigned pause_time : 16;
       unsigned tx_pause_frm_slot : 2;
       unsigned unused1 : 9;
       unsigned tx_flow_ctl_sta : 1;
      } b;
       unsigned long w;
    } EMAC_TX_FLOW_CTL
       

  • 8) EMAC_TX_DMA_DESC_LIST | 0x0020

    typedef union  emac_tx_dma_desc_list
    {
      struct
      {
       unsigned tx_desc_list : 32;
      } b;
       unsigned long w;
    } EMAC_TX_DMA_DESC_LIST
       

  • 9) EMAC_RX_CTL0 | 0x0024

    typedef union  emac_rx_ctl0
    {
      struct
      {
       unsigned unused0 : 16;
       unsigned rx_flow_ctl_en : 1;
       unsigned rx_pause_frm_md : 1;
       unsigned unused1 : 9;
       unsigned check_crc : 1;
       unsigned strip_fcs : 1;
       unsigned jumbo_frm_en : 1;
       unsigned rx_frm_len_ctl : 1;
       unsigned rx_en : 1;
      } b;
       unsigned long w;
    } EMAC_RX_CTL0
       

  • 10) EMAC_RX_CTL1 | 0x0028

    typedef union  emac_rx_ctl1
    {
      struct
      {
       unsigned flush_rx_frm : 1;
       unsigned rx_md : 1;
       unsigned rx_runt_frm : 1;
       unsigned rx_err_frm : 1;
       unsigned rx_th : 2;
       unsigned unused0 : 14;
       unsigned rx_flow_ctl_th_act : 2;
       unsigned rx_flow_ctl_th_deact : 2;
       unsigned rx_fifo_flow_ctl : 1;
       unsigned unused1 : 5;
       unsigned rx_dma_en : 1;
       unsigned rx_dma_start : 1;
      } b;
       unsigned long w;
    } EMAC_RX_CTL1
       

  • 11) EMAC_RX_DMA_DESC_LIST | 0x0034

    typedef union  emac_rx_dma_desc_list
    {
      struct
      {
       unsigned rx_desc_list : 32;
      } b;
       unsigned long w;
    } EMAC_RX_DMA_DESC_LIST
       

  • 12) EMAC_RX_FRM_FLT | 0x0038

    typedef union  emac_rx_frm_flt
    {
      struct
      {
       unsigned rx_all : 1;
       unsigned flt_md : 1;
       unsigned unused0 : 2;
       unsigned da_inv_filter : 1;
       unsigned sa_inv_filter : 1;
       unsigned sa_filter_en : 1;
       unsigned unused1 : 1;
       unsigned hash_unicast : 1;
       unsigned hash_multicast : 1;
       unsigned unused2 : 2;
       unsigned ctl_frm_filter : 2;
       unsigned unused3 : 2;
       unsigned rx_all_multicast : 1;
       unsigned dis_broadcast : 1;
       unsigned unused4 : 13;
       unsigned dis_addr_filter : 1;
      } b;
       unsigned long w;
    } EMAC_RX_FRM_FLT
       

  • 13) EMAC_RX_HASH0 | 0x0040

    typedef union  emac_rx_hash0
    {
      struct
      {
       unsigned hash_tab0 : 32;
      } b;
       unsigned long w;
    } EMAC_RX_HASH0
       

  • 14) EMAC_RX_HASH1 | 0x0044

    typedef union  emac_rx_hash1
    {
      struct
      {
       unsigned hash_tab1 : 32;
      } b;
       unsigned long w;
    } EMAC_RX_HASH1
       

  • 15) EMAC_MII_CMD | 0x0048

    typedef union  emac_mii_cmd
    {
      struct
      {
       unsigned mii_busy : 1;
       unsigned mii_wr : 1;
       unsigned unused0 : 2;
       unsigned phy_reg_addr : 5;
       unsigned unused1 : 3;
       unsigned phy_addr : 5;
       unsigned unused2 : 3;
       unsigned mdc_div_ratio_m : 3;
       unsigned unused3 : 9;
      } b;
       unsigned long w;
    } EMAC_MII_CMD
       

  • 16) EMAC_MII_DATA | 0x004C

    typedef union  emac_mii_data
    {
      struct
      {
       unsigned mii_data : 16;
       unsigned unused0 : 16;
      } b;
       unsigned long w;
    } EMAC_MII_DATA
       

  • 17) EMAC_ADDR_HIGH0 | 0x0050

    typedef union  emac_addr_high0
    {
      struct
      {
       unsigned mac_addr_high0 : 16;
       unsigned unused0 : 16;
      } b;
       unsigned long w;
    } EMAC_ADDR_HIGH0
       

  • 18) EMAC_ADDR_LOW0 | 0x0054

    typedef union  emac_addr_low0
    {
      struct
      {
       unsigned mac_addr_low0 : 32;
      } b;
       unsigned long w;
    } EMAC_ADDR_LOW0
       

  • 19) EMAC_ADDR_HIGHN | 0x0050+0x08*N(N=1~7)

    typedef union  emac_addr_highn
    {
      struct
      {
       unsigned mac_addr_high : 16;
       unsigned unused0 : 8;
       unsigned mac_addr_byte_ctl : 6;
       unsigned mac_addr_type : 1;
       unsigned mac_addr_ctl : 1;
      } b;
       unsigned long w;
    } EMAC_ADDR_HIGHN
       

  • 20) EMAC_ADDR_LOWN | 0x0054+0x08*N(N=1~7)

    typedef union  emac_addr_lown
    {
      struct
      {
       unsigned mac_addr_lown : 32;
      } b;
       unsigned long w;
    } EMAC_ADDR_LOWN
       

  • 21) EMAC_TX_DMA_STA | 0x00B0

    typedef union  emac_tx_dma_sta
    {
      struct
      {
       unsigned tx_dma_sta : 3;
       unsigned unused0 : 29;
      } b;
       unsigned long w;
    } EMAC_TX_DMA_STA
       

  • 22) EMAC_TX_DMA_CUR_DESC | 0x00B4

    typedef union  emac_tx_dma_cur_desc
    {
      struct
      {
       unsigned emac_tx_dma_cur_desc : 32;
      } b;
       unsigned long w;
    } EMAC_TX_DMA_CUR_DESC
       

  • 23) EMAC_TX_DMA_CUR_BUF | 0x00B8

    typedef union  emac_tx_dma_cur_buf
    {
      struct
      {
       unsigned emac_tx_dma_cur_buf : 32;
      } b;
       unsigned long w;
    } EMAC_TX_DMA_CUR_BUF
       

  • 24) EMAC_RX_DMA_STA | 0x00C0

    typedef union  emac_rx_dma_sta
    {
      struct
      {
       unsigned rx_dma_sta : 3;
       unsigned unused0 : 29;
      } b;
       unsigned long w;
    } EMAC_RX_DMA_STA
       

  • 25) EMAC_RX_DMA_CUR_DESC | 0x00C4

    typedef union  emac_rx_dma_cur_desc
    {
      struct
      {
       unsigned emac_rx_dma_cur_desc : 32;
      } b;
       unsigned long w;
    } EMAC_RX_DMA_CUR_DESC
       

  • 26) EMAC_RX_DMA_CUR_BUF | 0x00C8

    typedef union  emac_rx_dma_cur_buf
    {
      struct
      {
       unsigned emac_rx_dma_cur_buf : 32;
      } b;
       unsigned long w;
    } EMAC_RX_DMA_CUR_BUF
       

  • 27) EMAC_RGMII_STA | 0x00D0

    typedef union  emac_rgmii_sta
    {
      struct
      {
       unsigned rgmii_link_md : 1;
       unsigned rgmii_link_spd : 2;
       unsigned rgmii_link : 1;
       unsigned unused0 : 28;
      } b;
       unsigned long w;
    } EMAC_RGMII_STA
       


  • Allwinner H616 Manual