|
|
@ -156,8 +156,7 @@ impl Context {
|
|
|
|
/// Push all callee-saved registers at the current kernel stack.
|
|
|
|
/// Push all callee-saved registers at the current kernel stack.
|
|
|
|
/// Store current sp, switch to target.
|
|
|
|
/// Store current sp, switch to target.
|
|
|
|
/// Pop all callee-saved registers, then return to the target.
|
|
|
|
/// Pop all callee-saved registers, then return to the target.
|
|
|
|
#[naked]
|
|
|
|
#[inline(always)]
|
|
|
|
#[inline(never)]
|
|
|
|
|
|
|
|
pub unsafe extern fn switch(&mut self, _target: &mut Self) {
|
|
|
|
pub unsafe extern fn switch(&mut self, _target: &mut Self) {
|
|
|
|
extern {
|
|
|
|
extern {
|
|
|
|
fn switch_context(src : &mut Context, dst : &mut Context);
|
|
|
|
fn switch_context(src : &mut Context, dst : &mut Context);
|
|
|
|