summaryrefslogtreecommitdiffhomepage
path: root/Private/KernelKit/PCI
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@el-mahrouss-logic.com>2024-03-28 13:05:28 +0100
committerAmlal El Mahrouss <amlal@el-mahrouss-logic.com>2024-03-28 13:05:28 +0100
commit84cc6ff6f43b48383248282743efc514946db641 (patch)
treefa7f9099b87e235ba122d17b6a3b39234cd39883 /Private/KernelKit/PCI
parent3d798c5fc738768493df925d1f5d72256f2dec4e (diff)
Kernel: :boom: breaking changes, Update API and the HCORE based
macros, rename HCore to NewOS. Signed-off-by: Amlal El Mahrouss <amlal@el-mahrouss-logic.com>
Diffstat (limited to 'Private/KernelKit/PCI')
-rw-r--r--Private/KernelKit/PCI/Database.hpp4
-rw-r--r--Private/KernelKit/PCI/Device.hpp8
-rw-r--r--Private/KernelKit/PCI/Dma.hpp4
-rw-r--r--Private/KernelKit/PCI/Dma.inl2
-rw-r--r--Private/KernelKit/PCI/IO-Impl-AMD64.inl4
-rw-r--r--Private/KernelKit/PCI/IO.hpp4
-rw-r--r--Private/KernelKit/PCI/Iterator.hpp4
-rw-r--r--Private/KernelKit/PCI/PCI.hpp4
8 files changed, 17 insertions, 17 deletions
diff --git a/Private/KernelKit/PCI/Database.hpp b/Private/KernelKit/PCI/Database.hpp
index 773677d6..b79f7b57 100644
--- a/Private/KernelKit/PCI/Database.hpp
+++ b/Private/KernelKit/PCI/Database.hpp
@@ -8,7 +8,7 @@
#include <KernelKit/PCI/Device.hpp>
#include <NewKit/Defines.hpp>
-namespace HCore {
+namespace NewOS {
namespace Types {
// https://wiki.osdev.org/PCI
enum class PciDeviceKind : UChar {
@@ -32,4 +32,4 @@ namespace HCore {
Invalid = Unassgined,
};
} // namespace Types
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/PCI/Device.hpp b/Private/KernelKit/PCI/Device.hpp
index 08371f12..c73ca068 100644
--- a/Private/KernelKit/PCI/Device.hpp
+++ b/Private/KernelKit/PCI/Device.hpp
@@ -7,7 +7,7 @@
#include <NewKit/Defines.hpp>
-namespace HCore::PCI
+namespace NewOS::PCI
{
enum class PciConfigKind : UShort
{
@@ -74,8 +74,8 @@ namespace HCore::PCI
UShort m_Bar;
};
-} // namespace HCore::PCI
+} // namespace NewOS::PCI
-extern "C" void LumiaPCISetCfgTarget(HCore::UInt bar);
-extern "C" HCore::UInt LumiaPCIReadRaw(HCore::UInt bar);
+extern "C" void LumiaPCISetCfgTarget(NewOS::UInt bar);
+extern "C" NewOS::UInt LumiaPCIReadRaw(NewOS::UInt bar);
diff --git a/Private/KernelKit/PCI/Dma.hpp b/Private/KernelKit/PCI/Dma.hpp
index d5df4c3d..1e1b5036 100644
--- a/Private/KernelKit/PCI/Dma.hpp
+++ b/Private/KernelKit/PCI/Dma.hpp
@@ -12,7 +12,7 @@
#include <NewKit/OwnPtr.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore {
+namespace NewOS {
enum class DmaKind {
PCI, // Bus mastering is required to be turned on. Basiaclly a request
// control system. 64-Bit access depends on the PAE bit and the device
@@ -70,6 +70,6 @@ class DMAFactory final {
public:
static OwnPtr<IOBuf<Char *>> Construct(OwnPtr<DMAWrapper> &dma);
};
-} // namespace HCore
+} // namespace NewOS
#include <KernelKit/PCI/Dma.inl>
diff --git a/Private/KernelKit/PCI/Dma.inl b/Private/KernelKit/PCI/Dma.inl
index ac0214af..5f7e1379 100644
--- a/Private/KernelKit/PCI/Dma.inl
+++ b/Private/KernelKit/PCI/Dma.inl
@@ -4,7 +4,7 @@
------------------------------------------- */
-namespace HCore
+namespace NewOS
{
template<class T>
T* DMAWrapper::operator->()
diff --git a/Private/KernelKit/PCI/IO-Impl-AMD64.inl b/Private/KernelKit/PCI/IO-Impl-AMD64.inl
index f720f2b6..195ebca1 100644
--- a/Private/KernelKit/PCI/IO-Impl-AMD64.inl
+++ b/Private/KernelKit/PCI/IO-Impl-AMD64.inl
@@ -12,7 +12,7 @@
------------------------------------------- */
-namespace HCore {
+namespace NewOS {
template <SizeT Sz>
template <typename T>
T IOArray<Sz>::In(SizeT index) {
@@ -44,4 +44,4 @@ void IOArray<Sz>::Out(SizeT index, T value) {
break;
}
}
-} // namespace HCore
+} // namespace NewOS
diff --git a/Private/KernelKit/PCI/IO.hpp b/Private/KernelKit/PCI/IO.hpp
index a58bd955..87a29b78 100644
--- a/Private/KernelKit/PCI/IO.hpp
+++ b/Private/KernelKit/PCI/IO.hpp
@@ -11,7 +11,7 @@
#include <NewKit/Defines.hpp>
#include <NewKit/Ref.hpp>
-namespace HCore {
+namespace NewOS {
template <SizeT Sz>
class IOArray final {
public:
@@ -40,7 +40,7 @@ class IOArray final {
};
using IOArray16 = IOArray<16>;
-} // namespace HCore
+} // namespace NewOS
#ifdef __x86_64__
#include <KernelKit/PCI/IO-Impl-AMD64.inl>
diff --git a/Private/KernelKit/PCI/Iterator.hpp b/Private/KernelKit/PCI/Iterator.hpp
index 89e1f246..f1069fda 100644
--- a/Private/KernelKit/PCI/Iterator.hpp
+++ b/Private/KernelKit/PCI/Iterator.hpp
@@ -11,7 +11,7 @@
#define ME_DEVICE_COUNT (33)
#define ME_FUNCTION_COUNT (8)
-namespace HCore::PCI {
+namespace NewOS::PCI {
class Iterator final {
public:
Iterator() = delete;
@@ -31,6 +31,6 @@ namespace HCore::PCI {
private:
Array<PCI::Device, ME_BUS_COUNT> m_Devices;
};
-} // namespace HCore::PCI
+} // namespace NewOS::PCI
#endif // __PCI_ITERATOR_HPP__
diff --git a/Private/KernelKit/PCI/PCI.hpp b/Private/KernelKit/PCI/PCI.hpp
index c93150b2..65e199ad 100644
--- a/Private/KernelKit/PCI/PCI.hpp
+++ b/Private/KernelKit/PCI/PCI.hpp
@@ -14,7 +14,7 @@
#define PCI_FUNC_COUNT (8)
#define PCI_BUS_COUNT (255)
-namespace HCore::PCI {
+namespace NewOS::PCI {
// model
struct DeviceHeader {
UInt16 VendorId;
@@ -50,4 +50,4 @@ namespace HCore::PCI {
Detail::BAR BAR4;
Detail::BAR BAR5;
};
-} // namespace HCore::PCI
+} // namespace NewOS::PCI