kern: Add real SvcBreak implementation

This commit is contained in:
Michael Scire
2020-07-31 00:04:43 -07:00
committed by SciresM
parent 4c3c910774
commit 325802e29d
5 changed files with 160 additions and 11 deletions

View File

@@ -35,6 +35,10 @@ namespace ams::kern::arch::arm64 {
static void PostDestroy(uintptr_t arg) { /* ... */ }
public:
static uintptr_t GetProgramCounter(const KThread &thread);
static void SetPreviousProgramCounter();
static Result BreakIfAttached(ams::svc::BreakReason break_reason, uintptr_t address, size_t size);
static Result SetHardwareBreakPoint(ams::svc::HardwareBreakPointRegisterName name, u64 flags, u64 value);
/* TODO: This is a placeholder definition. */

View File

@@ -193,6 +193,8 @@ namespace ams::kern {
KProcess::State SetDebugObject(void *debug_object);
void ClearDebugObject(KProcess::State state);
bool EnterJitDebug(ams::svc::DebugEvent event, ams::svc::DebugException exception, uintptr_t param1 = 0, uintptr_t param2 = 0, uintptr_t param3 = 0, uintptr_t param4 = 0);
KEventInfo *GetJitDebugInfo();
void ClearJitDebugInfo();