feat(kernel): console cap gates DebugPutchar, no uart fast path; spawn start arg in a0; delegate returns slot
This commit is contained in:
@@ -3,7 +3,7 @@ use super::{TrapFrame, write_result};
|
||||
/// Syscalls answered without the kernel lock because they touch nothing it
|
||||
/// guards. A pending IPI or reschedule request forces the slow path.
|
||||
pub(super) fn fast_syscall(frame: &mut TrapFrame) -> bool {
|
||||
use types::syscall_abi::{SYS_DEBUG_PUTCHAR, SYS_GET_PROCESS_ID, SYS_GET_TIME, SYS_YIELD};
|
||||
use types::syscall_abi::{SYS_GET_PROCESS_ID, SYS_GET_TIME, SYS_YIELD};
|
||||
if crate::smp::has_pending_request() {
|
||||
return false;
|
||||
}
|
||||
@@ -13,10 +13,6 @@ pub(super) fn fast_syscall(frame: &mut TrapFrame) -> bool {
|
||||
Some(pid) => kernel::SyscallResult::Value(pid),
|
||||
None => return false,
|
||||
},
|
||||
SYS_DEBUG_PUTCHAR => {
|
||||
crate::hw::uart::Uart::new().put_char(frame.regs[10] as u8);
|
||||
kernel::SyscallResult::Ok
|
||||
}
|
||||
SYS_YIELD if crate::smp::yield_is_noop() => kernel::SyscallResult::Ok,
|
||||
_ => return false,
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user