Skip to main content

svc2

Macro svc2 

Source
macro_rules! svc2 {
    ($num:expr, $arg0:expr, $arg1:expr) => { ... };
}
Expand description

Generate an SVC call with 2 parameters

Puts the first argument in the instruction, and the parameters in r0-r1. Gives you back the value left in r0 by the handler.

const SYSCALL_FOO: u32 = 0x100;
let result = svc2!(0x00, SYSCALL_FOO, 1);