1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-31 13:18:13 +00:00

Kernel/FileSystem: Simplify the ProcFS significantly

Since the ProcFS doesn't hold many global objects within it, the need
for a fully-structured design of backing components and a registry like
with the SysFS is no longer true.

To acommodate this, let's remove all backing store and components of the
ProcFS, so now it resembles what we had in the early days of ProcFS in
the project - a mostly-static filesystem, with very small amount of
kmalloc allocations needed.
We still use the inode index mechanism to understand the role of each
inode, but this is done in a much "static"ier way than before.
This commit is contained in:
Liav A 2023-02-20 17:51:18 +02:00 committed by Linus Groh
parent 9216caeec2
commit c56e1c5378
18 changed files with 362 additions and 952 deletions

View file

@ -363,9 +363,6 @@ ErrorOr<void> Process::attach_resources(NonnullOwnPtr<Memory::AddressSpace>&& pr
first_thread->detach();
}
auto weak_ptr = TRY(this->try_make_weak_ptr());
m_procfs_traits = TRY(ProcessProcFSTraits::try_create({}, move(weak_ptr)));
// This is not actually explicitly verified by any official documentation,
// but it's not listed anywhere as being cleared, and rsync expects it to work like this.
if (fork_parent)