mirror of
https://github.com/RGBCube/serenity
synced 2025-07-23 13:17:36 +00:00
Kernel: Add more AARCH64 stubs
This commit is contained in:
parent
bf3c99ef23
commit
63a91d6971
4 changed files with 34 additions and 0 deletions
|
@ -5,6 +5,7 @@
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include <AK/Format.h>
|
#include <AK/Format.h>
|
||||||
|
#include <AK/Vector.h>
|
||||||
|
|
||||||
#include <Kernel/Arch/Processor.h>
|
#include <Kernel/Arch/Processor.h>
|
||||||
#include <Kernel/Arch/aarch64/ASM_wrapper.h>
|
#include <Kernel/Arch/aarch64/ASM_wrapper.h>
|
||||||
|
@ -58,4 +59,18 @@ u32 Processor::clear_critical()
|
||||||
TODO_AARCH64();
|
TODO_AARCH64();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
u32 Processor::smp_wake_n_idle_processors(u32 wake_count)
|
||||||
|
{
|
||||||
|
(void)wake_count;
|
||||||
|
TODO_AARCH64();
|
||||||
|
}
|
||||||
|
|
||||||
|
ErrorOr<Vector<FlatPtr, 32>> Processor::capture_stack_trace(Thread& thread, size_t max_frames)
|
||||||
|
{
|
||||||
|
(void)thread;
|
||||||
|
(void)max_frames;
|
||||||
|
TODO_AARCH64();
|
||||||
|
return Vector<FlatPtr, 32> {};
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -160,6 +160,8 @@ public:
|
||||||
VERIFY(!Processor::in_critical());
|
VERIFY(!Processor::in_critical());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
ALWAYS_INLINE static FPUState const& clean_fpu_state() { TODO_AARCH64(); }
|
||||||
|
|
||||||
// FIXME: Actually return the idle thread once aarch64 supports threading.
|
// FIXME: Actually return the idle thread once aarch64 supports threading.
|
||||||
ALWAYS_INLINE static Thread* idle_thread()
|
ALWAYS_INLINE static Thread* idle_thread()
|
||||||
{
|
{
|
||||||
|
@ -182,8 +184,12 @@ public:
|
||||||
TODO_AARCH64();
|
TODO_AARCH64();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static u32 smp_wake_n_idle_processors(u32 wake_count);
|
||||||
|
|
||||||
[[noreturn]] static void halt();
|
[[noreturn]] static void halt();
|
||||||
|
|
||||||
|
static ErrorOr<Vector<FlatPtr, 32>> capture_stack_trace(Thread& thread, size_t max_frames = 0);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
u32 m_in_critical { 0 };
|
u32 m_in_critical { 0 };
|
||||||
|
|
||||||
|
|
|
@ -15,7 +15,17 @@ namespace Kernel {
|
||||||
|
|
||||||
struct RegisterState {
|
struct RegisterState {
|
||||||
FlatPtr userspace_sp() const { return 0; }
|
FlatPtr userspace_sp() const { return 0; }
|
||||||
|
void set_userspace_sp(FlatPtr value)
|
||||||
|
{
|
||||||
|
(void)value;
|
||||||
|
TODO_AARCH64();
|
||||||
|
}
|
||||||
FlatPtr ip() const { return 0; }
|
FlatPtr ip() const { return 0; }
|
||||||
|
void set_ip(FlatPtr value)
|
||||||
|
{
|
||||||
|
(void)value;
|
||||||
|
TODO_AARCH64();
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
inline void copy_kernel_registers_into_ptrace_registers(PtraceRegisters& ptrace_regs, RegisterState const& kernel_regs)
|
inline void copy_kernel_registers_into_ptrace_registers(PtraceRegisters& ptrace_regs, RegisterState const& kernel_regs)
|
||||||
|
|
|
@ -189,6 +189,9 @@ LockRefPtr<Process> Process::create_kernel_process(LockRefPtr<Thread>& first_thr
|
||||||
first_thread->regs().esp = FlatPtr(entry_data); // entry function argument is expected to be in regs.esp
|
first_thread->regs().esp = FlatPtr(entry_data); // entry function argument is expected to be in regs.esp
|
||||||
#elif ARCH(X86_64)
|
#elif ARCH(X86_64)
|
||||||
first_thread->regs().rdi = FlatPtr(entry_data); // entry function argument is expected to be in regs.rdi
|
first_thread->regs().rdi = FlatPtr(entry_data); // entry function argument is expected to be in regs.rdi
|
||||||
|
#elif ARCH(AARCH64)
|
||||||
|
(void)entry_data;
|
||||||
|
TODO_AARCH64();
|
||||||
#else
|
#else
|
||||||
# error Unknown architecture
|
# error Unknown architecture
|
||||||
#endif
|
#endif
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue