thermosphere: unfuck sw breakpoint logic
This commit is contained in:
@@ -19,16 +19,18 @@
|
||||
#define _REENT_ONLY
|
||||
#include <errno.h>
|
||||
|
||||
#include <stdatomic.h>
|
||||
#include "spinlock.h"
|
||||
|
||||
#define MAX_SW_BREAKPOINTS 32
|
||||
|
||||
typedef struct SoftwareBreakpoint {
|
||||
u64 address; // VA
|
||||
uintptr_t address; // VA
|
||||
u32 savedInstruction;
|
||||
u32 uid;
|
||||
bool persistent;
|
||||
bool applied;
|
||||
atomic_bool triedToApplyOrRevert;
|
||||
} SoftwareBreakpoint;
|
||||
|
||||
typedef struct SoftwareBreakpointManager {
|
||||
@@ -45,4 +47,4 @@ bool applyAllSoftwareBreakpoints(void);
|
||||
|
||||
int addSoftwareBreakpoint(u64 addr, bool persistent);
|
||||
int removeSoftwareBreakpoint(u64 addr, bool keepPersistent);
|
||||
int removeAllSoftwareBreakpoints(bool keepPersistent);
|
||||
int removeAllSoftwareBreakpoints(bool keepPersistent);
|
||||
|
||||
Reference in New Issue
Block a user