亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關(guān)于我們
? 蟲蟲下載站

?? readme.txt

?? SCSI Miniport Interface
?? TXT
字號:
This sample program consists of two parts.  First, all the necessary
source code is provided to compile a Win32 sample program that sends
an IOCtl_SCSI_MINIPORT request with a custom ControlCode to the SCSI
miniport driver.  Second, a detailed description is provided that
explains what changes the driver writer has to make to a SCSI
miniport driver to allow it to properly recognize and handle the
corresponding IOCtl request from the Win32 sample program.

Part 1 - Win32 sample

The SCSI Miniport IOCtl sample, SMPI.C, demonstrates how a Win32
application sends a user defined IOCtl Control Code to a SCSI
miniport driver. This is a simple program that is composed of four
steps.

Step 1, a handle is obtained to the SCSI miniport driver using the
Win32 API, CreateFile.  The name of the file to be opened is
\\.\Scsi0:.  As an alternative, a drive letter can be substituted for
\\.\Scsi0: (e.g. - \\.\C:).  This will map to the appropriate SCSI
miniport driver that is responsible for C:.

Step 2, the SRB_IO_CONTROL structure is filled out.  The following
items must be completed :

     HeaderLength - must be the size of an SRB_IO_CONTROL structure
     ControlCode - while strictly optional, this entry should be
              considered mandatory.  The ControlCode value is used to
              further sub-divide IOCTL_SCSI_MINIPORT requests.  The
              contents of ControlCode are defined by the SCSI miniport
              driver writer.
     Length - the size of the data buffer immediately following the
              SRB_IO_CONTROL structure.  If no additional data buffer
              is used, then this must be set to 0.

The following items of the SRB_IO_CONTROL structure are optional :

     Signature - these 8 bytes are available to help prevent IOCtl
              conflicts between various vendors
     Timeout - indicates the minimum time in seconds before the
              request has timed out.  There is no maximum Timeout for
              IOCTL_SCSI_MINIPORT.  Note, for IOCTL_SCSI_PASS_THROUGH,
              the maximum time out value is 108000 seconds (30 minutes).
     ReturnCode - this entry is filled in by the SCSI miniport to
              inform the Win32 application of the results of the
              requested action.  The contents of ReturnCode are defined
              by the SCSI miniport Driver writer.

In the SMPI.C sample, two customer defined ControlCodes are used,
SMP_RETURN_3F and SMP_PRINT_STRING.  The first requires
no additional data buffer.  The second requires that a contiguous
data buffer be appended at the end of the SRB_IO_CONTROL structure. 
The ControlCodes are defined by the SCSI miniport driver (see below).

Step 3, send the SRB_IO_CONTROL structure to the SCSI miniport driver
via the DeviceIoControl Win32 API.  The dwIoControlCode must be
IOCTL_SCSI_MINIPORT.  This particular dwIoControlCode is not
currently defined in any of the Win32 SDK header files and must be
defined in your own personal header file.  It is defined in the
Windows NT DDK header file, NTDDSCSI.H.  Including a Windows NT
DDK header file in a Win32 source file has been avoided strictly to
demonstrate the ability to write a Win32 application that accesses a
device driver without having the Windows NT DDK.

Step 4, close the handle to the SCSI miniport driver.

In SMPI.C, steps 2 and 3 are repeated to demonstrate the two
ControlCodes, SMP_RETURN_3F and SMP_PRINT_STRING.  The
first requires no extra data buffer and so 'length' is set to 0.  The
second does require additional buffer space.  The value of 100 is
used as it makes the buffer large enough to handle up to 100 bytes of
data returned by the SCSI miniport driver.

When strings are manipulated via the _memXXX functions, the
terminating null is not used.  When using strXXX commands, the
terminating null is used.  strlen does not include the terminating
null in it's total.

Part 2 - SCSI Miniport Driver

The SCSI miniport driver writer is free to define the ControlCode to
any value.  Microsoft has provided a template for defining such
values and the driver writer can use this template for determining
their ControlCode values, but are not obligated to do so.  In this
sample, SMP_RETURN_3F was defined using the template and
SMP_PRINT_STRING was defined with a random number.

If the microsoft template is to be used, then the Windows NT DDK
header file, DEVIOCTL.H, should be consulted before defining a new
IOCtl.  Also, the "Kernel-mode Driver Design Guide" contains
additional information on page B-12.  There are two documentation
errors on this page. First, the bit pattern should be :

      bit(s)     purpose
      ------     -------
      0,1        Transfer type
      2-12       Function Code
      13         Customer bit
      14,15      Required Access
      16-30      Device type
      31         Common bit

The second documentation error states that the Function Code values
can be 0x00 to 0x7F for Microsoft defined IOCtls and 0x80 to 0xFF for
user defined IOCtls.  This should be 0x000 to 0x7FF for Microsoft
defined IOCtls and 0x800 to 0xFFF for user defined IOCtls.  The
Function Code field defines the function and the Customer bit
determines whether the function is defined by Microsoft or a
customer.

The following should be added to the SCSI minport driver's header
file :

