ladybird/Kernel/ThreadTracer.cpp
James Mintram dfe4810c3a Kernel: Add cross platform RegisterState header and Aarch64 version
A new RegisterState header includes the platform specific RegisterState
header based on the platform being compiled.

The Aarch64 RegisterState header contains stubs for Debug
2021-10-15 21:48:45 +01:00

25 lines
457 B
C++

/*
* Copyright (c) 2018-2020, Andreas Kling <kling@serenityos.org>
*
* SPDX-License-Identifier: BSD-2-Clause
*/
#include <Kernel/Arch/RegisterState.h>
#include <Kernel/ThreadTracer.h>
namespace Kernel {
ThreadTracer::ThreadTracer(ProcessID tracer_pid)
: m_tracer_pid(tracer_pid)
{
}
void ThreadTracer::set_regs(const RegisterState& regs)
{
PtraceRegisters r {};
copy_kernel_registers_into_ptrace_registers(r, regs);
m_regs = r;
}
}