diff --git a/nucleus/src/arch/aarch64/caps.rs b/nucleus/src/arch/aarch64/caps.rs index b5fcd02..6e4f418 100644 --- a/nucleus/src/arch/aarch64/caps.rs +++ b/nucleus/src/arch/aarch64/caps.rs @@ -380,6 +380,15 @@ capdefs! { AsidControl, AsidPool } +impl NullCapability { + /// Create a Null capability. + /// + /// Such capabilities are invalid and can not be used for anything. + pub fn new() -> NullCapability { + NullCapability(LocalRegisterCopy::new(u128::from(NullCap::Type::value))) + } +} + // @todo retyping a device capability requires specifying memory base exactly, can't just pick next frame? /// Capability to a block of untyped memory. @@ -483,15 +492,6 @@ impl CapNodeCapability { } } -impl NullCapability { - /// Create a Null capability. - /// - /// Such capabilities are invalid and can not be used for anything. - pub fn new() -> NullCapability { - NullCapability(LocalRegisterCopy::new(u128::from(NullCap::Type::value))) - } -} - impl CapNodeCapability { /// Create a capability to CapNode. ///