diff options
| author | Peihsun Yeh <[email protected]> | 2018-08-14 12:16:17 -0700 |
|---|---|---|
| committer | Peihsun Yeh <[email protected]> | 2018-08-14 12:16:17 -0700 |
| commit | c6a43d3aad9a76d1ba702e4cabd394082ce4f70a (patch) | |
| tree | 09e183ac1a637631ee570db135f99f9e7942eae0 /general/SimpleMediaSource/SimpleMediaSourceDriver/Device.h | |
| parent | fd1d9958e8df60ad1e3dfb4312d4ff13e1e7ea92 (diff) | |
Added driver project, but it is not building yet
Diffstat (limited to 'general/SimpleMediaSource/SimpleMediaSourceDriver/Device.h')
| -rw-r--r-- | general/SimpleMediaSource/SimpleMediaSourceDriver/Device.h | 46 |
1 files changed, 46 insertions, 0 deletions
diff --git a/general/SimpleMediaSource/SimpleMediaSourceDriver/Device.h b/general/SimpleMediaSource/SimpleMediaSourceDriver/Device.h new file mode 100644 index 00000000..6c2da5e4 --- /dev/null +++ b/general/SimpleMediaSource/SimpleMediaSourceDriver/Device.h @@ -0,0 +1,46 @@ +/*++ + +Module Name: + + device.h + +Abstract: + + This file contains the device definitions. + +Environment: + + User-mode Driver Framework 2 + +--*/ + +#include "public.h" + +EXTERN_C_START + +// +// The device context performs the same job as +// a WDM device extension in the driver frameworks +// +typedef struct _DEVICE_CONTEXT +{ + ULONG PrivateDeviceData; // just a placeholder + +} DEVICE_CONTEXT, *PDEVICE_CONTEXT; + +// +// This macro will generate an inline function called DeviceGetContext +// which will be used to get a pointer to the device context memory +// in a type safe manner. +// +WDF_DECLARE_CONTEXT_TYPE_WITH_NAME(DEVICE_CONTEXT, DeviceGetContext) + +// +// Function to initialize the device and its callbacks +// +NTSTATUS +SimpleMediaSourceDriverCreateDevice( + _Inout_ PWDFDEVICE_INIT DeviceInit + ); + +EXTERN_C_END |
