summaryrefslogtreecommitdiff
path: root/Kernel
diff options
context:
space:
mode:
authorLiav A <liavalb@gmail.com>2022-04-22 15:51:45 +0300
committerAndreas Kling <kling@serenityos.org>2022-07-15 12:29:23 +0200
commit6ff1aeb64dd4790598b108f77abbf7e8fed163a0 (patch)
treeb0da949f5eef1cd58156326a6635eddb8228a7f8 /Kernel
parent4ad437f3a79134bf7a2c5ae13e31338be9c4a0ab (diff)
downloadserenity-6ff1aeb64dd4790598b108f77abbf7e8fed163a0.zip
Kernel/SysFS: Rename Devices code folder => DeviceIdentifiers
This folder in the SysFS code represents everything related to /sys/dev, which is a directory meant to be a convenient interface to track all IDs of all block and character devices (ID = major:minor numbers).
Diffstat (limited to 'Kernel')
-rw-r--r--Kernel/CMakeLists.txt8
-rw-r--r--Kernel/Devices/Device.h2
-rw-r--r--Kernel/FileSystem/SysFS/Registry.h2
-rw-r--r--Kernel/FileSystem/SysFS/RootDirectory.cpp6
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.cpp (renamed from Kernel/FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.cpp)6
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.h (renamed from Kernel/FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.h)6
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.cpp (renamed from Kernel/FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.cpp)6
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.h (renamed from Kernel/FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.h)6
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.cpp (renamed from Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.cpp)2
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.h (renamed from Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.h)0
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.cpp (renamed from Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.cpp)12
-rw-r--r--Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.h (renamed from Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.h)6
12 files changed, 31 insertions, 31 deletions
diff --git a/Kernel/CMakeLists.txt b/Kernel/CMakeLists.txt
index 19a58aef95..ca829adf64 100644
--- a/Kernel/CMakeLists.txt
+++ b/Kernel/CMakeLists.txt
@@ -147,10 +147,10 @@ set(KERNEL_SOURCES
FileSystem/SysFS/Subsystems/Bus/USB/BusDirectory.cpp
FileSystem/SysFS/Subsystems/Bus/USB/DeviceInformation.cpp
FileSystem/SysFS/Subsystems/Bus/Directory.cpp
- FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.cpp
- FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.cpp
- FileSystem/SysFS/Subsystems/Devices/DeviceComponent.cpp
- FileSystem/SysFS/Subsystems/Devices/Directory.cpp
+ FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.cpp
+ FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.cpp
+ FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.cpp
+ FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.cpp
FileSystem/SysFS/Subsystems/Firmware/BIOS/Component.cpp
FileSystem/SysFS/Subsystems/Firmware/BIOS/Directory.cpp
FileSystem/SysFS/Subsystems/Firmware/Directory.cpp
diff --git a/Kernel/Devices/Device.h b/Kernel/Devices/Device.h
index 60989f934d..b6c9e53d61 100644
--- a/Kernel/Devices/Device.h
+++ b/Kernel/Devices/Device.h
@@ -23,7 +23,7 @@
#include <Kernel/FileSystem/DeviceFileTypes.h>
#include <Kernel/FileSystem/File.h>
#include <Kernel/FileSystem/SysFS/Registry.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.h>
#include <Kernel/UnixTypes.h>
namespace Kernel {
diff --git a/Kernel/FileSystem/SysFS/Registry.h b/Kernel/FileSystem/SysFS/Registry.h
index 351295d934..b888bb5eef 100644
--- a/Kernel/FileSystem/SysFS/Registry.h
+++ b/Kernel/FileSystem/SysFS/Registry.h
@@ -10,7 +10,7 @@
#include <Kernel/FileSystem/Inode.h>
#include <Kernel/FileSystem/SysFS/Component.h>
#include <Kernel/FileSystem/SysFS/RootDirectory.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.h>
#include <Kernel/Locking/MutexProtected.h>
namespace Kernel {
diff --git a/Kernel/FileSystem/SysFS/RootDirectory.cpp b/Kernel/FileSystem/SysFS/RootDirectory.cpp
index 8a5951ebf6..b844df3100 100644
--- a/Kernel/FileSystem/SysFS/RootDirectory.cpp
+++ b/Kernel/FileSystem/SysFS/RootDirectory.cpp
@@ -7,7 +7,7 @@
#include <Kernel/FileSystem/SysFS/Registry.h>
#include <Kernel/FileSystem/SysFS/RootDirectory.h>
#include <Kernel/FileSystem/SysFS/Subsystems/Bus/Directory.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.h>
#include <Kernel/Sections.h>
namespace Kernel {
@@ -33,9 +33,9 @@ ErrorOr<void> SysFSRootDirectory::traverse_as_directory(FileSystemID fsid, Funct
SysFSRootDirectory::SysFSRootDirectory()
{
auto buses_directory = SysFSBusDirectory::must_create(*this);
- auto devices_directory = SysFSDevicesDirectory::must_create(*this);
+ auto device_identifiers_directory = SysFSDeviceIdentifiersDirectory::must_create(*this);
m_components.append(buses_directory);
- m_components.append(devices_directory);
+ m_components.append(device_identifiers_directory);
m_buses_directory = buses_directory;
}
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.cpp b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.cpp
index 21a95c3ef5..6de2fc0026 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.cpp
+++ b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.cpp
@@ -5,16 +5,16 @@
*/
#include <Kernel/FileSystem/SysFS/Registry.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.h>
#include <Kernel/Sections.h>
namespace Kernel {
-NonnullRefPtr<SysFSBlockDevicesDirectory> SysFSBlockDevicesDirectory::must_create(SysFSDevicesDirectory const& devices_directory)
+NonnullRefPtr<SysFSBlockDevicesDirectory> SysFSBlockDevicesDirectory::must_create(SysFSDeviceIdentifiersDirectory const& devices_directory)
{
return adopt_ref_if_nonnull(new SysFSBlockDevicesDirectory(devices_directory)).release_nonnull();
}
-SysFSBlockDevicesDirectory::SysFSBlockDevicesDirectory(SysFSDevicesDirectory const& devices_directory)
+SysFSBlockDevicesDirectory::SysFSBlockDevicesDirectory(SysFSDeviceIdentifiersDirectory const& devices_directory)
: SysFSDirectory(devices_directory)
{
}
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.h b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.h
index 8420de42ff..7b5b0ab155 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.h
+++ b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.h
@@ -7,19 +7,19 @@
#pragma once
#include <Kernel/FileSystem/SysFS/Component.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.h>
namespace Kernel {
class SysFSBlockDevicesDirectory final : public SysFSDirectory {
public:
virtual StringView name() const override { return "block"sv; }
- static NonnullRefPtr<SysFSBlockDevicesDirectory> must_create(SysFSDevicesDirectory const&);
+ static NonnullRefPtr<SysFSBlockDevicesDirectory> must_create(SysFSDeviceIdentifiersDirectory const&);
virtual ErrorOr<void> traverse_as_directory(FileSystemID, Function<ErrorOr<void>(FileSystem::DirectoryEntryView const&)>) const override;
virtual RefPtr<SysFSComponent> lookup(StringView name) override;
private:
- explicit SysFSBlockDevicesDirectory(SysFSDevicesDirectory const&);
+ explicit SysFSBlockDevicesDirectory(SysFSDeviceIdentifiersDirectory const&);
};
}
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.cpp b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.cpp
index 3c3f65ba34..a26b6bcc42 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.cpp
+++ b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.cpp
@@ -5,16 +5,16 @@
*/
#include <Kernel/FileSystem/SysFS/Registry.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.h>
#include <Kernel/Sections.h>
namespace Kernel {
-NonnullRefPtr<SysFSCharacterDevicesDirectory> SysFSCharacterDevicesDirectory::must_create(SysFSDevicesDirectory const& devices_directory)
+NonnullRefPtr<SysFSCharacterDevicesDirectory> SysFSCharacterDevicesDirectory::must_create(SysFSDeviceIdentifiersDirectory const& devices_directory)
{
return adopt_ref_if_nonnull(new SysFSCharacterDevicesDirectory(devices_directory)).release_nonnull();
}
-SysFSCharacterDevicesDirectory::SysFSCharacterDevicesDirectory(SysFSDevicesDirectory const& devices_directory)
+SysFSCharacterDevicesDirectory::SysFSCharacterDevicesDirectory(SysFSDeviceIdentifiersDirectory const& devices_directory)
: SysFSDirectory(devices_directory)
{
}
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.h b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.h
index ccef4ff780..1249d93da0 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.h
+++ b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.h
@@ -7,19 +7,19 @@
#pragma once
#include <Kernel/FileSystem/SysFS/Component.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.h>
namespace Kernel {
class SysFSCharacterDevicesDirectory final : public SysFSDirectory {
public:
virtual StringView name() const override { return "char"sv; }
- static NonnullRefPtr<SysFSCharacterDevicesDirectory> must_create(SysFSDevicesDirectory const&);
+ static NonnullRefPtr<SysFSCharacterDevicesDirectory> must_create(SysFSDeviceIdentifiersDirectory const&);
virtual ErrorOr<void> traverse_as_directory(FileSystemID, Function<ErrorOr<void>(FileSystem::DirectoryEntryView const&)>) const override;
virtual RefPtr<SysFSComponent> lookup(StringView name) override;
private:
- explicit SysFSCharacterDevicesDirectory(SysFSDevicesDirectory const&);
+ explicit SysFSCharacterDevicesDirectory(SysFSDeviceIdentifiersDirectory const&);
};
}
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.cpp b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.cpp
index c4227117b3..05cd3b71fd 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.cpp
+++ b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.cpp
@@ -5,7 +5,7 @@
*/
#include <Kernel/Devices/Device.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.h>
#include <Kernel/Sections.h>
namespace Kernel {
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.h b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.h
index 40aaebbb3d..40aaebbb3d 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Devices/DeviceComponent.h
+++ b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/DeviceComponent.h
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.cpp b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.cpp
index d2da6abd13..893c798bb6 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.cpp
+++ b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.cpp
@@ -5,21 +5,21 @@
*/
#include <Kernel/FileSystem/SysFS/RootDirectory.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/BlockDevicesDirectory.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/CharacterDevicesDirectory.h>
-#include <Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/BlockDevicesDirectory.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/CharacterDevicesDirectory.h>
+#include <Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.h>
#include <Kernel/Sections.h>
namespace Kernel {
-UNMAP_AFTER_INIT NonnullRefPtr<SysFSDevicesDirectory> SysFSDevicesDirectory::must_create(SysFSRootDirectory const& root_directory)
+UNMAP_AFTER_INIT NonnullRefPtr<SysFSDeviceIdentifiersDirectory> SysFSDeviceIdentifiersDirectory::must_create(SysFSRootDirectory const& root_directory)
{
- auto devices_directory = adopt_ref_if_nonnull(new SysFSDevicesDirectory(root_directory)).release_nonnull();
+ auto devices_directory = adopt_ref_if_nonnull(new SysFSDeviceIdentifiersDirectory(root_directory)).release_nonnull();
devices_directory->m_components.append(SysFSBlockDevicesDirectory::must_create(*devices_directory));
devices_directory->m_components.append(SysFSCharacterDevicesDirectory::must_create(*devices_directory));
return devices_directory;
}
-SysFSDevicesDirectory::SysFSDevicesDirectory(SysFSRootDirectory const& root_directory)
+SysFSDeviceIdentifiersDirectory::SysFSDeviceIdentifiersDirectory(SysFSRootDirectory const& root_directory)
: SysFSDirectory(root_directory)
{
}
diff --git a/Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.h b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.h
index 7294e4c7e3..5b7b684ef2 100644
--- a/Kernel/FileSystem/SysFS/Subsystems/Devices/Directory.h
+++ b/Kernel/FileSystem/SysFS/Subsystems/DeviceIdentifiers/Directory.h
@@ -11,13 +11,13 @@
namespace Kernel {
-class SysFSDevicesDirectory final : public SysFSDirectory {
+class SysFSDeviceIdentifiersDirectory final : public SysFSDirectory {
public:
virtual StringView name() const override { return "dev"sv; }
- static NonnullRefPtr<SysFSDevicesDirectory> must_create(SysFSRootDirectory const&);
+ static NonnullRefPtr<SysFSDeviceIdentifiersDirectory> must_create(SysFSRootDirectory const&);
private:
- explicit SysFSDevicesDirectory(SysFSRootDirectory const&);
+ explicit SysFSDeviceIdentifiersDirectory(SysFSRootDirectory const&);
};
}