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

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? xunicdevice.cpp

?? WDM驅動程序實例,用DriverStudio加vc
?? CPP
?? 第 1 頁 / 共 2 頁
字號:
// XunicDevice.cpp
//
// Generated by DriverWizard 3.2.0 (Build 2485)
// Requires DDK and DriverWorks
// File created on 2/8/2006
//
// This source file contains the implementation of a subclass of KDevice.
// WDM drivers implement a subclass of KPnpDevice and override member
// functions to handle requests (IRPs) from the system.
//

#include <vdw.h>
#include "XunicDriver.h"
#include "XunicDevice.h"
#include "..\\intrface.h"

#pragma hdrstop("Xunic.pch")

// Global driver trace object
// TODO:	Use KDebugOnlyTrace if you want trace messages
//			to appear only in checked builds.  Use KTrace if
//			you want trace messages to always appear.  Call
//			method SetOutputLevel to set the output threshold.
extern KDebugOnlyTrace T;

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::XunicDevice
//		This is the constructor for the class representing the Functional
//		Device Object, or FDO.  It is derived from KPnpDevice, which builds
//		in automatic dispatching of subfunctions of IRP_MJ_POWER and IRP_MJ_PNP
//		to virtual member functions.
//		The object being constructed contains a data member (m_Lower) of type
//		KPnpLowerDevice. By initializing it, the driver binds the FDO to the
//		PDO and creates an interface to the upper edge of the system class driver.
//
//	Arguments:
//		IN	Pdo
//				Physical Device Object.  This is a pointer to a system
//				device object that represents the physical device.
//
//		IN	Unit
//				Unit number to append to the device's base device name 
//				to distinguish multiple units of this device type.
//
//	Return Value:
//		none
//
XunicDevice::XunicDevice(PDEVICE_OBJECT Pdo, ULONG Unit) :
	KPnpDevice(Pdo, &GUID_DEVINTERFACE_XUNIC)
{
	if (!NT_SUCCESS(m_ConstructorStatus))
	{
		T.Trace(TraceError, __FUNCTION__": Failed to create device XunicDevice"
			" unit number %d status %x\n", Unit, m_ConstructorStatus);
		ASSERT(FALSE);
		return;
	}

	// Initialize the lower device
	m_Lower.Initialize(this, Pdo);

	// Inform the base class of the lower edge device object
	SetLowerDevice(&m_Lower);

	// Initialize the PnP Policy settings to the "standard" policy
	SetPnpPolicy();

	// TODO: Customize the PnP Policy for this device by setting
	//		 flags in m_Policies.

	// Initialize the Power Policy settings to the "standard" policy
	SetPowerPolicy();

	// TODO: Customize the Power Policy for this device by setting
	//		 flags in m_PowerPolicies.

}

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::~XunicDevice
//		This is the destructor for the class. 
//
//	Arguments:
//		none
//
//	Return Value:
//		none
//
XunicDevice::~XunicDevice()
{
}

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::DefaultPnp
//		Default handler for IRP_MJ_PNP. 
//		This routine just passes the IRP through to the lower device. IRPs 
//		that correspond to any virtual members of KpnpDevice that handle 
//		minor functions of IRP_MJ_PNP and that are not overridden get 
//		passed to this routine.
//
//	Arguments:
//		IN	I
//			the plug and play IRP
//
//	Return Value:
//		NTSTATUS
//			Result returned from lower device
//
NTSTATUS XunicDevice::DefaultPnp(KIrp I)
{
	T.Trace(TraceInfo, __FUNCTION__"++.  IRP %p\n", I);
	T << I; 

	I.ForceReuseOfCurrentStackLocationInCalldown();
	NTSTATUS status = m_Lower.PnpCall(this, I);

	T.Trace(TraceInfo, __FUNCTION__"--.  IRP %p, STATUS %x\n", I, status);

	return status;
}

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::DefaultPower
//		Default handler for IRP_MJ_POWER. 
//		This routine just passes the IRP through to the lower device. IRPs 
//		that correspond to any virtual members of KpnpDevice that handle 
//		minor functions of IRP_MJ_POWER and that are not overridden get 
//		passed to this routine.
//
//	Arguments:
//		IN	I
//			the power IRP
//
//	Return Value:
//		NTSTATUS
//			Result returned from lower device
//
NTSTATUS XunicDevice::DefaultPower(KIrp I)
{
	T.Trace(TraceInfo, __FUNCTION__"++.  IRP %p\n", I);
	T << I; 

	I.IndicatePowerIrpProcessed();
	I.CopyParametersDown();
	NTSTATUS status = m_Lower.PnpPowerCall(this, I);

	T.Trace(TraceInfo, __FUNCTION__"--.  IRP %p, STATUS %x\n", I, status);

	return status;
}

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::SystemControl
//		Default handler for IRP_MJ_SYSTEM_CONTROL. 
//		This routine just passes the IRP through to the next device since 
//		this driver is not a WMI provider.
//
//	Arguments:
//		IN	I
//			the system control (WMI) IRP
//
//	Return Value:
//		NTSTATUS
//			Result returned from lower device
//
NTSTATUS XunicDevice::SystemControl(KIrp I)
{
	T.Trace(TraceInfo, __FUNCTION__"++.  IRP %p\n", I);
	T << I; 

	NTSTATUS status = STATUS_SUCCESS;

	I.ForceReuseOfCurrentStackLocationInCalldown();
	status = m_Lower.PnpCall(this, I);

	T.Trace(TraceInfo, __FUNCTION__"--.  IRP %p, STATUS %x\n", I, status);

	return status;
}

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::OnStartDevice
//		Handler for IRP_MJ_PNP subfcn IRP_MN_START_DEVICE. 
//		Initialize the hardware device. Typically, the driver initializes
//		physical resources here.  Call I.AllocatedResources() for a list
//		of the raw resources that the system has assigned to the device,
//		or I.TranslatedResources() for the translated resource list.
//
//	Arguments:
//		IN	I
//			the start device IRP
//
//	Return Value:
//		NTSTATUS
//
NTSTATUS XunicDevice::OnStartDevice(KIrp I)
{
	T.Trace(TraceInfo, __FUNCTION__"++.  IRP %p\n", I);

	NTSTATUS status = STATUS_SUCCESS;

	I.Information() = 0;

	// Get the list of raw resources from the IRP
	PCM_RESOURCE_LIST pResListRaw = I.AllocatedResources();
	// Get the list of translated resources from the IRP
	PCM_RESOURCE_LIST pResListTranslated = I.TranslatedResources();

	// TODO: Add device-specific code to initialize/start your hardware device.
    // The base class will handle completion of the IRP

	T.Trace(TraceInfo, __FUNCTION__"--.  IRP %p, STATUS %x\n", I, status);

	return status;
}

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::OnStopDevice
//		Handler for IRP_MJ_PNP subfcn IRP_MN_STOP_DEVICE. 
//		The system calls this when the device is stopped.  Release any 
//		hardware resources in this routine.
//
//	Arguments:
//		IN	I
//			the stop device IRP
//
//	Return Value:
//		NTSTATUS
//
NTSTATUS XunicDevice::OnStopDevice(KIrp I)
{
	T.Trace(TraceInfo, __FUNCTION__"++.  IRP %p\n", I);

	NTSTATUS status = STATUS_SUCCESS;

	// TODO: Add device-specific code to stop your hardware device.
    // The base class will handle completion of the IRP

	// Release the system resources
	Invalidate();

	T.Trace(TraceInfo, __FUNCTION__"--.  IRP %p, STATUS %x\n", I, STATUS_SUCCESS);

	// Can't fail this IRP
	return STATUS_SUCCESS;
}

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::OnRemoveDevice
//		Handler for IRP_MJ_PNP subfcn IRP_MN_REMOVE_DEVICE. 
//		The system calls this when the device is removed.
//		Our PnP policy will take care of 
//			(1) giving the IRP to the lower device
//			(2) detaching the PDO
//			(3) deleting the device object
//
//	Arguments:
//		IN	I
//			the remove device IRP
//
//	Return Value:
//		NTSTATUS
//
NTSTATUS XunicDevice::OnRemoveDevice(KIrp I)
{
	T.Trace(TraceInfo, __FUNCTION__"++.  IRP %p\n", I);

	NTSTATUS status = STATUS_SUCCESS;

	// TODO: Add device-specific code to remove your hardware device.
    // The base class will handle completion of the IRP

	// Release the system resources
	Invalidate();

	T.Trace(TraceInfo, __FUNCTION__"--.  IRP %p, STATUS %x\n", I, STATUS_SUCCESS);

	// Can't fail this IRP
	return STATUS_SUCCESS;
}

