win-pvdrivers

view xenusb/xenusb.c @ 1031:329b9b9d47ec

re-enable xenusb. compiles but untested.
author James Harper <james.harper@bendigoit.com.au>
date Thu Feb 21 20:37:38 2013 +1100 (2013-02-21)
parents 5bdb7251370c
children
line source
1 /*
2 PV Drivers for Windows Xen HVM Domains
3 Copyright (C) 2009 James Harper
5 This program is free software; you can redistribute it and/or
6 modify it under the terms of the GNU General Public License
7 as published by the Free Software Foundation; either version 2
8 of the License, or (at your option) any later version.
10 This program is distributed in the hope that it will be useful,
11 but WITHOUT ANY WARRANTY; without even the implied warranty of
12 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
13 GNU General Public License for more details.
15 You should have received a copy of the GNU General Public License
16 along with this program; if not, write to the Free Software
17 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
18 */
20 #define INITGUID
21 #include "xenusb.h"
22 #include <stdlib.h>
24 DRIVER_INITIALIZE DriverEntry;
26 NTSTATUS
27 DriverEntry(PDRIVER_OBJECT DriverObject, PUNICODE_STRING RegistryPath) {
28 NTSTATUS status = STATUS_SUCCESS;
29 WDF_DRIVER_CONFIG config;
30 WDFDRIVER driver;
32 FUNCTION_ENTER();
34 WDF_DRIVER_CONFIG_INIT(&config, XenUsb_EvtDriverDeviceAdd);
35 status = WdfDriverCreate(DriverObject, RegistryPath, WDF_NO_OBJECT_ATTRIBUTES, &config, &driver);
37 if (!NT_SUCCESS(status)) {
38 FUNCTION_MSG("WdfDriverCreate failed with status 0x%x\n", status);
39 }
41 FUNCTION_EXIT();
43 return status;
44 }