kernel: Format page allocation code

25cdb5b3bbccf504c73d6174547bbab5900891bf01a2f92034d76ab5290cbab3
Apply canonical formatting to page allocation expressions and function
parameters.

Assisted-by: Codex:gpt-6
Alexis Sellier committed ago 1 parent 8023e856
kernel/kernel/calls.rad +2 -1
1033 1033
    current: ?abi::CurrentContextInfo
1034 1034
) -> lifecycle::PageHeld throws (abi::Error) {
1035 1035
    let running = current else panic "reservePage: no current context";
1036 1036
    let handle = abi::Handle(arguments[0]);
1037 1037
    let context = abi::reference(running.context);
1038 -
    let op = abi::Operation::PageHeap as u64 if operation == PageOperation::Heap
1038 +
    let op = abi::Operation::PageHeap as u64
1039 +
        if operation == PageOperation::Heap
1039 1040
        else abi::Operation::PageAllocate as u64;
1040 1041
    try admit(&*shared, domain, &*table, op, handle);
1041 1042
    if operation == PageOperation::Heap {
1042 1043
        if arguments[1] <> 0 or arguments[2] <> 0 or arguments[3] <> 0 {
1043 1044
            throw abi::Error::InvalidArg;
kernel/kernel/locked.rad +4 -1
226 226
}
227 227
228 228
/// Reserve zeroed pages or an exclusive heap Page. The result carries the token to
229 229
/// initialize them with.
230 230
export fn beginPage(
231 -
    guard: &sync::Guard, domain: &domains::Domain, operation: calls::PageOperation, arguments: &[u64]
231 +
    guard: &sync::Guard,
232 +
    domain: &domains::Domain,
233 +
    operation: calls::PageOperation,
234 +
    arguments: &[u64]
232 235
) -> lifecycle::PageHeld throws (abi::Error) {
233 236
    // The guard serializes the shared metadata, and the record came from `get`.
234 237
    unsafe {
235 238
        let shared = &mut state::SHARED;
236 239
        let table = &mut domain.memory.table;