Имя модуля: SMHC0 , базовый адрес: 0x04020000 Имя модуля: SMHC1 , базовый адрес: 0x04021000 Имя модуля: SMHC2 , базовый адрес: 0x04022000 Руководство п. 5.3.5 Регистров: 50 Имя регистра | Смещение 1) SMHC_CTRL | 0x0000 typedef union smhc_ctrl { struct { unsigned soft_rst : 1; unsigned fifo_rst : 1; unsigned dma_rst : 1; unsigned unused0 : 1; unsigned int_enb : 1; unsigned dma_enb : 1; unsigned unused1 : 2; unsigned cd_dbc_enb : 1; unsigned unused2 : 1; unsigned ddr_mod_sel : 1; unsigned time_unit_dat : 1; unsigned time_unit_cmd : 1; unsigned unused3 : 18; unsigned fifo_ac_mod : 1; } b; unsigned long w; } SMHC_CTRL 2) SMHC_CLKDIV | 0x0004 typedef union smhc_clkdiv { struct { unsigned cclk_div : 8; unsigned unused0 : 8; unsigned cclk_enb : 1; unsigned cclk_ctrl : 1; unsigned unused1 : 13; unsigned mask_data0 : 1; } b; unsigned long w; } SMHC_CLKDIV 3) SMHC_TMOUT | 0x0008 typedef union smhc_tmout { struct { unsigned rto_lmt : 8; unsigned dto_lmt : 24; } b; unsigned long w; } SMHC_TMOUT 4) SMHC_CTYPE | 0x000C typedef union smhc_ctype { struct { unsigned card_wid : 2; unsigned unused0 : 30; } b; unsigned long w; } SMHC_CTYPE 5) SMHC_BLKSIZ | 0x0010 typedef union smhc_blksiz { struct { unsigned blk_sz : 16; unsigned unused0 : 16; } b; unsigned long w; } SMHC_BLKSIZ 6) SMHC_BYTCNT | 0x0014 typedef union smhc_bytcnt { struct { unsigned byte_cnt : 32; } b; unsigned long w; } SMHC_BYTCNT 7) SMHC_CMD | 0x0018 typedef union smhc_cmd { struct { unsigned cmd_idx : 6; unsigned resp_rcv : 1; unsigned long_resp : 1; unsigned chk_resp_crc : 1; unsigned data_trans : 1; unsigned trans_dir : 1; unsigned trans_mode : 1; unsigned stop_cmd_flag : 1; unsigned wait_pre_over : 1; unsigned stop_abt_cmd : 1; unsigned send_init_seq : 1; unsigned unused0 : 5; unsigned prg_clk : 1; unsigned unused1 : 2; unsigned boot_mod : 2; unsigned exp_boot_ack : 1; unsigned boot_abt : 1; unsigned vol_sw : 1; unsigned unused2 : 2; unsigned cmd_load : 1; } b; unsigned long w; } SMHC_CMD 8) SMHC_CMDARG | 0x001C typedef union smhc_cmdarg { struct { unsigned cmd_arg : 32; } b; unsigned long w; } SMHC_CMDARG 9) SMHC_RESP0 | 0x0020 typedef union smhc_resp0 { struct { unsigned cmd_resp0 : 32; } b; unsigned long w; } SMHC_RESP0 10) SMHC_RESP1 | 0x0024 typedef union smhc_resp1 { struct { unsigned cmd_resp1 : 32; } b; unsigned long w; } SMHC_RESP1 11) SMHC_RESP2 | 0x0028 typedef union smhc_resp2 { struct { unsigned cmd_resp2 : 32; } b; unsigned long w; } SMHC_RESP2 12) SMHC_RESP3 | 0x002C typedef union smhc_resp3 { struct { unsigned cmd_resp3 : 32; } b; unsigned long w; } SMHC_RESP3 13) SMHC_INTMASK | 0x0030 typedef union smhc_intmask { struct { unsigned unused0 : 1; unsigned re_int_en : 1; unsigned cc_int_en : 1; unsigned dtc_int_en : 1; unsigned dtr_int_en : 1; unsigned drr_int_en : 1; unsigned rce_int_en : 1; unsigned dce_int_en : 1; unsigned dto_bds_int_en : 1; unsigned rto_back_int_en : 1; unsigned dsto_vsd_int_en : 1; unsigned fu_fo_int_en : 1; unsigned cb_iw_int_en : 1; unsigned dse_bc_int_en : 1; unsigned acd_int_en : 1; unsigned dee_int_en : 1; unsigned sdio_int_en : 1; unsigned unused1 : 13; unsigned card_insert_int_en : 1; unsigned card_removal_int_en : 1; } b; unsigned long w; } SMHC_INTMASK 14) SMHC_MINTSTS | 0x0034 typedef union smhc_mintsts { struct { unsigned unused0 : 1; unsigned m_re_int : 1; unsigned m_cc_int : 1; unsigned m_dtc_int : 1; unsigned m_dtr_int : 1; unsigned m_drr_int : 1; unsigned m_rce_int : 1; unsigned m_dce_int : 1; unsigned m_rto_back_int : 1; unsigned m_dto_bds_int : 1; unsigned m_dsto_vsd_int : 1; unsigned m_fu_fo_int : 1; unsigned m_cb_iw_int : 1; unsigned m_dse_bc_int : 1; unsigned m_acd_int : 1; unsigned m_dee_int : 1; unsigned m_sdio_int : 1; unsigned unused1 : 13; unsigned m_card_insert : 1; unsigned m_card_removal_int : 1; } b; unsigned long w; } SMHC_MINTSTS 15) SMHC_RINTSTS | 0x0038 typedef union smhc_rintsts { struct { unsigned unused0 : 1; unsigned re_ : 1; unsigned cc_ : 1; unsigned dtc : 1; unsigned dtr : 1; unsigned drr : 1; unsigned rce : 1; unsigned dce : 1; unsigned rto_back : 1; unsigned dto_bds : 1; unsigned dsto_vsd : 1; unsigned fu_fo : 1; unsigned cb_iw : 1; unsigned dse_bc : 1; unsigned acd : 1; unsigned dee : 1; unsigned sdioi_int : 1; unsigned unused1 : 13; unsigned card_insert : 1; unsigned card_removal : 1; } b; unsigned long w; } SMHC_RINTSTS 16) SMHC_STATUS | 0x003C typedef union smhc_status { struct { unsigned fifo_rx_level : 1; unsigned fifo_tx_level : 1; unsigned fifo_empty : 1; unsigned fifo_full : 1; unsigned fsm_sta : 4; unsigned card_present : 1; unsigned card_busy : 1; unsigned fsm_busy : 1; unsigned resp_idx : 6; unsigned fifo_level : 9; unsigned unused0 : 5; unsigned dma_req : 1; } b; unsigned long w; } SMHC_STATUS 17) SMHC_FIFOTH | 0x0040 typedef union smhc_fifoth { struct { unsigned tx_tl : 8; unsigned unused0 : 8; unsigned rx_tl : 8; unsigned unused1 : 4; unsigned bsize_of_trans : 3; unsigned unused2 : 1; } b; unsigned long w; } SMHC_FIFOTH 18) SMHC_FUNS | 0x0044 typedef union smhc_funs { struct { unsigned host_send_mmc_irqresq : 1; unsigned read_wait : 1; unsigned abt_rdata : 1; unsigned unused0 : 29; } b; unsigned long w; } SMHC_FUNS 19) SMHC_TBC0 | 0x0048 typedef union smhc_tbc0 { struct { unsigned tbc0 : 32; } b; unsigned long w; } SMHC_TBC0 20) SMHC_TBC1 | 0x004C typedef union smhc_tbc1 { struct { unsigned tbc1 : 32; } b; unsigned long w; } SMHC_TBC1 21) SMHC_DBGC | 0x0050 typedef union smhc_dbgc { struct { unsigned unused0 : 32; } b; unsigned long w; } SMHC_DBGC 22) SMHC_CSDC | 0x0054 typedef union smhc_csdc { struct { unsigned crc_det_para : 4; unsigned unused0 : 28; } b; unsigned long w; } SMHC_CSDC 23) SMHC_A12A | 0x0058 typedef union smhc_a12a { struct { unsigned sd_a12a : 16; unsigned unused0 : 16; } b; unsigned long w; } SMHC_A12A 24) SMHC_NTSR | 0x005C typedef union smhc_ntsr { struct { unsigned unused0 : 4; unsigned cmd_sample_timing_phase : 2; unsigned unused1 : 2; unsigned dat_sample_timing_phase : 2; unsigned unused2 : 6; unsigned cmd_send_rx_phase_clr : 1; unsigned unused3 : 3; unsigned dat_recv_rx_phase_clr : 1; unsigned dat_trans_rx_phase_clr : 1; unsigned dat_crc_status_rx_phase_clr : 1; unsigned unused4 : 1; unsigned cmd_dat_rx_phase_clr : 1; unsigned unused5 : 2; unsigned dat0_bypass : 1; unsigned unused6 : 3; unsigned mode_selec : 1; } b; unsigned long w; } SMHC_NTSR 25) SMHC_HWRST | 0x0078 typedef union smhc_hwrst { struct { unsigned hw_rst : 1; unsigned unused0 : 31; } b; unsigned long w; } SMHC_HWRST 26) SMHC_IDMAC | 0x0080 typedef union smhc_idmac { struct { unsigned idmac_rst : 1; unsigned fix_bust_ctrl : 1; unsigned reserved2 : 5; unsigned idmac_enb : 1; unsigned reserved1 : 3; unsigned unused0 : 20; unsigned des_load_ctrl : 1; } b; unsigned long w; } SMHC_IDMAC 27) SMHC_DLBA | 0x0084 typedef union smhc_dlba { struct { unsigned des_base_addr : 32; } b; unsigned long w; } SMHC_DLBA 28) SMHC_IDST | 0x0088 typedef union smhc_idst { struct { unsigned tx_int : 1; unsigned rx_int : 1; unsigned fatal_berr_int : 1; unsigned unused0 : 1; unsigned des_unavl_int : 1; unsigned err_flag_sum : 1; unsigned unused1 : 2; unsigned nor_int_sum_nis : 1; unsigned abn_int_sum_ais : 1; unsigned idmac_err_sta : 3; unsigned reserved1 : 4; unsigned unused2 : 15; } b; unsigned long w; } SMHC_IDST 29) SMHC_IDIE | 0x008C typedef union smhc_idie { struct { unsigned tx_int_enb : 1; unsigned rx_int_enb : 1; unsigned ferr_int_enb : 1; unsigned unused0 : 1; unsigned des_unavl_int_enb : 1; unsigned err_sum_int_enb : 1; unsigned unused1 : 2; unsigned reserved1 : 2; unsigned unused2 : 22; } b; unsigned long w; } SMHC_IDIE 30) SMHC_THLD | 0x0100 typedef union smhc_thld { struct { unsigned card_rd_thld_enb : 1; unsigned bcig : 1; unsigned card_wr_thld_enb : 1; unsigned unused0 : 13; unsigned card_rd_thld : 12; unsigned unused1 : 4; } b; unsigned long w; } SMHC_THLD 31) SMHC_SFC | 0x0104 typedef union smhc_sfc { struct { unsigned bypass_en : 1; unsigned stop_clk_ctrl : 4; unsigned unused0 : 27; } b; unsigned long w; } SMHC_SFC 32) SMHC_A23A | 0x0108 typedef union smhc_a23a { struct { unsigned a23a : 32; } b; unsigned long w; } SMHC_A23A 33) EMMC_DDR_SBIT_DET | 0x010C typedef union emmc_ddr_sbit_det { struct { unsigned half_start_bit : 1; unsigned unused0 : 30; unsigned hs400_md_en : 1; } b; unsigned long w; } EMMC_DDR_SBIT_DET 34) SMHC_RESP_CRC | 0x0110 typedef union smhc_resp_crc { struct { unsigned resp_crc : 7; unsigned unused0 : 25; } b; unsigned long w; } SMHC_RESP_CRC 35) NDFC_SPARE_AREA | 0x0114 typedef union ndfc_spare_area { struct { unsigned ndfc_spare_adr : 16; unsigned unused0 : 16; } b; unsigned long w; } NDFC_SPARE_AREA 36) SMHC_D6_CRC | 0x0118 typedef union smhc_d6_crc { struct { unsigned dat6_crc : 32; } b; unsigned long w; } SMHC_D6_CRC 37) SMHC_D5_CRC | 0x011C typedef union smhc_d5_crc { struct { unsigned dat5_crc : 32; } b; unsigned long w; } SMHC_D5_CRC 38) SMHC_D4_CRC | 0x0120 typedef union smhc_d4_crc { struct { unsigned dat4_crc : 32; } b; unsigned long w; } SMHC_D4_CRC 39) SMHC_D3_CRC | 0x0124 typedef union smhc_d3_crc { struct { unsigned dat3_crc : 32; } b; unsigned long w; } SMHC_D3_CRC 40) SMHC_D2_CRC | 0x0128 typedef union smhc_d2_crc { struct { unsigned dat2_crc : 32; } b; unsigned long w; } SMHC_D2_CRC 41) SMHC_D1_CRC | 0x012C typedef union smhc_d1_crc { struct { unsigned dat1_crc : 32; } b; unsigned long w; } SMHC_D1_CRC 42) SMHC_D0_CRC | 0x0130 typedef union smhc_d0_crc { struct { unsigned dat0_crc : 32; } b; unsigned long w; } SMHC_D0_CRC 43) SMHC_CRC_STA | 0x0134 typedef union smhc_crc_sta { struct { unsigned crc_sta : 3; unsigned unused0 : 29; } b; unsigned long w; } SMHC_CRC_STA 44) SMHC_EXT_CMD | 0x0138 typedef union smhc_ext_cmd { struct { unsigned auto_cmd23_en : 1; unsigned unused0 : 31; } b; unsigned long w; } SMHC_EXT_CMD 45) SMHC_EXT_RESP | 0x013C typedef union smhc_ext_resp { struct { unsigned smhc_ext_resp : 32; } b; unsigned long w; } SMHC_EXT_RESP 46) SMHC_DRV_DL | 0x0140 typedef union smhc_drv_dl { struct { unsigned unused0 : 16; unsigned cmd_drv_ph_sel : 1; unsigned dat_drv_ph_sel : 1; unsigned unused1 : 14; } b; unsigned long w; } SMHC_DRV_DL 47) SMHC_SAMP_DL | 0x0144 typedef union smhc_samp_dl { struct { unsigned samp_dl_sw : 6; unsigned unused0 : 1; unsigned samp_dl_sw_en : 1; unsigned samp_dl : 6; unsigned samp_dl_cal_done : 1; unsigned samp_dl_cal_start : 1; unsigned unused1 : 16; } b; unsigned long w; } SMHC_SAMP_DL 48) SMHC_DS_DL | 0x0148 typedef union smhc_ds_dl { struct { unsigned ds_dl_sw : 6; unsigned unused0 : 1; unsigned ds_dl_sw_en : 1; unsigned ds_dl : 6; unsigned ds_dl_cal_done : 1; unsigned ds_dl_cal_start : 1; unsigned unused1 : 16; } b; unsigned long w; } SMHC_DS_DL 49) SMHC_FIFO | 0x0200 typedef union smhc_fifo { struct { unsigned ds_dl_sw : 6; unsigned unused0 : 1; unsigned ds_dl_sw_en : 1; unsigned ds_dl : 6; unsigned ds_dl_cal_done : 1; unsigned ds_dl_cal_start : 1; unsigned unused1 : 16; } b; unsigned long w; } SMHC_FIFO 50) SMHC_D7_CRC | 0x0114 typedef union smhc_d7_crc { struct { unsigned dat7_crc : 32; } b; unsigned long w; } SMHC_D7_CRC |