diff options
author | 2022-02-21 19:57:18 +0000 | |
---|---|---|
committer | 2022-02-24 01:44:11 +0000 | |
commit | 894f2aabdbd65f85eecf25debc2326f0387863c7 (patch) | |
tree | f08ad0ca10df764c5b29549421e874c4c3512bec /cortex-m-semihosting/src/lib.rs | |
parent | 9e8dd294b04510d727d50039a7f84292789aed0e (diff) | |
download | cortex-m-894f2aabdbd65f85eecf25debc2326f0387863c7.tar.gz cortex-m-894f2aabdbd65f85eecf25debc2326f0387863c7.tar.zst cortex-m-894f2aabdbd65f85eecf25debc2326f0387863c7.zip |
Remove outlined asm, replace with stable inline asm.
Diffstat (limited to 'cortex-m-semihosting/src/lib.rs')
-rw-r--r-- | cortex-m-semihosting/src/lib.rs | 18 |
1 files changed, 1 insertions, 17 deletions
diff --git a/cortex-m-semihosting/src/lib.rs b/cortex-m-semihosting/src/lib.rs index 3bc23ea..4ff975d 100644 --- a/cortex-m-semihosting/src/lib.rs +++ b/cortex-m-semihosting/src/lib.rs @@ -151,14 +151,6 @@ //! //! # Optional features //! -//! ## `inline-asm` -//! -//! When this feature is enabled semihosting is implemented using inline assembly and -//! compiling this crate requires nightly. -//! -//! When this feature is disabled semihosting is implemented using FFI calls into an external -//! assembly file and compiling this crate works on stable and beta. -//! //! ## `jlink-quirks` //! //! When this feature is enabled, return values above `0xfffffff0` from semihosting operation @@ -191,11 +183,6 @@ pub mod export; pub mod hio; pub mod nr; -#[cfg(all(thumb, not(feature = "inline-asm")))] -extern "C" { - fn __sh_syscall(nr: usize, arg: usize) -> usize; -} - /// Performs a semihosting operation, takes a pointer to an argument block #[inline(always)] pub unsafe fn syscall<T>(nr: usize, arg: &T) -> usize { @@ -206,10 +193,7 @@ pub unsafe fn syscall<T>(nr: usize, arg: &T) -> usize { #[inline(always)] pub unsafe fn syscall1(_nr: usize, _arg: usize) -> usize { match () { - #[cfg(all(thumb, not(feature = "inline-asm"), not(feature = "no-semihosting")))] - () => __sh_syscall(_nr, _arg), - - #[cfg(all(thumb, feature = "inline-asm", not(feature = "no-semihosting")))] + #[cfg(all(thumb, not(feature = "no-semihosting")))] () => { let mut nr = _nr; core::arch::asm!( |