mirror of
https://github.com/LadybirdBrowser/ladybird.git
synced 2024-11-25 00:50:22 +00:00
Kernel: Move ScopedCritical.cpp to Kernel base directory
This file does not contain any architecture specific implementations, so we can move it to the Kernel base directory. Also update the relevant include paths.
This commit is contained in:
parent
496a3cdcd3
commit
b18a7297c5
Notes:
sideshowbarker
2024-07-17 02:29:11 +09:00
Author: https://github.com/FireFox317 Commit: https://github.com/SerenityOS/serenity/commit/b18a7297c5 Pull-request: https://github.com/SerenityOS/serenity/pull/16690 Reviewed-by: https://github.com/ADKaster ✅ Reviewed-by: https://github.com/nico ✅
9 changed files with 7 additions and 45 deletions
|
@ -11,8 +11,8 @@
|
|||
#include <AK/Noncopyable.h>
|
||||
#ifdef KERNEL
|
||||
# include <Kernel/Arch/Processor.h>
|
||||
# include <Kernel/Arch/ScopedCritical.h>
|
||||
# include <Kernel/Locking/SpinlockProtected.h>
|
||||
# include <Kernel/ScopedCritical.h>
|
||||
#elif defined(AK_OS_WINDOWS)
|
||||
// Forward declare to avoid pulling Windows.h into every file in existence.
|
||||
extern "C" __declspec(dllimport) void __stdcall Sleep(unsigned long);
|
||||
|
|
|
@ -1,37 +0,0 @@
|
|||
/*
|
||||
* Copyright (c) 2018-2021, Andreas Kling <kling@serenityos.org>
|
||||
*
|
||||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <Kernel/Arch/ScopedCritical.h>
|
||||
|
||||
#include <Kernel/Arch/Processor.h>
|
||||
|
||||
namespace Kernel {
|
||||
|
||||
ScopedCritical::ScopedCritical() = default;
|
||||
ScopedCritical::~ScopedCritical() = default;
|
||||
|
||||
ScopedCritical::ScopedCritical(ScopedCritical&& /*from*/)
|
||||
{
|
||||
TODO_AARCH64();
|
||||
}
|
||||
|
||||
ScopedCritical& ScopedCritical::operator=(ScopedCritical&& /*from*/)
|
||||
{
|
||||
TODO_AARCH64();
|
||||
return *this;
|
||||
}
|
||||
|
||||
void ScopedCritical::leave()
|
||||
{
|
||||
TODO_AARCH64();
|
||||
}
|
||||
|
||||
void ScopedCritical::enter()
|
||||
{
|
||||
TODO_AARCH64();
|
||||
}
|
||||
|
||||
}
|
|
@ -24,11 +24,11 @@
|
|||
#include <Kernel/Arch/Interrupts.h>
|
||||
#include <Kernel/Arch/Processor.h>
|
||||
#include <Kernel/Arch/SafeMem.h>
|
||||
#include <Kernel/Arch/ScopedCritical.h>
|
||||
#include <Kernel/Arch/TrapFrame.h>
|
||||
#include <Kernel/Arch/x86_64/CPUID.h>
|
||||
#include <Kernel/Arch/x86_64/MSR.h>
|
||||
#include <Kernel/Arch/x86_64/ProcessorInfo.h>
|
||||
#include <Kernel/ScopedCritical.h>
|
||||
|
||||
#include <Kernel/Memory/PageDirectory.h>
|
||||
#include <Kernel/Memory/ScopedAddressSpaceSwitcher.h>
|
||||
|
|
|
@ -260,6 +260,7 @@ set(KERNEL_SOURCES
|
|||
ProcessProcFSTraits.cpp
|
||||
Random.cpp
|
||||
Scheduler.cpp
|
||||
ScopedCritical.cpp
|
||||
StdLib.cpp
|
||||
Syscalls/anon_create.cpp
|
||||
Syscalls/alarm.cpp
|
||||
|
@ -390,7 +391,6 @@ if ("${SERENITY_ARCH}" STREQUAL "x86_64")
|
|||
Arch/x86_64/VGA/IOArbiter.cpp
|
||||
|
||||
Arch/x86_64/RTC.cpp
|
||||
Arch/x86_64/ScopedCritical.cpp
|
||||
Arch/x86_64/Shutdown.cpp
|
||||
Arch/x86_64/SmapDisabler.cpp
|
||||
|
||||
|
@ -466,7 +466,6 @@ elseif("${SERENITY_ARCH}" STREQUAL "aarch64")
|
|||
Arch/aarch64/Panic.cpp
|
||||
Arch/aarch64/Processor.cpp
|
||||
Arch/aarch64/SafeMem.cpp
|
||||
Arch/aarch64/ScopedCritical.cpp
|
||||
Arch/aarch64/SmapDisabler.cpp
|
||||
Arch/aarch64/vector_table.S
|
||||
)
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
#include <Kernel/Library/NonnullLockRefPtr.h>
|
||||
#ifdef KERNEL
|
||||
# include <Kernel/Arch/Processor.h>
|
||||
# include <Kernel/Arch/ScopedCritical.h>
|
||||
# include <Kernel/ScopedCritical.h>
|
||||
#endif
|
||||
|
||||
#define LOCKREFPTR_SCRUB_BYTE 0xa0
|
||||
|
|
|
@ -11,8 +11,8 @@
|
|||
#include <AK/AtomicRefCounted.h>
|
||||
#include <AK/StdLibExtras.h>
|
||||
#include <Kernel/Arch/Processor.h>
|
||||
#include <Kernel/Arch/ScopedCritical.h>
|
||||
#include <Kernel/Library/LockRefPtr.h>
|
||||
#include <Kernel/ScopedCritical.h>
|
||||
|
||||
namespace AK {
|
||||
|
||||
|
|
|
@ -14,7 +14,7 @@
|
|||
#include <AK/Types.h>
|
||||
#ifdef KERNEL
|
||||
# include <Kernel/Arch/Processor.h>
|
||||
# include <Kernel/Arch/ScopedCritical.h>
|
||||
# include <Kernel/ScopedCritical.h>
|
||||
#endif
|
||||
|
||||
#define NONNULLLOCKREFPTR_SCRUB_BYTE 0xa1
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
* SPDX-License-Identifier: BSD-2-Clause
|
||||
*/
|
||||
|
||||
#include <Kernel/Arch/ScopedCritical.h>
|
||||
#include <Kernel/ScopedCritical.h>
|
||||
|
||||
#include <Kernel/Arch/Processor.h>
|
||||
|
Loading…
Reference in a new issue