1
0
Fork 0

Compare commits

..

30 Commits

Author SHA1 Message Date
Simon Renblad 4376d5800c fix libconfig errors 2024-10-21 17:34:30 +08:00
Simon Renblad 5523d22e43 enable fatfs LFN + alloc 2024-10-21 15:31:40 +08:00
Simon Renblad 60aa4ce9bc remove LLVM 11 copy 2024-10-21 11:11:40 +08:00
Simon Renblad f16aa400f9 up LLVM version 2024-10-21 11:10:39 +08:00
Simon Renblad ed83a6d8af szl: replace as with cast 2024-10-17 16:43:17 +08:00
Simon Renblad 01fdb5dd95 switch to addr_of/addr_of_mut 2024-10-17 16:26:02 +08:00
Simon Renblad 123bedf0fe fixed libconfig warns 2024-10-17 16:25:07 +08:00
Simon Renblad e18f77fdea fixed sync_channel warnings 2024-10-17 16:24:12 +08:00
Simon Renblad 364b0a4bbb remove undefined behavior in asserts 2024-10-17 14:41:50 +08:00
Simon Renblad 239bd2e65f add xbuild target features 2024-10-17 11:21:41 +08:00
Simon Renblad e4914f5872 cargo: change resolver 2024-10-17 10:33:41 +08:00
Simon Renblad 85596cea79 unused libs, fixup 2024-10-15 17:14:31 +08:00
Simon Renblad 10b03da5ce fixed bugs + missing methods 2024-10-15 17:14:31 +08:00
Simon Renblad c528721b42 remove unnecessary feature attributes 2024-10-15 17:14:31 +08:00
Simon Renblad a35cc3dcc2 fix panic message 2024-10-15 17:14:31 +08:00
Simon Renblad 1c89a3c6d5 flake hashes 2024-10-15 17:14:31 +08:00
Simon Renblad 4e74e79a44 fix compiler builtins version 2024-10-15 17:14:31 +08:00
Simon Renblad c40a3f7518 add fatfs 0.4 dep 2024-10-15 17:14:30 +08:00
Simon Renblad 5c1912ebfc lockfile 2024-10-15 17:14:30 +08:00
Simon Renblad 8cda41d857 lockfile update 2024-10-15 17:14:30 +08:00
Simon Renblad d9baf0657f lockfile update 2024-10-15 17:14:30 +08:00
Simon Renblad b8491bc86d commit lockfile 2024-10-15 17:14:30 +08:00
Simon Renblad d87421efe7 szl switch to fatfs r/w traits 2024-10-15 17:14:30 +08:00
Simon Renblad bbd6e8bd52 remove core_io dependency from libconfig 2024-10-15 17:14:30 +08:00
Simon Renblad 7f21764ade remove usage of BufReader 2024-10-15 17:14:30 +08:00
Simon Renblad b29877b8f6 change fatfs to master 2024-10-15 17:14:30 +08:00
Simon Renblad 4e6ba57a01 remove core_io from Cargo.toml 2024-10-15 17:14:30 +08:00
Simon Renblad 0fe62c34eb up flake to 2024 sep nightly 2024-10-15 17:14:30 +08:00
Simon Renblad aa29c47c2b update version 2024-10-15 17:14:30 +08:00
Simon Renblad 1644e7a7bc llvm_asm -> asm 2024-10-15 17:14:30 +08:00
5 changed files with 30 additions and 31 deletions

46
Cargo.lock generated
View File

