diff options
author | Andrew Waterman <waterman@cs.berkeley.edu> | 2016-03-10 00:42:47 -0800 |
---|---|---|
committer | Andrew Waterman <waterman@cs.berkeley.edu> | 2016-03-10 00:42:47 -0800 |
commit | 469c5f16a7ce5a913248367a420d43dc3518eb88 (patch) | |
tree | 91ab6ca1ba68d84ecaa80f25e1ef45c737c13adf /machine/mtrap.h | |
parent | 8bd01c7999a1ba98e556492950d76789fe41462b (diff) | |
download | pk-469c5f16a7ce5a913248367a420d43dc3518eb88.zip pk-469c5f16a7ce5a913248367a420d43dc3518eb88.tar.gz pk-469c5f16a7ce5a913248367a420d43dc3518eb88.tar.bz2 |
Make num_harts a uintptr_t
Making it a uint32_t is a false economy.
Diffstat (limited to 'machine/mtrap.h')
-rw-r--r-- | machine/mtrap.h | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/machine/mtrap.h b/machine/mtrap.h index 0498d99..6defd67 100644 --- a/machine/mtrap.h +++ b/machine/mtrap.h @@ -30,7 +30,7 @@ static inline int xlen() extern uintptr_t first_free_paddr; extern uintptr_t mem_size; -extern uint32_t num_harts; +extern uintptr_t num_harts; typedef uintptr_t csr_t; // TODO this might become uint128_t for RV128 @@ -60,7 +60,7 @@ typedef struct { #define HLS() ((hls_t*)(MACHINE_STACK_TOP() - HLS_SIZE)) #define OTHER_HLS(id) ((hls_t*)((void*)HLS() + RISCV_PGSIZE * ((id) - read_const_csr(mhartid)))) -void hls_init(uint32_t hart_id, csr_t* csrs); +void hls_init(uintptr_t hart_id, csr_t* csrs); void parse_config_string(); void poweroff(void) __attribute((noreturn)); void printm(const char* s, ...); |