2020-03-10 04:04:17 +00:00
|
|
|
[package]
|
|
|
|
|
authors = ["Sean Cross <sean@xobs.io>"]
|
|
|
|
|
description = "Core kernel for Xous, including task switching and memory management"
|
2022-09-27 10:43:39 +00:00
|
|
|
license = "MIT OR Apache-2.0"
|
2021-05-19 06:18:46 +00:00
|
|
|
edition = "2018"
|
2022-09-27 09:02:20 +00:00
|
|
|
name = "xous-kernel"
|
2023-03-21 18:48:55 +00:00
|
|
|
version = "0.9.38"
|
2021-08-16 04:25:15 +00:00
|
|
|
resolver = "2"
|
2020-03-10 04:04:17 +00:00
|
|
|
|
2022-06-10 13:36:53 +00:00
|
|
|
# Dependency versions enforced by Cargo.lock.
|
2020-03-10 04:04:17 +00:00
|
|
|
[dependencies]
|
|
|
|
|
bitflags = "1.2.1"
|
2021-08-18 10:15:29 +00:00
|
|
|
stats_alloc = { version = "0.1.8", optional = true }
|
2026-01-29 11:12:00 +00:00
|
|
|
xous-kernel = { package = "xous", version = "0.9.70", features = [
|
2021-08-18 10:15:29 +00:00
|
|
|
"forget-memory-messages",
|
|
|
|
|
] }
|
2026-01-29 11:12:00 +00:00
|
|
|
utralib = { version = "0.1.27", optional = true, default-features = false }
|
2024-06-14 11:10:18 +00:00
|
|
|
rand_chacha = { version = "0.3.1", optional = true, default-features = false }
|
2025-09-18 13:25:51 +00:00
|
|
|
bao1x-hal = { path = "../libs/bao1x-hal", optional = true, default-features = false }
|
2026-01-13 19:19:35 +00:00
|
|
|
bao1x-api = { path = "../libs/bao1x-api", optional = true }
|
2024-05-12 08:28:14 +00:00
|
|
|
loader = { path = "../loader", optional = true, features = ["swap"] }
|
2021-08-16 04:25:15 +00:00
|
|
|
[target.'cfg(any(windows,unix))'.dev-dependencies]
|
2026-01-29 11:12:00 +00:00
|
|
|
xous-kernel = { package = "xous", version = "0.9.70", features = [
|
2021-08-18 10:15:29 +00:00
|
|
|
"forget-memory-messages",
|
|
|
|
|
"processes-as-threads",
|
|
|
|
|
] }
|
2024-05-17 16:22:23 +00:00
|
|
|
rand = "0.8.5"
|
2021-08-16 04:25:15 +00:00
|
|
|
|
2020-06-03 07:34:55 +00:00
|
|
|
[target.'cfg(target_arch = "riscv32")'.dependencies]
|
2024-01-14 16:14:39 +00:00
|
|
|
riscv = { version = "0.5.6", package = "xous-riscv" } # source is in "../imports/riscv-0.5.6"
|
2023-04-06 01:37:46 +00:00
|
|
|
gdbstub = { version = "0.6.5", optional = true, default-features = false }
|
2023-04-06 02:45:42 +00:00
|
|
|
gdbstub_arch = { version = "0.2.4", optional = true, default-features = false }
|
2020-06-03 07:34:55 +00:00
|
|
|
|
2023-03-14 14:39:19 +00:00
|
|
|
[target.'cfg(target_arch = "arm")'.dependencies]
|
2024-01-14 16:14:39 +00:00
|
|
|
armv7 = { git = "https://github.com/Foundation-Devices/armv7.git", branch = "update", features = [
|
|
|
|
|
"critical-section",
|
2023-03-14 14:39:19 +00:00
|
|
|
] }
|
2024-02-07 16:33:14 +00:00
|
|
|
# FIXME: bring atsama5d27 target up to date so utralib dependency does not conflict
|
|
|
|
|
# atsama5d27 = { git = "https://github.com/Foundation-Devices/atsama5d27.git", branch = "master" }
|
2026-01-29 11:12:00 +00:00
|
|
|
xous-kernel = { package = "xous", version = "0.9.70", features = ["v2p"] }
|
2023-04-05 12:35:01 +00:00
|
|
|
critical-section = "1.1.1"
|
2023-03-14 14:39:19 +00:00
|
|
|
|
2024-08-18 18:24:24 +00:00
|
|
|
[lints.rust]
|
|
|
|
|
unexpected_cfgs = { level = "warn", check-cfg = ['cfg(ci)', 'cfg(baremetal)'] }
|
|
|
|
|
|
2020-03-10 04:04:17 +00:00
|
|
|
[features]
|
2025-09-18 13:25:51 +00:00
|
|
|
vexii-test = [] # integration test for vexii, not a production configuration
|
2025-12-01 17:42:59 +00:00
|
|
|
bao1x = ["utralib/bao1x", "rand_chacha", "raw-trng"]
|
2025-01-01 14:51:16 +00:00
|
|
|
verilator-only = []
|
2025-09-18 13:25:51 +00:00
|
|
|
board-baosec = ["bao1x-hal/kernel-baosec", "memmap-flash", "swap"]
|
|
|
|
|
board-baosor = ["bao1x-hal/kernel-baosor"]
|
|
|
|
|
board-dabao = ["bao1x-hal/kernel-dabao"]
|
2025-05-18 01:24:22 +00:00
|
|
|
hosted-baosec = []
|
2024-10-04 05:05:59 +00:00
|
|
|
|
2023-03-14 14:39:19 +00:00
|
|
|
atsama5d27 = ["utralib/atsama5d27"]
|
2022-10-25 11:29:02 +00:00
|
|
|
precursor = ["utralib/precursor"]
|
2022-10-01 18:21:27 +00:00
|
|
|
hosted = ["utralib/hosted"]
|
2022-10-25 15:08:50 +00:00
|
|
|
renode = ["utralib/renode"]
|
2022-10-25 11:29:02 +00:00
|
|
|
|
2020-03-10 04:04:17 +00:00
|
|
|
debug-print = []
|
2026-01-13 19:19:35 +00:00
|
|
|
gdb-stub = ["gdbstub", "gdbstub_arch", "bao1x-api"]
|
2020-08-29 16:33:30 +00:00
|
|
|
print-panics = []
|
2026-01-13 19:19:35 +00:00
|
|
|
dump-kernel-pages = [] # include kernel pages in panic dumps
|
2020-07-15 09:08:05 +00:00
|
|
|
report-memory = ["stats_alloc"]
|
2021-03-23 11:52:53 +00:00
|
|
|
wrap-print = []
|
2026-01-13 19:19:35 +00:00
|
|
|
big-heap = [] # Cause heaps to start at 12 MM instead of 512 kB
|
2022-09-15 11:17:00 +00:00
|
|
|
v2p = ["xous-kernel/v2p"]
|
2024-05-12 08:28:14 +00:00
|
|
|
swap = ["xous-kernel/swap", "loader/swap"]
|
2025-05-11 04:50:02 +00:00
|
|
|
memmap-flash = []
|
2024-03-16 10:55:27 +00:00
|
|
|
debug-swap = []
|
2024-05-17 16:22:23 +00:00
|
|
|
debug-swap-verbose = []
|
2024-06-13 07:42:34 +00:00
|
|
|
raw-trng = ["xous-kernel/raw-trng"]
|
2026-01-07 18:56:33 +00:00
|
|
|
# this is somewhat unsafe because it introduces more attack surface for the kernel by allowing the
|
|
|
|
|
# userspace to hand it a random page from the caller's virtual memory space, and populate it with debug information
|
2025-12-09 08:19:04 +00:00
|
|
|
debug-proc = []
|
2023-07-17 10:49:21 +00:00
|
|
|
|
|
|
|
|
# patches for simulation targets ONLY. Applying these flags will result in totally broken security.
|
|
|
|
|
hwsim = []
|
|
|
|
|
|
2021-05-20 03:42:31 +00:00
|
|
|
# default = ["print-panics", "debug-print", "wrap-print"]
|
2025-12-09 08:19:04 +00:00
|
|
|
default = ["debug-proc", "print-panics"]
|
2020-07-28 05:28:14 +00:00
|
|
|
|
|
|
|
|
[target.'cfg(any(windows, unix))'.dependencies]
|
2021-05-19 06:18:46 +00:00
|
|
|
crossbeam-channel = "0.5"
|
|
|
|
|
hex = "0.4"
|
2020-07-29 13:18:30 +00:00
|
|
|
lazy_static = "1.4"
|
2023-04-25 14:09:41 +00:00
|
|
|
rand = "0.8.5"
|
2021-12-25 07:58:27 +00:00
|
|
|
rand_chacha = "0.3.1"
|