Skip to content

Commit

Permalink
eclic: move eclic-mode-hack.S into Rust
Browse files Browse the repository at this point in the history
Uses inline assembly to move the code from `eclic-mode-hack.S` into
Rust.

The generated assembly is different. This commit should be reverted if
regressions are noticed on real hardware.
  • Loading branch information
rmsyn committed May 27, 2023
1 parent 6fce78c commit 51a9fbd
Show file tree
Hide file tree
Showing 6 changed files with 268 additions and 377 deletions.
11 changes: 0 additions & 11 deletions assemble.sh

This file was deleted.

Binary file removed bin/gd32vf103xx-hal.a
Binary file not shown.
21 changes: 0 additions & 21 deletions build.rs

This file was deleted.

345 changes: 0 additions & 345 deletions eclic-mode-hack.S

This file was deleted.

4 changes: 4 additions & 0 deletions src/eclic.rs
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
use crate::pac::{ECLIC, Interrupt};

/// The code is based on vendor provided HAL libraries.
/// Most code come from Firmware\RISCV\env_Eclipse\start.S
pub mod mode;

const EFFECTIVE_LEVEL_PRIORITY_BITS: u8 = 4;

#[repr(u8)]
Expand Down
Loading

0 comments on commit 51a9fbd

Please sign in to comment.