///////////////////////////////////////////////////////////////////////////////////////////////////
//  XunicDevice::OnDevicePowerUp
//		Handler for IRP_MJ_POWER subfcn IRP_MN_SET_POWER 
//		for a request to go to power on state from low power state
//		This function was called by the framework from the completion
//		routine of the IRP_MJ_POWER dispatch handler in KPnpDevice.
//		The bus driver has completed the IRP and this driver can now
//		access the hardware device.  
//		This routine runs at DISPATCH_LEVEL.
//
//	Arguments:
//		IN	I
//			the power IRP
//
//	Return Value:
//		NTSTATUS
//
NTSTATUS XunicDevice::OnDevicePowerUp(KIrp I)
{
	T.Trace(TraceInfo, __FUNCTION__"++.  IRP %p\n", I);

	NTSTATUS status = STATUS_SUCCESS;

	// TODO: Add device-specific code to:
	//		 Restore any context to the hardware device that
	//		 was saved during the handling of a power down request.
	//		 See the OnDeviceSleep function.
	//		 Do NOT complete this IRP.
    //		 The base class will handle completion of the IRP

	T.Trace(TraceInfo, __FUNCTION__"--.  IRP %p, STATUS %x\n", I, status);

	return status;

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产成人午夜精品5599| 亚洲视频在线一区| 久久国产精品色| 欧美大白屁股肥臀xxxxxx| 日韩国产欧美在线播放| 91精品国产欧美一区二区成人| 秋霞国产午夜精品免费视频| 欧美成人伊人久久综合网| 国产精品一区二区在线看| 国产精品久久久久久久久免费桃花| 不卡一二三区首页| 一区二区三区在线观看视频| 欧美精品少妇一区二区三区| 经典三级一区二区| 国产精品伦理一区二区| 欧美午夜精品一区二区三区| 麻豆一区二区三| 久久久.com| 欧美主播一区二区三区| 日日夜夜免费精品| 国产色婷婷亚洲99精品小说| 91在线云播放| 美脚の诱脚舐め脚责91| 国产精品毛片久久久久久| 欧美专区在线观看一区| 精品亚洲成a人| 自拍偷拍亚洲激情| 欧美一区二区人人喊爽| 成人一区二区三区中文字幕| 亚洲va欧美va天堂v国产综合| 日韩欧美一级在线播放| av电影天堂一区二区在线观看| 亚洲福利一区二区三区| 久久美女高清视频| 在线观看日韩精品| 国产麻豆精品久久一二三| 亚洲欧美日韩在线不卡| 精品久久久久久最新网址| 99国产精品久| 国产在线精品视频| 亚洲一区视频在线| 国产精品无人区| 日韩三级中文字幕| 国产白丝精品91爽爽久久| 亚洲成av人片在线| 国产精品入口麻豆原神| 欧美一级高清大全免费观看| 色综合久久中文字幕综合网| 国产美女在线精品| 日本女优在线视频一区二区| 亚洲裸体在线观看| 欧美激情一区二区三区不卡 | 国产精品中文欧美| 一区二区三区成人| 国产精品丝袜久久久久久app| 欧美日韩亚洲丝袜制服| 99精品视频一区二区| 国产丶欧美丶日本不卡视频| 美脚の诱脚舐め脚责91| 午夜久久电影网| 亚洲图片一区二区| 亚洲男人的天堂av| 中文字幕在线观看一区二区| 国产午夜亚洲精品羞羞网站| 欧美r级在线观看| 日韩小视频在线观看专区| 欧美丰满嫩嫩电影| 欧美三电影在线| 欧美亚州韩日在线看免费版国语版| 国产a精品视频| 国产成人日日夜夜| 国产成人一级电影| 国产老妇另类xxxxx| 精品写真视频在线观看| 日本女人一区二区三区| 日本aⅴ精品一区二区三区 | 精品一区二区在线播放| 亚洲成av人片一区二区三区| 一区二区在线观看免费 | 欧美大片在线观看一区二区| 91高清视频免费看| 91久久精品网| 欧美视频一区在线| 91麻豆精品国产| 在线播放日韩导航| 欧美一级艳片视频免费观看| 欧美日韩高清一区二区三区| 欧美日韩五月天| 欧美日韩成人在线| 日韩精品中文字幕一区| 日韩精品中文字幕一区| 精品精品国产高清一毛片一天堂| 欧美一级在线观看| xf在线a精品一区二区视频网站| 日韩欧美不卡一区| 国产午夜精品在线观看| 国产欧美中文在线| 亚洲天堂2014| 午夜欧美一区二区三区在线播放| 丝袜美腿成人在线| 韩国精品免费视频| 成人国产免费视频| 一本久久综合亚洲鲁鲁五月天| 欧美日韩在线播放三区| 日韩视频一区在线观看| 久久亚洲一区二区三区明星换脸| 国产欧美日韩精品一区| 亚洲免费在线观看| 六月婷婷色综合| 懂色av一区二区三区免费看| 99天天综合性| 欧美日韩国产首页| 精品国产乱码久久久久久影片| 中文天堂在线一区| 午夜精品久久久| 成人精品国产一区二区4080| 欧美在线观看一二区| 精品91自产拍在线观看一区| 亚洲天堂2016| 精品无码三级在线观看视频| 成人午夜碰碰视频| 制服丝袜亚洲色图| 中文字幕亚洲精品在线观看| 天堂蜜桃一区二区三区| 国产剧情一区在线| 欧美三级日韩在线| 国产偷国产偷亚洲高清人白洁| 亚洲综合激情小说| 国产a久久麻豆| 日韩一级免费一区| 亚洲一区影音先锋| 国产宾馆实践打屁股91| 91精品国产综合久久小美女| 亚洲色图制服丝袜| 国产成人综合网站| 在线播放国产精品二区一二区四区 | 视频一区视频二区在线观看| 精品久久久三级丝袜| 亚洲一区二区三区在线播放| 国产成a人无v码亚洲福利| 777xxx欧美| 亚洲另类春色校园小说| 国产精品一区二区男女羞羞无遮挡| 欧美色图片你懂的| 国产精品久久久久久一区二区三区 | 国产美女精品人人做人人爽| 欧美性一区二区| 中文乱码免费一区二区| 国产一区二区免费看| 这里只有精品免费| 亚洲一级二级三级| 91网上在线视频| 国产精品久久久久久户外露出| 国产一区二区久久| 精品粉嫩超白一线天av| 秋霞电影网一区二区| 欧美剧情电影在线观看完整版免费励志电影| 国产精品高清亚洲| 日韩网站在线看片你懂的| 国产精品久久一卡二卡| 欧美网站大全在线观看| 国产成人精品亚洲777人妖| 久久精品视频一区| 高清在线成人网| 亚洲一区在线视频观看| 色综合久久88色综合天天| 亚洲一区日韩精品中文字幕| 欧美日韩精品一区视频| 激情av综合网| 一区二区三区欧美激情| 69堂亚洲精品首页| 本田岬高潮一区二区三区| www.亚洲精品| 亚洲日本在线a| 色综合一个色综合| 一区二区中文视频| 色综合天天综合| 亚洲小说春色综合另类电影| 欧美日韩在线播放一区| 五月婷婷色综合| 日韩免费高清视频| 国产老妇另类xxxxx| 国产精品女主播在线观看| a4yy欧美一区二区三区| 亚洲麻豆国产自偷在线| 欧美日本免费一区二区三区| 日韩专区一卡二卡| 精品捆绑美女sm三区| 成人免费观看av| 亚洲一区二区在线免费观看视频| 欧美日韩国产bt| 精品一区二区三区日韩| 精品福利一二区| 国产欧美日韩综合精品一区二区 | 日韩美女精品在线| 91福利国产成人精品照片| 午夜欧美视频在线观看| 久久精品网站免费观看| 色偷偷88欧美精品久久久| 日韩不卡一二三区|