Have ndmreset reset the processor
authorPalmer Dabbelt <palmer@dabbelt.com>
Wed, 19 Apr 2017 23:59:10 +0000 (16:59 -0700)
committerPalmer Dabbelt <palmer@dabbelt.com>
Wed, 26 Apr 2017 16:14:27 +0000 (09:14 -0700)
riscv/debug_module.cc

index 533b959b9d3cf487b70910189f60482229185acc..5f66ebed0a1843d07ac038c83baf9a5172e37ba7 100644 (file)
@@ -437,6 +437,9 @@ bool debug_module_t::dmi_write(unsigned address, uint32_t value)
               debug_rom_flags[dmcontrol.hartsel] |= (1 << DEBUG_ROM_FLAG_RESUME);
               resumeack[dmcontrol.hartsel] = false;
             }
+           if (dmcontrol.ndmreset) {
+             proc->reset();
+           }
           }
         }
         return true;