feat: 初步支持 USB 网卡桥接;删除 OTG 端点预算管理

This commit is contained in:
mofeng-git
2026-07-16 19:19:24 +08:00
parent 63c2bb4ca2
commit 213359b6c8
35 changed files with 2367 additions and 727 deletions

View File

@@ -1,8 +1,9 @@
//! USB OTG composite gadget (HID + MSD).
//! USB OTG composite gadget (HID + MSD + Ethernet).
#[cfg(unix)]
pub mod bridge;
#[cfg(unix)]
pub mod configfs;
pub mod endpoint;
#[cfg(unix)]
pub mod function;
#[cfg(unix)]
@@ -11,6 +12,8 @@ pub mod hid;
pub mod manager;
#[cfg(unix)]
pub mod msd;
#[cfg(unix)]
pub mod network;
pub mod report_desc;
pub mod self_check;
#[cfg(unix)]
@@ -21,7 +24,9 @@ pub use manager::{wait_for_hid_devices, OtgGadgetManager};
#[cfg(unix)]
pub use msd::{MsdFunction, MsdLunConfig};
#[cfg(unix)]
pub use service::{HidDevicePaths, OtgService};
pub use network::NetworkFunction;
#[cfg(unix)]
pub use service::{HidDevicePaths, OtgNetworkStatus, OtgRuntimeHealth, OtgService};
/// List USB Device Controller names exposed by sysfs.
pub fn list_udc_devices() -> Vec<String> {