login 2813126e31
新增rust ffi (#77)
* 引入cargo

* 取消对Cargo.lock的跟踪

* 解决vscode报错问题

* new: rust的代码能够调用c语言的printk_color

* 1、将原本run.sh的工作拆解,变为几个不同的make命令
2、在docker镜像中编译rust

* 更改workflow

* update workflow

* new: 解决workflow无法通过编译的问题
2022-11-11 15:35:37 +08:00

36 lines
860 B
ArmAsm
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

#include"../common/asm.h"
/**
* @brief 导出内核线程的执行引导程序
* (kernel_thread)
* rsp
* 7unsigned longpt_regs
*/
ENTRY(kernel_thread_func)
popq %r15
popq %r14
popq %r13
popq %r12
popq %r11
popq %r10
popq %r9
popq %r8
popq %rbx
popq %rcx
popq %rdx
popq %rsi
popq %rdi
popq %rbp
popq %rax
movq %rax, %ds
popq %rax
movq %rax, %es
popq %rax
addq $0x20, %rsp
popfq
addq $0x10, %rsp
movq %rdx, %rdi
callq *%rbx
movq %rax, %rdi
callq process_do_exit