summaryrefslogtreecommitdiffhomepage
path: root/dev/ZBAKit/BootKit/Device.h
diff options
context:
space:
mode:
Diffstat (limited to 'dev/ZBAKit/BootKit/Device.h')
-rw-r--r--dev/ZBAKit/BootKit/Device.h36
1 files changed, 36 insertions, 0 deletions
diff --git a/dev/ZBAKit/BootKit/Device.h b/dev/ZBAKit/BootKit/Device.h
new file mode 100644
index 00000000..bef56f3d
--- /dev/null
+++ b/dev/ZBAKit/BootKit/Device.h
@@ -0,0 +1,36 @@
+/* -------------------------------------------
+
+ Copyright ZKA Web Services Co.
+
+------------------------------------------- */
+
+#pragma once
+
+#include <Modules/ATA/ATA.h>
+
+using namespace Kernel;
+
+/// @brief Device type.
+class Device
+{
+public:
+ explicit Device() = default;
+ virtual ~Device() = default;
+
+ ZKA_MOVE_DEFAULT(Device);
+
+ struct Trait
+ {
+ SizeT mBase{1024};
+ SizeT mSize{1024};
+ };
+
+ virtual Trait& Leak() = 0;
+
+ virtual Device& Read(Char* Buf, const SizeT& SecCount) = 0;
+ virtual Device& Write(Char* Buf, const SizeT& SecCount) = 0;
+};
+
+typedef Device BootDevice;
+typedef Device NetworkDevice;
+typedef Device DiskDevice;