@ -4,9 +4,9 @@ version = 3
[[package]]
name = "bit_field"
version = "0.10.1"
version = "0.10.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "dcb6dd1c2376d2e096796e234a70e17e94cc2d5d54ff8ce42b28cef1d0d359a4"
checksum = "dc827186963e592360843fb5ba4b973e145841266c1357f7180c43526f2e5b61"
[[package]]
name = "bitflags"
@ -22,21 +22,18 @@ checksum = "b048fb63fd8b5923fc5aa7b340d8e156aec7ec02f0c78fa8a6ddc2613f6f71de"
[[package]]
name = "byteorder"
version = "1.4.3"
version = "1.5.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "14c189c53d098945499cdfa7ecc63567cf3886b3332b312a5b4585d8d3a6a610"
checksum = "1fd0f2584146f6f2ef48085050886acf353beff7305ebd1ae69500e27c67f64b"
[[package]]
name = "cc"
version = "1.0.73"
version = "1.1.24"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "2fff2a6927b3bb87f9595d67196a70493f627687a71d87a0d692242c33f58c11"
[[package]]
name = "cfg-if"
version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "baf1de4339761588bc0619e3cbc0120ee582ebb74b53b4efbf79117bd2da40fd"
checksum = "812acba72f0a070b003d3697490d2b55b837230ae7c6c6497f05cc2ddbb8d938"
dependencies = [
"shlex",
]
[[package]]
name = "compiler_builtins"
@ -82,7 +79,7 @@ version = "0.0.0"
dependencies = [
"embedded-hal",
"libcortex_a9",
"nb 1.0.0",
"nb 1.1.0",
"pin-utils",
"smoltcp",
]
@ -151,12 +148,9 @@ checksum = "822add9edb1860698b79522510da17bef885171f75aa395cff099d770c609c24"
[[package]]
name = "log"
version = "0.4.14"
version = "0.4.22"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "51b9bbe6c47d51fc3e1a9b945965946b4c44142ab8792c50835a980d362c2710"
dependencies = [
"cfg-if",
]
checksum = "a7a70ba024b9dc04c27ea2f0c0548feb474ec5c54bba33a7f72f873a39d07b24"
[[package]]
name = "managed"
@ -170,14 +164,14 @@ version = "0.1.3"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "801d31da0513b6ec5214e9bf433a77966320625a37860f910be265be6e18d06f"
dependencies = [
"nb 1.0.0",
"nb 1.1.0",
]
[[package]]
name = "nb"
version = "1.0.0"
version = "1.1.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "546c37ac5d9e56f55e73b677106873d9d9f5190605e41a856503623648488cae"
checksum = "8d5439c4ad607c3c23abf66de8c8bf57ba8adcd1f129e699851a6e43935d339d"
[[package]]
name = "pin-utils"
@ -191,6 +185,12 @@ version = "1.0.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "bd7a31eed1591dcbc95d92ad7161908e72f4677f8fabf2a32ca49b4237cbf211"
[[package]]
name = "shlex"
version = "1.3.0"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "0fda2ff0d084019ba4d7c6f371c95d8fd75ce3524c3cb8fb653a3023f6323e64"
[[package]]
name = "smoltcp"
version = "0.7.5"
@ -230,9 +230,9 @@ checksum = "6a02e4885ed3bc0f2de90ea6dd45ebcbb66dacffe03547fadbb0eeae2770887d"
[[package]]
name = "volatile-register"
version = "0.2.1"
version = "0.2.2"
source = "registry+https://github.com/rust-lang/crates.io-index"
checksum = "9ee8f19f9d74293faf70901bc20ad067dc1ad390d2cbf1e3f75f721ffee908b6"
checksum = "de437e2a6208b014ab52972a27e59b33fa2920d3e00fe05026167a1c509d19cc"
dependencies = [
"vcell",
]

View File

@ -73,7 +73,7 @@ fn read_to_end<'a>(file: &mut File<'a>, buffer: &mut Vec<u8>) -> Result<'a, ()>
fn read_to_string<'a>(file: &mut File<'a>) -> Result<'a, String> {
let mut buffer: Vec<u8> = Vec::new();
read_to_end(file, &mut buffer)?;
read_to_end(file, &mut buffer);
Ok(String::from_utf8(buffer)?)
}

View File

@ -172,6 +172,7 @@ impl<'a, T> Iterator for Receiver<'a, T> where T: Clone {
#[macro_export]
/// Macro for initializing the sync_channel with static buffer and indexes.
/// Note that this requires `#![feature(const_in_array_repeat_expressions)]`
macro_rules! sync_channel {
($t: ty, $cap: expr) => {
{

View File

@ -1,6 +1,6 @@
use core::{
ops::{Deref, DerefMut},
mem::{align_of, size_of},
ops::{Deref, DerefMut}
};
use alloc::alloc::{dealloc, Layout, LayoutError};
use crate::mmu::{L1_PAGE_SIZE, L1Table};
@ -20,7 +20,6 @@ impl<T> UncachedSlice<T> {
let layout = Layout::from_size_align(size, align)?;
let ptr = unsafe { alloc::alloc::alloc(layout).cast::<T>() };
let start = ptr as usize;
assert_eq!(start & (L1_PAGE_SIZE - 1), 0);
for page_start in (start..(start + size)).step_by(L1_PAGE_SIZE) {
// non-shareable device
@ -31,7 +30,6 @@ impl<T> UncachedSlice<T> {
l1_section.bufferable = false;
});
}
let slice = unsafe { core::slice::from_raw_parts_mut(ptr, len) };
// initialize
for e in slice.iter_mut() {

View File

@ -120,13 +120,13 @@ pub fn main_core0() {
slcr::BootModePins::Jtag => netboot::netboot(
&mut bootgen_file,
config,
addr_of_mut!(__runtime_start) as *mut u8,
addr_of_mut!(__runtime_start).cast(),
max_len,
),
slcr::BootModePins::SdCard => {
if boot_sd(
&mut bootgen_file,
addr_of_mut!(__runtime_start) as *mut u8,
addr_of_mut!(__runtime_start).cast(),
max_len,
)
.is_err()
@ -136,7 +136,7 @@ pub fn main_core0() {
netboot::netboot(
&mut bootgen_file,
config,
addr_of_mut!(__runtime_start) as *mut u8,
addr_of_mut!(__runtime_start).cast(),
max_len,
)
}
@ -147,7 +147,7 @@ pub fn main_core0() {
netboot::netboot(
&mut bootgen_file,
config,
addr_of_mut!(__runtime_start) as *mut u8,
addr_of_mut!(__runtime_start).cast(),
max_len,
)
}