mirror of
https://github.com/saymrwulf/xous-core.git
synced 2026-11-14 08:03:34 +00:00
flatipc is a new method for doing IPC. This is a zero-copy approach where structs are given `repr(C)` implementations that are well-defined and work across process boundaries. If the same struct or enum is used in two processes that has the same layout, then data can be freely passed between the two processes without incurring a serialization or deserialization penalty, provided the following hold: 1. The buffer must be page-aligned and be a multiple of the page size 2. The item must be `#[repr(C)]` 3. There must be no pointers or references of any kind If these three things hold, then the object is safe to sling across the process boundary. This crate adds the ability to annotate structs with `#[derive(flatipc::Ipc)]` to provide them with this functionality. When doing so, objects gain the `.into_ipc()` call that turns them into something that can be sent across process boundaries. The resulting object has `.lend()`, `.lend_mut()`, `.try_lend()`, and `.try_lend_mut()` as functions. Signed-off-by: Sean Cross <sean@xobs.io>
200 lines
5.5 KiB
TOML
200 lines
5.5 KiB
TOML
[workspace]
|
|
default-members = [
|
|
"services/xous-log",
|
|
"services/xous-ticktimer",
|
|
"services/xous-names",
|
|
"services/xous-susres",
|
|
"services/graphics-server",
|
|
"services/keyboard",
|
|
"services/com",
|
|
"services/trng",
|
|
"services/gam",
|
|
"services/status",
|
|
"services/ime-plugin-api",
|
|
"services/ime-frontend",
|
|
"services/ime-plugin-shell",
|
|
"services/content-plugin-api",
|
|
"services/shellchat",
|
|
"services/llio",
|
|
"services/codec",
|
|
"services/aes",
|
|
"services/spinor",
|
|
"services/root-keys",
|
|
"services/jtag",
|
|
"services/pddb",
|
|
"services/net",
|
|
"services/dns",
|
|
"services/modals",
|
|
"services/usb-device-xous",
|
|
"services/early_settings",
|
|
"libs/userprefs",
|
|
]
|
|
members = [
|
|
"xous-ipc",
|
|
"xous-rs",
|
|
"tools",
|
|
"services/graphics-server",
|
|
"services/xous-log",
|
|
"services/xous-ticktimer",
|
|
"services/xous-susres",
|
|
"services/xous-names",
|
|
"services/aes-test",
|
|
"services/com",
|
|
"services/keyboard",
|
|
"services/kernel-test",
|
|
"services/ticktimer-test-client",
|
|
"services/trng",
|
|
"services/gam",
|
|
"services/status",
|
|
"services/ime-frontend",
|
|
"services/ime-plugin-shell",
|
|
"services/ime-plugin-tts",
|
|
"services/shellchat",
|
|
"svd2repl",
|
|
"svd2utra",
|
|
"xtask",
|
|
"imports/getrandom",
|
|
"services/ime-plugin-api",
|
|
"services/content-plugin-api",
|
|
"services/llio",
|
|
"services/codec",
|
|
"services/aes",
|
|
"services/spinor",
|
|
"services/root-keys",
|
|
"services/jtag",
|
|
"tools/wycheproof-import",
|
|
"services/pddb",
|
|
"services/net",
|
|
"services/dns",
|
|
"services/log-test-client",
|
|
"services/test-spawn",
|
|
"services/modals",
|
|
"services/early_settings",
|
|
"apps/app-loader",
|
|
"apps/app-loader/spawn",
|
|
"apps/ball",
|
|
"apps/hello",
|
|
"apps/mtxchat",
|
|
"apps/mtxcli",
|
|
"apps/repl",
|
|
"apps/vault",
|
|
"apps/vault/tools/vaultbackup-rs",
|
|
"apps/transientdisk",
|
|
"apps/chat-test",
|
|
"apps/hidv2",
|
|
"services/libstd-test",
|
|
"services/ffi-test",
|
|
"services/tts",
|
|
"services/cram-console",
|
|
"services/cram-mbox1",
|
|
"services/cram-mbox2",
|
|
#"services/test-spawn",
|
|
#"services/test-spawn/spawn",
|
|
"services/usb-test",
|
|
"services/usb-device-xous",
|
|
"kernel",
|
|
"loader",
|
|
"libs/chat",
|
|
"libs/flatipc",
|
|
"libs/flatipc-derive",
|
|
"libs/perflib",
|
|
"libs/tls",
|
|
"libs/userprefs",
|
|
"libs/xous-pio",
|
|
"libs/xous-bio",
|
|
"libs/xous-bio-bdma",
|
|
"libs/xous-pl230",
|
|
"libs/cramium-hal",
|
|
"services/cram-hal-service",
|
|
"services/xous-swapper",
|
|
"services/test-swapper",
|
|
"services/cram-console",
|
|
]
|
|
resolver = "2"
|
|
|
|
# These packages have custom RUSTFLAGS, so if they
|
|
# were included in the workspace they would cause
|
|
# packages to be rebuilt every time they were touched.
|
|
# Keep them out of the main workspace.
|
|
exclude = [
|
|
"utralib", # Exclude UTRA, since it is machine-generated.
|
|
"locales", # exclude because it is machine-generated
|
|
"xtask",
|
|
# exclude the API crates, as they are domiciled here but referenced via crates.io
|
|
"api/xous-api-log",
|
|
"api/xous-api-names",
|
|
"api/xous-api-susres",
|
|
"api/xous-api-ticktimer",
|
|
# The "packing" crate is forked and is a separate workspace
|
|
"libs/mass-storage/packing",
|
|
# This directory is dedicated to out-of-tree tests and examples
|
|
"planning/",
|
|
]
|
|
|
|
[profile.release]
|
|
codegen-units = 1 # 1 better optimizations
|
|
debug = false
|
|
strip = false
|
|
lto = "fat"
|
|
incremental = true
|
|
#panic = "abort" # Remove panic output, which can reduce file size
|
|
opt-level = "s" # z,s: Optimize for size instead of performance; 1 for easier debugging; comment out for "best performance" (but in Rust 1.72 this causes regressions)
|
|
|
|
# prefer hardware-accelerated versions of services
|
|
[patch.crates-io]
|
|
sha2 = { git = "https://github.com/betrusted-io/hashes.git", branch = "sha2-v0.10.8-xous" }
|
|
# sha2 = { path = "../hashes/sha2" }
|
|
|
|
[patch.crates-io.aes]
|
|
path = "services/aes"
|
|
|
|
[patch.crates-io.curve25519-dalek]
|
|
git = "https://github.com/betrusted-io/curve25519-dalek.git"
|
|
branch = "main"
|
|
# path = "../curve25519-dalek/curve25519-dalek" # when doing local dev work
|
|
# feature overrides are specified at the crate level
|
|
|
|
[patch.crates-io.usb-device]
|
|
git = "https://github.com/betrusted-io/usb-device.git"
|
|
branch = "main"
|
|
# local dev shortcuts
|
|
# path = "../usb-device"
|
|
|
|
[patch.crates-io.getrandom]
|
|
path = "imports/getrandom"
|
|
|
|
[patch.crates-io.ring]
|
|
# path = "../ring-xous" # for local dev only
|
|
git = "https://github.com/betrusted-io/ring-xous"
|
|
rev = "5f86cb10bebd521a45fb3abb06995200aeda2948" # use the commitref because we're still updating the branch
|
|
#branch="0.16.20-cleanup"
|
|
|
|
######################################################
|
|
### PATCHES TO DEV/TEST XOUS KERNEL CODE
|
|
###
|
|
### The kernel is published to crates.io, and all the packages in Xous are configured to get
|
|
### the kernel from crates.io and NOT the local tree.
|
|
###
|
|
### When making changes to the kernel, you must activate some or all of the patches below
|
|
### for the local sources to "see" the changes.
|
|
### You will also need to compile with `--no-verify` to acknowledge that you are doing local
|
|
### source development and accept that what's on crates.io doesn't match what's inside this tree.
|
|
#######################################################
|
|
|
|
### Selectively patch in these crates, or more, as needed depending on your dev activity
|
|
[patch.crates-io.utralib]
|
|
path = "./utralib"
|
|
[patch.crates-io.svd2utra]
|
|
path = "./svd2utra"
|
|
# [patch.crates-io.xous]
|
|
# path = "./xous-rs"
|
|
# [patch.crates-io.xous-ipc]
|
|
# path = "./xous-ipc"
|
|
# [patch.crates-io.xous-api-names]
|
|
# path = "./api/xous-api-names"
|
|
# [patch.crates-io.xous-api-susres]
|
|
# path = "./api/xous-api-susres"
|
|
# [patch.crates-io.xous-api-log]
|
|
# path = "./api/xous-api-log"
|
|
# [patch.crates-io.xous-api-ticktimer]
|
|
# path = "./api/xous-api-ticktimer"
|