mirror of
https://gitlab.redox-os.org/redox-os/redox.git
synced 2026-06-20 11:54:17 +08:00
remove bochs breaks
This commit is contained in:
parent
a5d79d7957
commit
fcec69efdc
@ -13,17 +13,16 @@ pub unsafe extern fn syscall() {
|
||||
let d;
|
||||
let e;
|
||||
let f;
|
||||
asm!("xchg bx, bx" : "={rax}"(a), "={rbx}"(b), "={rcx}"(c), "={rdx}"(d), "={rsi}"(e), "={rdi}"(f)
|
||||
asm!("" : "={rax}"(a), "={rbx}"(b), "={rcx}"(c), "={rdx}"(d), "={rsi}"(e), "={rdi}"(f)
|
||||
: : : "intel", "volatile");
|
||||
|
||||
a = syscall(a, b, c, d, e, f);
|
||||
}
|
||||
|
||||
asm!("xchg bx, bx" : : "{rax}"(a) : : "intel", "volatile");
|
||||
asm!("" : : "{rax}"(a) : : "intel", "volatile");
|
||||
}
|
||||
|
||||
asm!("xchg bx, bx
|
||||
push fs
|
||||
asm!("push fs
|
||||
push rax
|
||||
mov rax, 0x18
|
||||
mov fs, ax
|
||||
@ -33,8 +32,7 @@ pub unsafe extern fn syscall() {
|
||||
inner();
|
||||
|
||||
// Interrupt return
|
||||
asm!("xchg bx, bx
|
||||
pop fs
|
||||
asm!("pop fs
|
||||
iretq"
|
||||
: : : : "intel", "volatile");
|
||||
}
|
||||
|
||||
@ -48,8 +48,7 @@ macro_rules! interrupt {
|
||||
}
|
||||
|
||||
// Push scratch registers
|
||||
asm!("xchg bx, bx
|
||||
push rax
|
||||
asm!("push rax
|
||||
push rcx
|
||||
push rdx
|
||||
push rdi
|
||||
@ -67,8 +66,7 @@ macro_rules! interrupt {
|
||||
inner();
|
||||
|
||||
// Pop scratch registers and return
|
||||
asm!("xchg bx, bx
|
||||
pop fs
|
||||
asm!("pop fs
|
||||
pop r11
|
||||
pop r10
|
||||
pop r9
|
||||
@ -95,8 +93,7 @@ macro_rules! interrupt_error {
|
||||
}
|
||||
|
||||
// Push scratch registers
|
||||
asm!("xchg bx, bx
|
||||
push rax
|
||||
asm!("push rax
|
||||
push rcx
|
||||
push rdx
|
||||
push rdi
|
||||
@ -114,8 +111,7 @@ macro_rules! interrupt_error {
|
||||
inner();
|
||||
|
||||
// Pop scratch registers, error code, and return
|
||||
asm!("xchg bx, bx
|
||||
pop fs
|
||||
asm!("pop fs
|
||||
pop r11
|
||||
pop r10
|
||||
pop r9
|
||||
|
||||
@ -204,8 +204,7 @@ pub unsafe extern fn kstart_ap(stack_start: usize, stack_end: usize) -> ! {
|
||||
|
||||
pub unsafe fn usermode(ip: usize, sp: usize) {
|
||||
// Test usermode
|
||||
asm!("xchg bx, bx
|
||||
mov rax, 0x2B
|
||||
asm!("mov rax, 0x2B
|
||||
mov ds, ax
|
||||
mov es, ax
|
||||
mov fs, ax
|
||||
|
||||
Loading…
Reference in New Issue
Block a user