kernel/process_capability: Handle debug capability flags
This commit is contained in:
parent
10824c5d63
commit
d09fb82113
@ -342,7 +342,13 @@ ResultCode ProcessCapabilities::HandleHandleTableFlags(u32 flags) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
ResultCode ProcessCapabilities::HandleDebugFlags(u32 flags) {
|
ResultCode ProcessCapabilities::HandleDebugFlags(u32 flags) {
|
||||||
// TODO: Implement
|
const u32 reserved = flags >> 19;
|
||||||
|
if (reserved != 0) {
|
||||||
|
return ERR_RESERVED_VALUE;
|
||||||
|
}
|
||||||
|
|
||||||
|
is_debuggable = (flags & 0x20000) != 0;
|
||||||
|
can_force_debug = (flags & 0x40000) != 0;
|
||||||
return RESULT_SUCCESS;
|
return RESULT_SUCCESS;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -165,6 +165,17 @@ public:
|
|||||||
return kernel_version;
|
return kernel_version;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/// Whether or not this process can be debugged.
|
||||||
|
bool IsDebuggable() const {
|
||||||
|
return is_debuggable;
|
||||||
|
}
|
||||||
|
|
||||||
|
/// Whether or not this process can forcibly debug another
|
||||||
|
/// process, even if that process is not considered debuggable.
|
||||||
|
bool CanForceDebug() const {
|
||||||
|
return can_force_debug;
|
||||||
|
}
|
||||||
|
|
||||||
private:
|
private:
|
||||||
/// Attempts to parse a given sequence of capability descriptors.
|
/// Attempts to parse a given sequence of capability descriptors.
|
||||||
///
|
///
|
||||||
|
Loading…
Reference in New Issue
Block a user