riscvarchive / riscv-qemu

QEMU with RISC-V (RV64G, RV32G) Emulation Support
386 stars 154 forks source link

Mask mie/mip fields depending on whether S mode is enabled (misa.S) #114

Open michaeljclark opened 6 years ago

michaeljclark commented 6 years ago

When S-mode (misa.S) is not present, writes to mip/mip.SEIP/SSIP/STIP and mie/sie.SEIE/SSIE/STIE need to be masked.

U-mode interrupts and the N-extension are not currently implemented, so these fields are already masked