您的位置:首页 > 理论基础 > 数据结构算法

驱动开发学习笔记02:DEVICE_OBJECT对象数据结构

2011-08-08 14:07 573 查看
typedef struct DECLSPEC_ALIGN(MEMORY_ALLOCATION_ALIGNMENT) _DEVICE_OBJECT {

CSHORT Type;

USHORT Size;

LONG ReferenceCount;

struct _DRIVER_OBJECT *DriverObject;//指向驱动程序的驱动对象,同属一个驱动程序的驱动对象是指向的是统一的驱动对象

struct _DEVICE_OBJECT *NextDevice;//指向下一个驱动对象

struct _DEVICE_OBJECT *AttachedDevice;//指向下一个设备对象

struct _IRP *CurrentIrp;//使用StartIO例程,此域指向当前IRP对象

PIO_TIMER Timer;

ULONG Flags;                                // See above:  DO_...

ULONG Characteristics;                      // See ntioapi:  FILE_...

__volatile PVPB Vpb;

PVOID DeviceExtension;

DEVICE_TYPE DeviceType;

CCHAR StackSize;

union {

LIST_ENTRY ListEntry;

WAIT_CONTEXT_BLOCK Wcb;

} Queue;

ULONG AlignmentRequirement;

KDEVICE_QUEUE DeviceQueue;

KDPC Dpc;


//

//  The following field is for exclusive use by the filesystem to keep

//  track of the number of Fsp threads currently using the device

//


ULONG ActiveThreadCount;

PSECURITY_DESCRIPTOR SecurityDescriptor;

KEVENT DeviceLock;


USHORT SectorSize;

USHORT Spare1;


struct _DEVOBJ_EXTENSION  *DeviceObjectExtension;

PVOID  Reserved;


} DEVICE_OBJECT;


typedef struct _DEVICE_OBJECT *PDEVICE_OBJECT;
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: 
相关文章推荐