mirror of
https://github.com/RGBCube/serenity
synced 2025-05-21 15:05:07 +00:00
Kernel: Add Syscalls/execve.cpp to aarch64 build
This commit is contained in:
parent
1fbf562e7e
commit
b941bd55d9
3 changed files with 13 additions and 7 deletions
|
@ -16,11 +16,6 @@ namespace Kernel {
|
||||||
|
|
||||||
ProcessID g_init_pid { 0 };
|
ProcessID g_init_pid { 0 };
|
||||||
|
|
||||||
ErrorOr<void> Process::exec(NonnullOwnPtr<KString>, NonnullOwnPtrVector<KString>, NonnullOwnPtrVector<KString>, Thread*&, u32&, int)
|
|
||||||
{
|
|
||||||
TODO_AARCH64();
|
|
||||||
}
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// Delay.cpp
|
// Delay.cpp
|
||||||
|
|
|
@ -272,6 +272,7 @@ set(KERNEL_SOURCES
|
||||||
Syscalls/disown.cpp
|
Syscalls/disown.cpp
|
||||||
Syscalls/dup2.cpp
|
Syscalls/dup2.cpp
|
||||||
Syscalls/emuctl.cpp
|
Syscalls/emuctl.cpp
|
||||||
|
Syscalls/execve.cpp
|
||||||
Syscalls/exit.cpp
|
Syscalls/exit.cpp
|
||||||
Syscalls/faccessat.cpp
|
Syscalls/faccessat.cpp
|
||||||
Syscalls/fallocate.cpp
|
Syscalls/fallocate.cpp
|
||||||
|
@ -402,7 +403,6 @@ if ("${SERENITY_ARCH}" STREQUAL "x86_64")
|
||||||
kprintf.cpp
|
kprintf.cpp
|
||||||
Panic.cpp
|
Panic.cpp
|
||||||
Syscall.cpp
|
Syscall.cpp
|
||||||
Syscalls/execve.cpp
|
|
||||||
)
|
)
|
||||||
|
|
||||||
set(KERNEL_SOURCES
|
set(KERNEL_SOURCES
|
||||||
|
|
|
@ -7,6 +7,7 @@
|
||||||
|
|
||||||
#include <AK/ScopeGuard.h>
|
#include <AK/ScopeGuard.h>
|
||||||
#include <AK/TemporaryChange.h>
|
#include <AK/TemporaryChange.h>
|
||||||
|
#include <Kernel/Arch/CPU.h>
|
||||||
#include <Kernel/Debug.h>
|
#include <Kernel/Debug.h>
|
||||||
#include <Kernel/FileSystem/Custody.h>
|
#include <Kernel/FileSystem/Custody.h>
|
||||||
#include <Kernel/FileSystem/OpenFileDescription.h>
|
#include <Kernel/FileSystem/OpenFileDescription.h>
|
||||||
|
@ -152,6 +153,10 @@ static ErrorOr<FlatPtr> make_userspace_context_for_main_thread([[maybe_unused]]
|
||||||
regs.rdi = argv_entries.size();
|
regs.rdi = argv_entries.size();
|
||||||
regs.rsi = argv;
|
regs.rsi = argv;
|
||||||
regs.rdx = envp;
|
regs.rdx = envp;
|
||||||
|
#elif ARCH(AARCH64)
|
||||||
|
regs.x[0] = argv_entries.size();
|
||||||
|
regs.x[1] = argv;
|
||||||
|
regs.x[2] = envp;
|
||||||
#else
|
#else
|
||||||
# error Unknown architecture
|
# error Unknown architecture
|
||||||
#endif
|
#endif
|
||||||
|
@ -717,8 +722,14 @@ static Array<ELF::AuxiliaryValue, auxiliary_vector_size> generate_auxiliary_vect
|
||||||
{ ELF::AuxiliaryValue::EGid, (long)egid.value() },
|
{ ELF::AuxiliaryValue::EGid, (long)egid.value() },
|
||||||
|
|
||||||
{ ELF::AuxiliaryValue::Platform, Processor::platform_string() },
|
{ ELF::AuxiliaryValue::Platform, Processor::platform_string() },
|
||||||
// FIXME: This is platform specific
|
// FIXME: This is platform specific
|
||||||
|
#if ARCH(X86_64)
|
||||||
{ ELF::AuxiliaryValue::HwCap, (long)CPUID(1).edx() },
|
{ ELF::AuxiliaryValue::HwCap, (long)CPUID(1).edx() },
|
||||||
|
#elif ARCH(AARCH64)
|
||||||
|
{ ELF::AuxiliaryValue::HwCap, (long)0 },
|
||||||
|
#else
|
||||||
|
# error "Unknown architecture"
|
||||||
|
#endif
|
||||||
|
|
||||||
{ ELF::AuxiliaryValue::ClockTick, (long)TimeManagement::the().ticks_per_second() },
|
{ ELF::AuxiliaryValue::ClockTick, (long)TimeManagement::the().ticks_per_second() },
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue