• <ins id="pjuwb"></ins>
    <blockquote id="pjuwb"><pre id="pjuwb"></pre></blockquote>
    <noscript id="pjuwb"></noscript>
          <sup id="pjuwb"><pre id="pjuwb"></pre></sup>
            <dd id="pjuwb"></dd>
            <abbr id="pjuwb"></abbr>

            小默

            [zz]DispatchPnP

            DispatchPnP

            The DispatchPnP routine services IRPs containing the IRP_MJ_PNP I/O function code.

            DRIVER_DISPATCH DispatchPnP;

            NTSTATUS
              DispatchPnP(
                __in struct _DEVICE_OBJECT  *DeviceObject,
                __in struct _IRP  *Irp
                )
              {...}

            Parameters

            DeviceObject
            Caller-supplied pointer to a DEVICE_OBJECT structure. This is the device object for the target device, previously created by the driver's AddDevice routine.
            Irp
            Caller-supplied pointer to an IRP structure that describes the requested I/O operation.

            Return Value

            If the routine succeeds, it must return STATUS_SUCCESS. Otherwise, it must return one of the error status values defined in Ntstatus.h.

            Comments

            A driver's DispatchPnP routine should be named XxxDispatchPnP, where Xxx is a driver-specific prefix. The driver's DriverEntry routine must store the DispatchPnP routine's address in DriverObject->MajorFunction[IRP_MJ_PNP].

            Input parameters for all Dispatch routines are supplied in the IRP structure pointed to by Irp. Additional parameters are supplied in the driver's associated I/O stack location, which is described by the IO_STACK_LOCATION structure and can be obtained by calling IoGetCurrentIrpStackLocation.

            Generally, all Dispatch routines execute in an arbitrary thread context at IRQL = PASSIVE_LEVEL, but there are exceptions. For more information, see Dispatch Routines and IRQLs.

            For more information about DispatchPnP routines, see Writing Dispatch Routines. For more information about IRPs, see Handling IRPs.

            Example

            To define a DispatchPnP callback function that is named MyDispatchPnP, you must first provide a function declaration that Static Driver Verifier (SDV) and other verification tools require, as follows:

            DRIVER_DISPATCH MyDispatchPnP;

             

            Then, implement your callback function as follows:

            NTSTATUS
              MyDispatchPnP(
                __in struct _DEVICE_OBJECT  *DeviceObject,
                __in struct _IRP  *Irp
                )
              {
                  // Function body
              }

             

            The DRIVER_DISPATCH function type is defined in the Wdm.h header file. For more information about SDV requirements for function declarations, see Declaring Functions Using Function Role Types for WDM Drivers.

            Requirements

            IRQL: PASSIVE_LEVEL (see Comments section)

            Headers: Declared in Wdm.h. Include Wdm.h, Ntddk.h, or Ntifs.h.

            posted on 2009-12-29 11:20 小默 閱讀(277) 評(píng)論(0)  編輯 收藏 引用 所屬分類: Windows

            導(dǎo)航

            統(tǒng)計(jì)

            留言簿(13)

            隨筆分類(287)

            隨筆檔案(289)

            漏洞

            搜索

            積分與排名

            最新評(píng)論

            閱讀排行榜

            伊人久久大香线焦综合四虎| 精品久久久噜噜噜久久久| 亚洲αv久久久噜噜噜噜噜| 人妻无码久久精品| 久久无码精品一区二区三区| 一级做a爰片久久毛片16| 久久精品人人槡人妻人人玩AV| 精品国产乱码久久久久久1区2区| 色悠久久久久久久综合网| 狠狠色综合网站久久久久久久 | 久久久久99精品成人片欧美 | 久久精品国产91久久麻豆自制 | 韩国无遮挡三级久久| 久久综合精品国产二区无码| 精品久久久久久久无码| 91精品日韩人妻无码久久不卡 | 欧美大香线蕉线伊人久久| 无码八A片人妻少妇久久| 色青青草原桃花久久综合| 一本色道久久综合亚洲精品| 成人a毛片久久免费播放| 亚洲精品99久久久久中文字幕| 久久久久亚洲av无码专区导航| 伊人久久综合精品无码AV专区| 久久久久国产精品人妻| 国产成人无码精品久久久免费| 国产亚洲精久久久久久无码AV| 久久精品免费大片国产大片| 精品久久久久久无码中文字幕一区| 国产精品久久久福利| 伊人久久大香线焦AV综合影院| 久久综合给久久狠狠97色| 久久综合九色综合97_久久久 | 久久99热这里只频精品6| 伊人久久大香线蕉亚洲五月天| MM131亚洲国产美女久久| 九九久久精品国产| 狠狠色丁香久久婷婷综合| 久久最近最新中文字幕大全| 久久人人爽人人爽人人片av麻烦| 9久久9久久精品|