implement proper IRQL, DPCs, kernel and user APCs, alertable waits, async file I/O with cancellation, trap frames, selftests, a real driver/device model, native async FAT32, VFAT dotfile fixes, syscall ABI cleanup, async_apc and async_cancel tests, POSIX multi-volume paths, and pimp the readme.
This commit is contained in:
1 parent
f5fd7bdd75
commit
529f816166
75 files changed
+9969
-5675
No files matched your search
+35
-34
@@ -1,34 +1,35 @@
|
||||
#pragma once
|
||||
// ob_object.h - executive object model
|
||||
// Every resource the kernel tracks is a typed, reference-counted OBJECT.
|
||||
// The OBJECT header must be the first member of any derived struct.
|
||||
#include <stdint.h>
|
||||
#include <stddef.h>
|
||||
#include <ke_status.h>
|
||||
|
||||
typedef enum OBJECT_TYPE {
|
||||
ObjectTypeProcess = 1,
|
||||
ObjectTypeThread = 2,
|
||||
ObjectTypeMutex = 3,
|
||||
ObjectTypeSemaphore = 4,
|
||||
ObjectTypeEvent = 5,
|
||||
ObjectTypeQueue = 6,
|
||||
ObjectTypeFile = 7,
|
||||
ObjectTypeDir = 8,
|
||||
} OBJECT_TYPE;
|
||||
|
||||
typedef struct OBJECT {
|
||||
OBJECT_TYPE Type;
|
||||
volatile long RefCount; // interlocked
|
||||
void (*Destroy)(struct OBJECT* self);
|
||||
} OBJECT;
|
||||
|
||||
// Increment the reference count. Call whenever ownership is shared.
|
||||
void ObReferenceObject(OBJECT* object);
|
||||
|
||||
// Decrement. Calls Destroy() and frees the object when count reaches zero.
|
||||
void ObDereferenceObject(OBJECT* object);
|
||||
|
||||
// Allocate a zeroed object of the given size from kernel pool.
|
||||
// Caller must fill Type and Destroy before publishing the pointer.
|
||||
OBJECT* ObAllocateObject(OBJECT_TYPE type, size_t size);
|
||||
#pragma once
|
||||
// ob_object.h - executive object model
|
||||
// Every resource the kernel tracks is a typed, reference-counted OBJECT.
|
||||
// The OBJECT header must be the first member of any derived struct.
|
||||
#include <stdint.h>
|
||||
#include <stddef.h>
|
||||
#include <ke_status.h>
|
||||
|
||||
typedef enum OBJECT_TYPE {
|
||||
ObjectTypeProcess = 1,
|
||||
ObjectTypeThread = 2,
|
||||
ObjectTypeMutex = 3,
|
||||
ObjectTypeSemaphore = 4,
|
||||
ObjectTypeEvent = 5,
|
||||
ObjectTypeQueue = 6,
|
||||
ObjectTypeFile = 7,
|
||||
ObjectTypeDir = 8,
|
||||
ObjectTypeAsyncIo = 9,
|
||||
} OBJECT_TYPE;
|
||||
|
||||
typedef struct OBJECT {
|
||||
OBJECT_TYPE Type;
|
||||
volatile long RefCount; // interlocked
|
||||
void (*Destroy)(struct OBJECT* self);
|
||||
} OBJECT;
|
||||
|
||||
// Increment the reference count. Call whenever ownership is shared.
|
||||
void ObReferenceObject(OBJECT* object);
|
||||
|
||||
// Decrement. Calls Destroy() and frees the object when count reaches zero.
|
||||
void ObDereferenceObject(OBJECT* object);
|
||||
|
||||
// Allocate a zeroed object of the given size from kernel pool.
|
||||
// Caller must fill Type and Destroy before publishing the pointer.
|
||||
OBJECT* ObAllocateObject(OBJECT_TYPE type, size_t size);
|
||||
Reference in new issue
Block a user