summaryrefslogtreecommitdiff
path: root/Kernel/Bus/PCI
diff options
context:
space:
mode:
authorkleines Filmröllchen <filmroellchen@serenityos.org>2022-08-18 21:46:28 +0200
committerBrian Gianforcaro <b.gianfo@gmail.com>2022-08-19 20:26:47 -0700
commit4314c25cf2a60f7692821b10a6e759d24ae1a1b6 (patch)
tree8b6e9c7a58afdca56b7ae02d324433884b8687da /Kernel/Bus/PCI
parent4809dc8ec28b8573b250a112b9a7dae4cde10e86 (diff)
downloadserenity-4314c25cf2a60f7692821b10a6e759d24ae1a1b6.zip
Kernel: Require lock rank for Spinlock construction
All users which relied on the default constructor use a None lock rank for now. This will make it easier to in the future remove LockRank and actually annotate the ranks by searching for None.
Diffstat (limited to 'Kernel/Bus/PCI')
-rw-r--r--Kernel/Bus/PCI/Access.h4
-rw-r--r--Kernel/Bus/PCI/Controller/VolumeManagementDevice.h2
2 files changed, 3 insertions, 3 deletions
diff --git a/Kernel/Bus/PCI/Access.h b/Kernel/Bus/PCI/Access.h
index fa1dc16fb2..14b0d40123 100644
--- a/Kernel/Bus/PCI/Access.h
+++ b/Kernel/Bus/PCI/Access.h
@@ -53,8 +53,8 @@ private:
Vector<Capability> get_capabilities(Address);
Optional<u8> get_capabilities_pointer(Address address);
- mutable RecursiveSpinlock m_access_lock;
- mutable Spinlock m_scan_lock;
+ mutable RecursiveSpinlock m_access_lock { LockRank::None };
+ mutable Spinlock m_scan_lock { LockRank::None };
HashMap<u32, NonnullOwnPtr<HostController>> m_host_controllers;
Vector<DeviceIdentifier> m_device_identifiers;
diff --git a/Kernel/Bus/PCI/Controller/VolumeManagementDevice.h b/Kernel/Bus/PCI/Controller/VolumeManagementDevice.h
index aa5a1e2849..a5baad70d7 100644
--- a/Kernel/Bus/PCI/Controller/VolumeManagementDevice.h
+++ b/Kernel/Bus/PCI/Controller/VolumeManagementDevice.h
@@ -29,7 +29,7 @@ private:
// Note: All read and writes must be done with a spinlock because
// Linux says that CPU might deadlock otherwise if access is not serialized.
- Spinlock m_config_lock;
+ Spinlock m_config_lock { LockRank::None };
};
}