summaryrefslogtreecommitdiffhomepage
path: root/src/libDDK/DriverKit/dev.h
diff options
context:
space:
mode:
authorAmlal El Mahrouss <amlal@nekernel.org>2026-03-01 05:48:35 +0100
committerAmlal El Mahrouss <amlal@nekernel.org>2026-03-01 05:48:35 +0100
commit38cddd5dc02f886e5cb3a0e386f0f7a1e6c8da86 (patch)
tree69b8bfc0a3fc403abf165d501e18b57e63a2405e /src/libDDK/DriverKit/dev.h
parent0871e5925e99e9a6f2d1eaf51ae82c7b4f740560 (diff)
feat: ddk!: Breaking changes, the DDK has been reworked in C++ instead.
chore: public, kernel: fixes and important patches. Signed-off-by: Amlal El Mahrouss <amlal@nekernel.org>
Diffstat (limited to 'src/libDDK/DriverKit/dev.h')
-rw-r--r--src/libDDK/DriverKit/dev.h37
1 files changed, 0 insertions, 37 deletions
diff --git a/src/libDDK/DriverKit/dev.h b/src/libDDK/DriverKit/dev.h
deleted file mode 100644
index c3c12ca4..00000000
--- a/src/libDDK/DriverKit/dev.h
+++ /dev/null
@@ -1,37 +0,0 @@
-// Copyright 2024-2025, Amlal El Mahrouss (amlal@nekernel.org)
-// Licensed under the Apache License, Version 2.0 (see LICENSE file)
-// Official repository: https://github.com/nekernel-org/nekernel
-
-#ifndef DRIVERKIT_DEV_H
-#define DRIVERKIT_DEV_H
-
-#include <DriverKit/ddk.h>
-
-struct _DDK_DEVICE;
-
-#define DDK_DEVICE_NAME_LEN (255)
-
-/// @brief Kernel Device driver.
-typedef struct _DDK_DEVICE DDK_FINAL {
- char d_name[DDK_DEVICE_NAME_LEN]; // the device name. Could be /./DEVICE_NAME/
- void* (*d_read)(void* arg, int len); // read from device.
- void (*d_write)(void* arg, int len);
- void (*d_wait)(void); // write to device.
- struct _DDK_DEVICE* (*d_open)(const char* path); // open device.
- void (*d_close)(struct _DDK_DEVICE* dev); // close device.
- void (*d_seek)(struct _DDK_DEVICE* dev, size_t off);
- size_t (*d_tell)(struct _DDK_DEVICE* dev);
-} DDK_DEVICE, *DDK_DEVICE_PTR;
-
-#define kopen kopen_dev
-#define kclose kclose_dev
-
-/// @brief Open a new device from path.
-/// @param path the device's path.
-DDK_EXTERN DDK_DEVICE_PTR kopen_dev(const char* path);
-
-/// @brief Close any device.
-/// @param device valid device.
-DDK_EXTERN BOOL kclose_dev(DDK_DEVICE_PTR device);
-
-#endif