Do not allow jtag ebreak outside machine mode
This commit is contained in:
parent
4209dc2792
commit
dc9246715d
|
@ -195,8 +195,9 @@ class DebugPlugin(val debugClockDomain : ClockDomain, hardwareBreakpointCount :
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
val allowEBreak = if(!pipeline.serviceExist(classOf[PrivilegeService])) True else pipeline.service(classOf[PrivilegeService]).isMachine()
|
||||||
|
|
||||||
decode.insert(DO_EBREAK) := !haltIt && (decode.input(IS_EBREAK) || hardwareBreakpoints.map(hb => hb.valid && hb.pc === (decode.input(PC) >> 1)).foldLeft(False)(_ || _))
|
decode.insert(DO_EBREAK) := !haltIt && (decode.input(IS_EBREAK) || hardwareBreakpoints.map(hb => hb.valid && hb.pc === (decode.input(PC) >> 1)).foldLeft(False)(_ || _)) && allowEBreak
|
||||||
when(execute.arbitration.isValid && execute.input(DO_EBREAK)){
|
when(execute.arbitration.isValid && execute.input(DO_EBREAK)){
|
||||||
execute.arbitration.haltByOther := True
|
execute.arbitration.haltByOther := True
|
||||||
busReadDataReg := execute.input(PC).asBits
|
busReadDataReg := execute.input(PC).asBits
|
||||||
|
|
Loading…
Reference in New Issue