111 lines
3.9 KiB
C
Executable File
111 lines
3.9 KiB
C
Executable File
#include <stdint.h>
|
|
|
|
typedef struct {
|
|
uint32_t en : 1; // 0 EN
|
|
uint32_t cacheinv : 1; // 1 CACHEINV
|
|
uint32_t waysel : 1; // 2 WAYSEL
|
|
uint32_t reserve0 : 13; // 3 Reserve
|
|
uint32_t hitmen : 1; // 16 HITMEN
|
|
uint32_t missmen : 1; // 17 MISSMEN
|
|
uint32_t hitmrst : 1; // 18 HITMRST
|
|
uint32_t missmrst : 1; // 19 MISSMRST
|
|
uint32_t reserve1 : 12; // 20 Reserve
|
|
} reg_sec_icache_icache_cr_t;
|
|
|
|
typedef struct {
|
|
uint32_t busyf : 1; // 0 BUSYF
|
|
uint32_t bsyendf : 1; // 1 BSYENDF
|
|
uint32_t errf : 1; // 2 ERRF
|
|
uint32_t reserve0 : 29; // 3 Reserve
|
|
} reg_sec_icache_icache_sr_t;
|
|
|
|
typedef struct {
|
|
uint32_t reserve0 : 1; // 0 Reserve
|
|
uint32_t bsyendie : 1; // 1 BSYENDIE
|
|
uint32_t errie : 1; // 2 ERRIE
|
|
uint32_t reserve1 : 29; // 3 Reserve
|
|
} reg_sec_icache_icache_ier_t;
|
|
|
|
typedef struct {
|
|
uint32_t reserve0 : 1; // 0 Reserve
|
|
uint32_t cbsyendf : 1; // 1 CBSYENDF
|
|
uint32_t cerrf : 1; // 2 CERRF
|
|
uint32_t reserve1 : 29; // 3 Reserve
|
|
} reg_sec_icache_icache_fcr_t;
|
|
|
|
typedef struct {
|
|
uint32_t hitmon : 32; // 0 HITMON
|
|
} reg_sec_icache_icache_hmonr_t;
|
|
|
|
typedef struct {
|
|
uint32_t missmon : 16; // 0 MISSMON
|
|
uint32_t reserve0 : 16; // 16 Reserve
|
|
} reg_sec_icache_icache_mmonr_t;
|
|
|
|
typedef struct {
|
|
uint32_t baseaddr : 8; // 0 BASEADDR
|
|
uint32_t reserve0 : 1; // 8 Reserve
|
|
uint32_t rsize : 3; // 9 RSIZE
|
|
uint32_t reserve1 : 3; // 12 Reserve
|
|
uint32_t ren : 1; // 15 REN
|
|
uint32_t remapaddr : 11; // 16 REMAPADDR
|
|
uint32_t reserve2 : 1; // 27 Reserve
|
|
uint32_t mstsel : 1; // 28 MSTSEL
|
|
uint32_t reserve3 : 2; // 29 Reserve
|
|
uint32_t hburst : 1; // 31 HBURST
|
|
} reg_sec_icache_icache_crr0_t;
|
|
|
|
typedef struct {
|
|
uint32_t baseaddr : 8; // 0 BASEADDR
|
|
uint32_t reserve0 : 1; // 8 Reserve
|
|
uint32_t rsize : 3; // 9 RSIZE
|
|
uint32_t reserve1 : 3; // 12 Reserve
|
|
uint32_t ren : 1; // 15 REN
|
|
uint32_t remapaddr : 11; // 16 REMAPADDR
|
|
uint32_t reserve2 : 1; // 27 Reserve
|
|
uint32_t mstsel : 1; // 28 MSTSEL
|
|
uint32_t reserve3 : 2; // 29 Reserve
|
|
uint32_t hburst : 1; // 31 HBURST
|
|
} reg_sec_icache_icache_crr1_t;
|
|
|
|
typedef struct {
|
|
uint32_t baseaddr : 8; // 0 BASEADDR
|
|
uint32_t reserve0 : 1; // 8 Reserve
|
|
uint32_t rsize : 3; // 9 RSIZE
|
|
uint32_t reserve1 : 3; // 12 Reserve
|
|
uint32_t ren : 1; // 15 REN
|
|
uint32_t remapaddr : 11; // 16 REMAPADDR
|
|
uint32_t reserve2 : 1; // 27 Reserve
|
|
uint32_t mstsel : 1; // 28 MSTSEL
|
|
uint32_t reserve3 : 2; // 29 Reserve
|
|
uint32_t hburst : 1; // 31 HBURST
|
|
} reg_sec_icache_icache_crr2_t;
|
|
|
|
typedef struct {
|
|
uint32_t baseaddr : 8; // 0 BASEADDR
|
|
uint32_t reserve0 : 1; // 8 Reserve
|
|
uint32_t rsize : 3; // 9 RSIZE
|
|
uint32_t reserve1 : 3; // 12 Reserve
|
|
uint32_t ren : 1; // 15 REN
|
|
uint32_t remapaddr : 11; // 16 REMAPADDR
|
|
uint32_t reserve2 : 1; // 27 Reserve
|
|
uint32_t mstsel : 1; // 28 MSTSEL
|
|
uint32_t reserve3 : 2; // 29 Reserve
|
|
uint32_t hburst : 1; // 31 HBURST
|
|
} reg_sec_icache_icache_crr3_t;
|
|
|
|
typedef struct {
|
|
volatile reg_sec_icache_icache_cr_t icache_cr;
|
|
volatile reg_sec_icache_icache_sr_t icache_sr;
|
|
volatile reg_sec_icache_icache_ier_t icache_ier;
|
|
volatile reg_sec_icache_icache_fcr_t icache_fcr;
|
|
volatile reg_sec_icache_icache_hmonr_t icache_hmonr;
|
|
volatile reg_sec_icache_icache_mmonr_t icache_mmonr;
|
|
volatile uint32_t reserve0[2];
|
|
volatile reg_sec_icache_icache_crr0_t icache_crr0;
|
|
volatile reg_sec_icache_icache_crr1_t icache_crr1;
|
|
volatile reg_sec_icache_icache_crr2_t icache_crr2;
|
|
volatile reg_sec_icache_icache_crr3_t icache_crr3;
|
|
} reg_sec_icache_t;
|
|
|