mirror of
https://github.com/fergalmoran/ladybird.git
synced 2025-12-25 10:48:41 +00:00
Kernel: Get rid of *LockRefPtr in the SysFS filesystem code
To do this we also need to get rid of LockRefPtrs in the USB code as well. Most of the SysFS nodes are statically generated during boot and are not mutated afterwards. The same goes for general device code - once we generate the appropriate SysFS nodes, we almost never mutate the node pointers afterwards, making locking unnecessary.
This commit is contained in:
@@ -14,7 +14,7 @@ namespace Kernel {
|
||||
|
||||
UNMAP_AFTER_INIT void FirmwareSysFSDirectory::initialize()
|
||||
{
|
||||
auto firmware_directory = adopt_lock_ref_if_nonnull(new (nothrow) FirmwareSysFSDirectory()).release_nonnull();
|
||||
auto firmware_directory = adopt_ref_if_nonnull(new (nothrow) FirmwareSysFSDirectory()).release_nonnull();
|
||||
SysFSComponentRegistry::the().register_new_component(firmware_directory);
|
||||
firmware_directory->create_components();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user