Browse Source
Merge pull request #392 from riscv/fesvr-no-dm-when-dmactive-0
FESVR: Can't read a DM register when DMACTIVE=0
pull/393/head
Andrew Waterman
6 years ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with
1 additions and
1 deletions
-
fesvr/dtm.cc
|
|
|
@ -137,7 +137,7 @@ void dtm_t::resume(int hartsel) |
|
|
|
current_hart = hartsel; |
|
|
|
|
|
|
|
if (running) { |
|
|
|
write(DMI_DMCONTROL, 0); |
|
|
|
write(DMI_DMCONTROL, DMI_DMCONTROL_DMACTIVE); |
|
|
|
// Read dmstatus to avoid back-to-back writes to dmcontrol.
|
|
|
|
read(DMI_DMSTATUS); |
|
|
|
} |
|
|
|
|