-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
This API was added in the latest nightly. Signed-off-by: Sean Cross <[email protected]>
- Loading branch information
Showing
2 changed files
with
28 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,18 +1,18 @@ | ||
From a30bd1caabe9d801c0fd57d89eadbce48d8aa010 Mon Sep 17 00:00:00 2001 | ||
From d1db9dbb558fa1cdef82459da443d751dcf2af8b Mon Sep 17 00:00:00 2001 | ||
From: Sean Cross <[email protected]> | ||
Date: Tue, 7 Nov 2023 10:41:10 +0800 | ||
Subject: [PATCH 3/5] xous: fs: add initial filesystem support | ||
Subject: [PATCH 3/4] xous: fs: add initial filesystem support | ||
|
||
Signed-off-by: Sean Cross <[email protected]> | ||
--- | ||
library/std/src/os/xous/fs.rs | 33 ++ | ||
library/std/src/os/xous/mod.rs | 3 + | ||
library/std/src/os/xous/path.rs | 42 ++ | ||
library/std/src/os/xous/services.rs | 3 + | ||
library/std/src/os/xous/services/pddb.rs | 88 ++++ | ||
library/std/src/sys/pal/xous/fs.rs | 629 +++++++++++++++++++++++ | ||
library/std/src/os/xous/services/pddb.rs | 88 +++ | ||
library/std/src/sys/pal/xous/fs.rs | 646 +++++++++++++++++++++++ | ||
library/std/src/sys/pal/xous/mod.rs | 1 - | ||
7 files changed, 798 insertions(+), 1 deletion(-) | ||
7 files changed, 815 insertions(+), 1 deletion(-) | ||
create mode 100644 library/std/src/os/xous/fs.rs | ||
create mode 100644 library/std/src/os/xous/path.rs | ||
create mode 100644 library/std/src/os/xous/services/pddb.rs | ||
|
@@ -229,10 +229,10 @@ index 00000000000..f8459b5bac9 | |
+} | ||
diff --git a/library/std/src/sys/pal/xous/fs.rs b/library/std/src/sys/pal/xous/fs.rs | ||
new file mode 100644 | ||
index 00000000000..fb2182e2091 | ||
index 00000000000..d2543909a92 | ||
--- /dev/null | ||
+++ b/library/std/src/sys/pal/xous/fs.rs | ||
@@ -0,0 +1,629 @@ | ||
@@ -0,0 +1,646 @@ | ||
+use alloc::str::FromStr; | ||
+ | ||
+use crate::ffi::OsString; | ||
|
@@ -489,17 +489,34 @@ index 00000000000..fb2182e2091 | |
+ } | ||
+ | ||
+ pub fn fsync(&self) -> io::Result<()> { | ||
+ // println!("rust: File::fsync()"); | ||
+ unsupported() | ||
+ } | ||
+ | ||
+ pub fn datasync(&self) -> io::Result<()> { | ||
+ // println!("rust: File::datasync()"); | ||
+ unsupported() | ||
+ } | ||
+ | ||
+ pub fn lock(&self) -> io::Result<()> { | ||
+ unsupported() | ||
+ } | ||
+ | ||
+ pub fn lock_shared(&self) -> io::Result<()> { | ||
+ unsupported() | ||
+ } | ||
+ | ||
+ pub fn try_lock(&self) -> io::Result<bool> { | ||
+ unsupported() | ||
+ } | ||
+ | ||
+ pub fn try_lock_shared(&self) -> io::Result<bool> { | ||
+ unsupported() | ||
+ } | ||
+ | ||
+ pub fn unlock(&self) -> io::Result<()> { | ||
+ unsupported() | ||
+ } | ||
+ | ||
+ pub fn truncate(&self, _size: u64) -> io::Result<()> { | ||
+ // println!("rust: File::truncate()"); | ||
+ unsupported() | ||
+ } | ||
+ | ||
|
Submodule rust
updated
3683 files