aboutsummaryrefslogtreecommitdiff
path: root/src/syscall.rs
diff options
context:
space:
mode:
authorGravatar Gerd Zellweger <mail@gerdzellweger.com> 2016-01-15 08:41:06 +0100
committerGravatar Gerd Zellweger <mail@gerdzellweger.com> 2016-01-15 08:41:06 +0100
commit36d60cd9a76fd496dbbff780942364fc88a60259 (patch)
tree55043b1fc6edf4c24a893fbfa096b83954188679 /src/syscall.rs
parent19a86adc76cc4e931a2cf91a473eefebe6898632 (diff)
downloadrust-x86-36d60cd9a76fd496dbbff780942364fc88a60259.tar.gz
rust-x86-36d60cd9a76fd496dbbff780942364fc88a60259.tar.zst
rust-x86-36d60cd9a76fd496dbbff780942364fc88a60259.zip
Formatting with new cargo fmt command.
Signed-off-by: Gerd Zellweger <mail@gerdzellweger.com>
Diffstat (limited to 'src/syscall.rs')
-rw-r--r--src/syscall.rs12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/syscall.rs b/src/syscall.rs
index 01d87fd..c554177 100644
--- a/src/syscall.rs
+++ b/src/syscall.rs
@@ -12,7 +12,6 @@
/// * Only values of class INTEGER or class MEMORY are passed to the kernel.
///
/// This code is inspired by the syscall.rs (https://github.com/kmcallister/syscall.rs/) project.
-
#[macro_export]
macro_rules! syscall {
($arg0:expr)
@@ -98,7 +97,14 @@ pub unsafe fn syscall5(arg0: u64, arg1: u64, arg2: u64, arg3: u64, arg4: u64, ar
#[inline(always)]
#[allow(unused_mut)]
-pub unsafe fn syscall6(arg0: u64, arg1: u64, arg2: u64, arg3: u64, arg4: u64, arg5: u64, arg6: u64) -> u64 {
+pub unsafe fn syscall6(arg0: u64,
+ arg1: u64,
+ arg2: u64,
+ arg3: u64,
+ arg4: u64,
+ arg5: u64,
+ arg6: u64)
+ -> u64 {
let mut ret: u64;
asm!("syscall" : "={rax}" (ret)
: "{rax}" (arg0), "{rdi}" (arg1), "{rsi}" (arg2), "{rdx}" (arg3),
@@ -106,4 +112,4 @@ pub unsafe fn syscall6(arg0: u64, arg1: u64, arg2: u64, arg3: u64, arg4: u64, ar
: "rcx", "r11", "memory"
: "volatile");
ret
-} \ No newline at end of file
+}