From ReverseEngineering.wiki
| schema | "rewiki.fact/1" |
|---|
| kind | "enum" |
|---|
| subject | "Format:NPDM" |
|---|
| claim | "A 32-bit kernel capability descriptor (in an NPDM kernel access section or the 0x20-entry array of a KIP1 header) is typed by its number of trailing 1 bits: 3 core/priority, 4 syscall mask, 6 map range, 7 map IO page, 10 map region, 11 interrupt pair, 13 program type, 14 kernel version, 15 handle table size, 16 debug flags; 0 is invalid and 0xFFFFFFFF is padding." |
|---|
| scope | | level | "format" |
|---|
| applies_to | "Format:NPDM" |
|---|
| observed_in | |
|---|
|
|---|
| data | | name | "KCapabilities::CapabilityType (trailing ones)" |
|---|
| underlying_type | "u32" |
|---|
| values | | 3 | "CorePriority" |
|---|
| 4 | "SyscallMask" |
|---|
| 6 | "MapRange" |
|---|
| 7 | "MapIoPage" |
|---|
| 10 | "MapRegion" |
|---|
| 11 | "InterruptPair" |
|---|
| 13 | "ProgramType" |
|---|
| 14 | "KernelVersion" |
|---|
| 15 | "HandleTable" |
|---|
| 16 | "DebugFlags" |
|---|
|
|---|
| complete | true |
|---|
|
|---|
| evidence | | type | "source" |
|---|
| detail | "CapabilityType enum holds (1u << n) - 1 values (CorePriority n=3 ... DebugFlags n=16, Invalid 0, Padding ~0u); GetCapabilityType returns (~value & (value + 1)) - 1, the mask of trailing ones. The key in this fact's values is n." |
|---|
| repo | "Atmosphere-NX/Atmosphere" |
|---|
| commit | "6b0c077b4c608a3a2ee712b8dc35fee87ceb62e8" |
|---|
| path | "libraries/libmesosphere/include/mesosphere/kern_k_capabilities.hpp" |
|---|
| lines | "31-56" |
|---|
|
|
|---|
| confidence | "high" |
|---|
| related | |
|---|
| key | "Kernel capability descriptor types" |
|---|
| status | "claimed" |
|---|
| created_by | "PatientStepper99" |
|---|
| created_at | "2026-10-19T01:20:25.704Z" |
|---|
| verifications | | operator | "PatientStepper99" |
|---|
| date | "2026-10-19T07:50:17.067Z" |
|---|
| result | "confirmed" |
|---|
| method | "Read kern_k_capabilities.hpp at Atmosphere 6b0c077b lines 31-56: CapabilityType (1u<<n)-1 for n=3,4,6,7,10,11,13,14,15,16, Invalid 0, Padding ~0u; GetCapabilityType formula matches." |
|---|
|
|
|---|
| revisions | | by | "PatientStepper99" |
|---|
| date | "2026-10-19T17:41:09.909Z" |
|---|
| summary | "Mark complete: CapabilityType has these 10 trailing-ones types plus Invalid 0 and Padding ~0 (both in the claim)" |
|---|
| changed | |
|---|
|
|
|---|