//
// IOCtl definitions
//

//
// Define the various device type values.  Note that values used by Microsoft
// Corporation are in the range 0x0000 - 0x7FFF, and 0x8000 - 0xFFFF are
// reserved for use by customers.
//

#define IOCTL_SCSI_MINIPORT_IO_CONTROL  0x8001

//
// Macro definition for defining IOCTL and FSCTL function control codes.
// Note that function codes 0x000 - 0x7FF are reserved for Microsoft
// Corporation, and 0x800 - 0xFFF are reserved for customers.
//

#define RETURNCODE0x0000003F   0x850

#define SMP_RETURN_3F     CTL_CODE(IOCTL_SCSI_MINIPORT_IO_CONTROL, RETURNCODE0x0000003F, METHOD_BUFFERED, FILE_ANY_ACCESS)
#define SMP_PRINT_STRING  0x80000001

PCHAR Signature="MyDrvr";
PCHAR DrvrString="This string was placed in the data area by the SCSI miniport driver\n";

typedef struct {
    SRB_IO_CONTROL sic;
    UCHAR          ucDataBuffer[512];
} SRB_BUFFER, *PSRB_BUFFER;

The following should be added to the SCSI miniport driver's source
code :

#include <miniport.h>
#include <devioctl.h>
#include <ntddscsi.h>
#include "mydriver.h"

and the following should be added to the SCSI miniport driver's
StartIo routine :

case SRB_FUNCTION_IO_CONTROL:

    if (!memcmp(((PSRB_IO_CONTROL)(Srb->DataBuffer))->Signature,Signature,strlen(Signature))) {

        DebugPrint((1,"MyDriverStartIo: MiniportIOCtl not supported\n"));

        Srb->SrbStatus = SRB_STATUS_INVALID_REQUEST;

        ScsiPortNotification(RequestComplete,
                             CardPtr,
                             Srb);
        break;
        }


    DebugPrint((1,"MyDriverStartIo: Miniport IOCtl received\n"));

    DebugPrint((3,"MyDriverStartIo: Srb->DataBuffer->ControlCode = %Xh\n",
                    ((PSRB_IO_CONTROL)(Srb->DataBuffer))->ControlCode));

    switch (((PSRB_IO_CONTROL)(Srb->DataBuffer))->ControlCode) {

        case SMP_RETURN_3F :

           Srb->SrbStatus = SRB_STATUS_SUCCESS;

           ((PSRB_IO_CONTROL)(Srb->DataBuffer))->ReturnCode =
              (ULONG) 0x0000003FL;

           ScsiPortNotification(RequestComplete,
                                CardPtr,
                                Srb);
           break;

        case SMP_PRINT_STRING :

           Srb->SrbStatus = SRB_STATUS_SUCCESS;

           DebugPrint((0,"%s",((PSRB_BUFFER)(Srb->DataBuffer))->ucDataBuffer));

           strcpy(((PSRB_BUFFER)(Srb->DataBuffer))->ucDataBuffer,DrvrString);

           ScsiPortNotification(RequestComplete,
                                CardPtr,
                                Srb);
           break;

        default :

           DebugPrint((1,"MyDriverStartIo: MiniportIOCtl not supported\n"));

           Srb->SrbStatus = SRB_STATUS_INVALID_REQUEST;

           ScsiPortNotification(RequestComplete,
                                CardPtr,
                                Srb);
           break;

    } // end switch

    break;


