Add syscall handler, still work in progress

Add elf files
This commit is contained in:
Jeremy Soller 2016-08-18 19:44:31 -06:00
parent 71a17070b1
commit 5588c38178
11 changed files with 263 additions and 18 deletions

View file

@ -106,3 +106,11 @@ pub fn handle(a: usize, b: usize, c: usize, d: usize, e: usize, _f: usize) -> ::
Call::Unknown => Err(Error::NoCall)
}.map_err(|err| err.into())
}
#[no_mangle]
pub extern fn syscall(a: usize, b: usize, c: usize, d: usize, e: usize, f: usize) -> usize {
match handle(a, b, c, d, e, f) {
Ok(value) => value,
Err(value) => !value
}
}