diff --git a/risc_v/src/fs.rs b/risc_v/src/fs.rs index 7d22c8c..1525ff5 100755 --- a/risc_v/src/fs.rs +++ b/risc_v/src/fs.rs @@ -192,7 +192,7 @@ impl MinixFileSystem { /// The goal of open is to traverse the path given by path. If we cache the inodes /// in RAM, it might make this much quicker. For now, this doesn't do anything since /// we're just testing read based on if we know the Inode we're looking for. - pub fn open(bdev: usize, path: &String) -> Result { + pub fn open(bdev: usize, path: &str) -> Result { if let Some(cache) = unsafe { MFS_INODE_CACHE[bdev-1].take() } { let ret; if let Some(inode) = cache.get(path) { diff --git a/risc_v/src/test.rs b/risc_v/src/test.rs index 5347fc0..30e5030 100644 --- a/risc_v/src/test.rs +++ b/risc_v/src/test.rs @@ -5,7 +5,6 @@ use crate::{elf, fs::MinixFileSystem, process::{PROCESS_LIST, PROCESS_LIST_MUTEX}}; -use alloc::string::String; /// Test block will load raw binaries into memory to execute them. This function /// will load ELF files and try to execute them. @@ -15,7 +14,7 @@ pub fn test() { // This could be better. We should see what our probe gave us, and it if is // a block device, init the filesystem. MinixFileSystem::init(BDEV); - let file_to_read = String::from("/helloworld.elf"); + let file_to_read = "/helloworld.elf"; let desc = MinixFileSystem::open(BDEV, &file_to_read).ok(); if desc.is_none() { println!("Error reading {}", file_to_read);