1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 19:37:35 +00:00

Kernel: Remove some unused code in the SharedBuffer class

This commit is contained in:
Andreas Kling 2021-01-16 22:41:07 +01:00
parent b818cf898e
commit 0571125dfe
2 changed files with 0 additions and 30 deletions

View file

@ -198,27 +198,4 @@ void SharedBuffer::seal()
}
}
auto SharedBuffer::set_volatile_all(bool is_volatile, bool& was_purged) -> SetVolatileError
{
was_purged = false;
auto pid = Process::current()->pid();
LOCKER(shared_buffers().lock());
for (size_t i = 0; i < m_refs.size(); ++i) {
auto& ref = m_refs[i];
if (ref.pid == pid) {
if (Region* region = ref.region.unsafe_ptr()) {
switch (region->set_volatile(region->vaddr(), region->size(), is_volatile, was_purged)) {
case Region::SetVolatileError::Success:
return SetVolatileError::Success;
case Region::SetVolatileError::NotPurgeable:
return SetVolatileError::NotPurgeable;
case Region::SetVolatileError::OutOfMemory:
return SetVolatileError::OutOfMemory;
}
}
}
}
return SetVolatileError::NotMapped;
}
}