aienux
Aienux, the AienOS kernel: boot, scheduling, IPC and capability boundaries. Pre-alpha; host, emulator and physical evidence are labelled separately.
Brought by drakestapleton
aienux / native / kernel / core / klog_boot.h
| 1 | /* SPDX-License-Identifier: Apache-2.0 |
| 2 | * Copyright 2026 Drake Stapleton (AIEN / aien-dev) |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | /* klog_boot.h -- what the UEFI stub found about the log slot |
| 18 | * (native/boot/efi_klog.c), read by the kernel after ExitBootServices |
| 19 | * (core/klog_flush.c). Raspberry Pi 5 build only (CK_KLOG). */ |
| 20 | #ifndef AIENOS_CK_KLOG_BOOT_H |
| 21 | #define AIENOS_CK_KLOG_BOOT_H |
| 22 | #include <stdint.h> |
| 23 | #include "klog_slot.h" |
| 24 | |
| 25 | enum { CK_KLOG_BOOT_NONE = 0, CK_KLOG_BOOT_ABSENT = 1, CK_KLOG_BOOT_REFUSED = 2, CK_KLOG_BOOT_FOUND = 3 }; |
| 26 | |
| 27 | struct ck_klog_boot { |
| 28 | int state; /* CK_KLOG_BOOT_* */ |
| 29 | struct ck_klog_map map; /* checked map (state FOUND) */ |
| 30 | uint64_t disk_last_block; /* firmware LastBlock of the disk that carries the slot */ |
| 31 | }; |
| 32 | extern struct ck_klog_boot ck_klog_boot; |
| 33 | #endif |