strat9_kernel/async_io/mod.rs
1/*
2 * This file is part of strat9-os.
3 *
4 * strat9-os is free software: you can redistribute it and/or modify
5 * it under the terms of the GNU General Public License as published by
6 * the Free Software Foundation, either version 3 of the License, or
7 * (at your option) any later version.
8 *
9 * strat9-os is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
12 * GNU General Public License for more details.
13 *
14 * You should have received a copy of the GNU General Public License
15 * along with strat9-os. If not, see <https://www.gnu.org/licenses/>.
16 *
17 * Website: https://www.strat9-os.org
18 * Repository: https://github.com/strat9-os/strat9-os
19 *
20 * Copyright (C) 2023-26 Guillaume Gielly
21 */
22
23//! Asynchronous I/O subsystem.
24//!
25//! Provides shared ring buffers (SQ/CQ) for zero-copy I/O submission
26//! and completion between userspace and kernel.
27//!
28//! # Status
29//!
30//! - IMPLEMENTED : ring buffer, dispatch (Nop/VFS/IPC/Storage),
31//! AHCI IRQ => CQE bridge. See GitLab issue for details.
32//!
33//! # TODO
34//!
35//! - `Read`/`Write` VFS: switch from synchronous (blocking scheme::read) to
36//! truly async via the `AsyncScheme` trait
37//! - `Open`/`Close`/`Stat`: implement dispatch handlers
38//! - `IpcCall`: implement combined send+recv
39//! - `PollAdd`/`PollRemove`: epoll-like support
40//! - `Timeout`/`TimeoutRemove`: async timer
41//! - `Accept`/`Connect`: async networking
42//! - `Cancel`: implement actual cancellation of in-flight ops
43//! - Efficient blocking: use `ring.wq.wait_until()` instead of
44//! `yield_task()` in `SYS_ASYNC_ENTER`
45//! - Multi-slot AHCI (queue depth > 1 per port)
46//! - Userspace runtime (`libasync`) + Rust async/await compatibility
47//! - Safety audit (IRQ-safety of SpinLocks, stack overflow)
48//!
49//! Tracking : <https://git.strat9-os.org/strat9-os/strat9-os/-/issues/53>
50
51pub mod complete;
52pub mod dispatch;
53pub mod ops;
54pub mod ring;
55pub mod syscall;