⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 kerneldll.h

📁 windows驱动程序
💻 H
字号:
//**************************************************************************************************//
//*                                                                                                *//
//* Copyright (C) 2003, James Antognini, antognini@mindspring.com.                                 *//
//*                                                                                                *//
//**************************************************************************************************//

#ifdef JADriverKernelMode                             // Begin kernel-mode-only section.
  
#if DBG
#define DbgPrint(arg) DbgPrint arg
#else
#define DbgPrint(arg)
#endif

//***************************************************************************//
//                                                                           //
// Types, definitions, etc.                                                  //
//                                                                           //
//***************************************************************************//

typedef struct _KernelDLLExt                          // Device extension.
  {
   UNICODE_STRING        JAUniSymLinkName;
   UNICODE_STRING        JAUniDeviceName;
   UNICODE_STRING        JARegPath;
   ANSI_STRING           JADriverName;
  }
   KernelDLLExt, * pKernelDLLExt;

//***************************************************************************//
//                                                                           //
// Routine prototypes.                                                       //
//                                                                           //
//***************************************************************************//

// Define the exported/imported function KernelDLLRtnsTest().

#if defined(ExportKernelDLL)                          // Exporting desired?
__declspec(dllexport)
#else                                                 // No, not desired.  Therefore, importing.
__declspec(dllimport)
#endif
NTSTATUS
KernelDLLRtnsTest(PDEVICE_OBJECT);

#endif                                                // End kernel-mode-only section.
  
#define FILE_DEVICE_KernelDLL      0x00008A00
 
#define KernelDLL_TEST  (ULONG) CTL_CODE(FILE_DEVICE_KernelDLL,    \
                                         0x01,                     \
                                         METHOD_BUFFERED,          \
                                         FILE_ANY_ACCESS           \
                                        )                          
                                                                 
typedef enum
  {
   CallKernelDLLUnknown,
   CallKernelDLLTest,
  }
   CallKernelDLLOperType;

typedef struct _KernelDLLTestStr
  {
   ULONG             rc;                              // Return code.
  }
   KernelDLLTestStr, * pKernelDLLTestStr;
  

//***************************************************************************//
//                                                                           //
// User-space routine prototypes.                                            //
//                                                                           //
//***************************************************************************//

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -