reset_demo begins with the following:
// Disable the machine & timer interrupts until setup is done. clear_csr(mie, MIP_MEIP); clear_csr(mie, MIP_MTIP);
I understand what clear_csr is doing, and that MIP_MEIP and MIP_MTIP are being used in place of having symbols defined for MIE_MEIE and MIE_MTIE as the locations in the registers are identical.
Why do we disable the machine and timer interrupts vs just disabling interrupts globally with the MIE bit in mstatus? My understanding is that by turning off MEIE and MTIE bits in mie we are leaving the possibility for software interrupts to still be handled (MSIE). Is there a specific reason why we would want that behaviour, or am I misunderstanding the relationship between mie/mstatus/the plic?
Here is the episode from my show where we encountered this question: