Merge pull request #362 from betrusted-io/fix-resume

kernel: use correct fake interrupt cause
This commit is contained in:
Sean Cross 2023-04-09 00:32:33 -07:00 committed by GitHub
commit 89ca18caad
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 2 additions and 2 deletions

View file

@ -49,10 +49,10 @@ _start:
// restore the SIM with the value previously socked away by the interrupt handler routine during the suspend half
jal ra, _enable_all_irqs
// set scause to simulate an interrupt's occurence -- this makes the resume "feel like" an interrupt
// set scause to simulate an interrupt's occurrence -- this makes the resume "feel like" an interrupt
// vectored into the same routine that caused the suspend, but without having gone through the typical
// interrupt handler mechanisms
li t0, 0x80000000
li t0, 0x80000009
csrw scause, t0
// this is the same path the suspend interrupt took, but we set it up manually