?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
午夜视频久久久久久| 精品国产伦理网| 欧美一级爆毛片| 精品99久久久久久| 欧美国产欧美综合| 一区二区免费视频| 免费成人美女在线观看.| 国产精品小仙女| 色网站国产精品| 欧美精品自拍偷拍动漫精品| 日本成人在线一区| 国产另类ts人妖一区二区| www.欧美.com| 欧美一区二区三区成人| 国产午夜精品一区二区| 一个色妞综合视频在线观看| 久久国产乱子精品免费女| 波多野结衣在线一区| 欧美精品免费视频| 久久精品无码一区二区三区| 亚洲综合一区二区三区| 精品一区二区三区影院在线午夜| 99re成人精品视频| 日韩精品一区二区三区四区| 亚洲人123区| 久久精品国产99国产精品| 99精品1区2区| 精品国产乱码久久久久久蜜臀| 亚洲精品日韩一| 国产又黄又大久久| 欧美日韩精品欧美日韩精品一综合 | 国产精品久久久久aaaa樱花 | 成人精品一区二区三区中文字幕| 欧美亚洲一区二区三区四区| 国产午夜精品福利| 婷婷国产v国产偷v亚洲高清| 成人av网站在线| 日韩免费视频线观看| 亚洲免费av网站| 国产成人免费9x9x人网站视频| 欧美日韩久久久一区| 国产一区二区视频在线| 欧美日韩在线免费视频| 国产欧美日韩卡一| 麻豆一区二区三区| 91黄色激情网站| 国产精品日韩成人| 国模无码大尺度一区二区三区| 欧美人牲a欧美精品| 亚洲人xxxx| 波多野结衣中文字幕一区二区三区| 精品国产乱码久久久久久免费 | 粉嫩在线一区二区三区视频| 日韩欧美一级特黄在线播放| 亚洲成在人线免费| 色噜噜狠狠一区二区三区果冻| 国产欧美日韩精品a在线观看| 麻豆国产精品一区二区三区| 欧美日韩国产另类一区| 一区二区成人在线| 91影院在线免费观看| 国产精品网站一区| 国产精品一色哟哟哟| 精品乱人伦一区二区三区| 日本不卡123| 欧美精品xxxxbbbb| 亚瑟在线精品视频| 欧美色成人综合| 亚洲国产综合视频在线观看| 国产精品理伦片| 成人午夜激情视频| 国产调教视频一区| 国产精品亚洲综合一区在线观看| 欧美sm美女调教| 国产在线不卡一区| 久久这里只有精品6| 精品一区二区免费在线观看| 精品久久国产老人久久综合| 麻豆高清免费国产一区| 欧美一区二区三区日韩| 奇米影视在线99精品| 日韩欧美三级在线| 久久疯狂做爰流白浆xx| 精品久久久久久久久久久久久久久| 捆绑紧缚一区二区三区视频| 精品盗摄一区二区三区| 国产一区不卡在线| 久久久久国产精品麻豆ai换脸| 国产激情一区二区三区四区| 一区二区三区小说| 亚洲日本在线视频观看| 成人h动漫精品| 亚洲六月丁香色婷婷综合久久| 国产成都精品91一区二区三| 国产精品丝袜一区| www.欧美日韩国产在线| 欧美电视剧在线看免费| 蜜桃视频在线观看一区二区| 久久日韩粉嫩一区二区三区| 丰满放荡岳乱妇91ww| 亚洲色图一区二区| 欧美第一区第二区| 成人av免费在线播放| 日本午夜精品视频在线观看 | av在线免费不卡| 午夜精品福利一区二区蜜股av | 欧美在线制服丝袜| 精品伊人久久久久7777人| 亚洲欧美经典视频| 久久先锋影音av鲁色资源网| 欧美色窝79yyyycom| 国产aⅴ综合色| 丝袜亚洲另类丝袜在线| 一区二区中文字幕在线| 日韩欧美视频在线| 欧美无砖专区一中文字| 成人手机在线视频| 久久电影网站中文字幕| 亚洲一区二区三区四区在线| 精品成人一区二区| 欧美人妇做爰xxxⅹ性高电影| 成人黄页毛片网站| 久久精品免费看| 亚洲成在人线免费| 亚洲婷婷国产精品电影人久久| 精品国产一区a| 欧美三片在线视频观看| 99久久精品国产一区| 国产精品18久久久久久久网站| 日韩电影免费在线看| 亚洲精品自拍动漫在线| 亚洲国产精品成人综合色在线婷婷| 日韩欧美aaaaaa| 欧美日韩免费一区二区三区| 91免费国产视频网站| 高清不卡在线观看av| 狠狠色丁香婷婷综合久久片| 天天色天天操综合| 亚洲综合丁香婷婷六月香| 国产精品福利在线播放| 国产亚洲精品资源在线26u| 日韩欧美一级特黄在线播放| 5858s免费视频成人| 欧美偷拍一区二区| 一本久久精品一区二区| 成人黄色片在线观看| 国产一区二区三区| 国产综合色在线| 另类人妖一区二区av| 日av在线不卡| 日韩成人一区二区| 日韩黄色在线观看| 亚洲第一二三四区| 一区二区三区成人在线视频| 亚洲人成亚洲人成在线观看图片| 国产精品网站导航| 国产精品视频在线看| 中文在线资源观看网站视频免费不卡 | 精品免费视频一区二区| 91精品国产综合久久香蕉麻豆| 91成人网在线| 日本韩国精品在线| 欧美亚洲丝袜传媒另类| 欧美视频在线观看一区| 欧美色图激情小说| 欧美日韩一区二区电影| 欧美日韩国产123区| 欧美三级电影网| 欧美精品123区| 91精品国产91综合久久蜜臀| 日韩一区二区在线观看视频 | 成人免费高清视频| 白白色 亚洲乱淫| 色综合久久九月婷婷色综合| 色噜噜久久综合| 欧美区在线观看| 欧美一级国产精品| 精品国产百合女同互慰| 久久蜜桃av一区精品变态类天堂 | 日韩午夜中文字幕| 精品国产免费视频| 日本一区二区免费在线观看视频 | 欧美日韩一区国产| 制服.丝袜.亚洲.另类.中文| 日韩情涩欧美日韩视频| 久久久久久久电影| 1024亚洲合集| 亚洲一区二区三区中文字幕在线| 午夜精品久久久久久久99水蜜桃 | 亚洲一区在线看| 日韩主播视频在线| 国产麻豆精品一区二区| 国产成人精品亚洲777人妖| 99精品欧美一区二区蜜桃免费 | 国产高清亚洲一区| 99精品一区二区| 51精品秘密在线观看| 久久久激情视频| 亚洲免费观看在线观看| 日韩成人一区二区|