File tree Expand file tree Collapse file tree 4 files changed +16
-9
lines changed
Expand file tree Collapse file tree 4 files changed +16
-9
lines changed Original file line number Diff line number Diff line change @@ -27,6 +27,11 @@ logger = []
2727# were observed on the VirtualBox UEFI implementation (see uefi-rs#121).
2828# In those cases, this feature can be excluded by removing the default features.
2929panic-on-logger-errors = []
30+ # high level FS abstraction
31+ fs = [
32+ " alloc" ,
33+ " exts"
34+ ]
3035
3136[dependencies ]
3237bitflags = " 1.3.1"
Original file line number Diff line number Diff line change @@ -48,8 +48,9 @@ impl From<PathError> for FileSystemError {
4848/// Return type for public [FileSystem] operations.
4949pub type FileSystemResult < T > = Result < T , FileSystemError > ;
5050
51- /// Entry point into the file system abstraction described by the module description. Accessor to
52- /// an UEFI volume. Available methods try to be close to the `fs` module of `libstd`.
51+ /// The file system abstraction provided by this module. It acts as convenient accessor to an UEFI
52+ /// volume in top of the [`SimpleFileSystemProtocol`]. The available methods try to be close to the
53+ /// `fs` module from the Rust standard library.
5354///
5455/// # Technical Background
5556/// Some random interesting information how this abstraction helps.
@@ -63,7 +64,7 @@ pub struct FileSystem<'name, 'boot_services> {
6364}
6465
6566impl < ' name , ' boot_services > FileSystem < ' name , ' boot_services > {
66- /// Constructor. The name is only used to help you as a user to identify this file system.
67+ /// Constructor. The name is only used to help developers to identify this file system.
6768 /// This may be "root", "main", or "boot".
6869 pub fn new (
6970 name : & ' name str ,
Original file line number Diff line number Diff line change 1- //! A high-level file system API for UEFI applications. It supports you to conveniently perform the
2- //! following important operations:
1+ //! A high-level file system API for UEFI applications. It supports developers to conveniently
2+ //! perform the following operations:
33//! - read file to bytes
44//! - write bytes to file
55//! - create files
1919//! `&str` and validated internally. There are no `File` objects that are exposed to users.
2020//!
2121//! The difference to using the [SimpleFileSystemProtocol] directly is that the abstractions in this
22- //! module take care of automatic release of resources and support you by returning data owned on
23- //! the heap (such as file info). There is no synchronization as it is untypically that users
24- //! bootstrap Application Processors (AP) during the UEFI stage, i.e., before hand-off to a kernel.
22+ //! module take care of automatic release of resources and support developers by returning data
23+ //! owned on the heap (such as file info). There is no synchronization as it is untypically that
24+ //! users bootstrap Application Processors (AP) during the UEFI stage, i.e., before hand-off to a
25+ //! kernel.
2526
2627mod dir_entry_iter;
2728mod file_info;
Original file line number Diff line number Diff line change @@ -64,5 +64,5 @@ pub mod alloc;
6464#[ cfg( feature = "logger" ) ]
6565pub mod logger;
6666
67- #[ cfg( all ( feature = "exts" , feature = "alloc" ) ) ]
67+ #[ cfg( feature = "fs" ) ]
6868pub mod fs;
You can’t perform that action at this time.
0 commit comments