diff options
author | Andreas Kling <kling@serenityos.org> | 2021-08-22 01:49:22 +0200 |
---|---|---|
committer | Andreas Kling <kling@serenityos.org> | 2021-08-22 03:34:10 +0200 |
commit | c922a7da090d57ed36cf8526e985b82ec3f4933f (patch) | |
tree | d4791565a1149af47eae4cb4470f875e0644f18c /Kernel/Memory/VirtualRangeAllocator.cpp | |
parent | 55adace359bfda606b445b5177ce5138687d4626 (diff) | |
download | serenity-c922a7da090d57ed36cf8526e985b82ec3f4933f.zip |
Kernel: Rename ScopedSpinlock => SpinlockLocker
This matches MutexLocker, and doesn't sound like it's a lock itself.
Diffstat (limited to 'Kernel/Memory/VirtualRangeAllocator.cpp')
-rw-r--r-- | Kernel/Memory/VirtualRangeAllocator.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/Kernel/Memory/VirtualRangeAllocator.cpp b/Kernel/Memory/VirtualRangeAllocator.cpp index 351ec0cd8b..c9f1dbad29 100644 --- a/Kernel/Memory/VirtualRangeAllocator.cpp +++ b/Kernel/Memory/VirtualRangeAllocator.cpp @@ -25,7 +25,7 @@ void VirtualRangeAllocator::initialize_with_range(VirtualAddress base, size_t si void VirtualRangeAllocator::initialize_from_parent(VirtualRangeAllocator const& parent_allocator) { - ScopedSpinlock lock(parent_allocator.m_lock); + SpinlockLocker lock(parent_allocator.m_lock); m_total_range = parent_allocator.m_total_range; m_available_ranges.clear(); for (auto it = parent_allocator.m_available_ranges.begin(); !it.is_end(); ++it) { @@ -103,7 +103,7 @@ Optional<VirtualRange> VirtualRangeAllocator::allocate_anywhere(size_t size, siz if (Checked<size_t>::addition_would_overflow(effective_size, alignment)) return {}; - ScopedSpinlock lock(m_lock); + SpinlockLocker lock(m_lock); for (auto it = m_available_ranges.begin(); !it.is_end(); ++it) { auto& available_range = *it; @@ -142,7 +142,7 @@ Optional<VirtualRange> VirtualRangeAllocator::allocate_specific(VirtualAddress b return {}; } - ScopedSpinlock lock(m_lock); + SpinlockLocker lock(m_lock); for (auto it = m_available_ranges.begin(); !it.is_end(); ++it) { auto& available_range = *it; if (!available_range.contains(base, size)) @@ -159,7 +159,7 @@ Optional<VirtualRange> VirtualRangeAllocator::allocate_specific(VirtualAddress b void VirtualRangeAllocator::deallocate(VirtualRange const& range) { - ScopedSpinlock lock(m_lock); + SpinlockLocker lock(m_lock); VERIFY(m_total_range.contains(range)); VERIFY(range.size()); VERIFY((range.size() % PAGE_SIZE) == 0); |