win-pvdrivers

changeset 704:7b5ccd2632d9

Cleanups now that KdPrint is a no-op under Free build
author James Harper <james.harper@bendigoit.com.au>
date Thu Nov 26 19:51:45 2009 +1100 (2009-11-26)
parents b94dda2b30d6
children b620a1b82e0b
files xenusb/xenusb_devurb.c xenusb/xenusb_hub.c xenusb/xenusb_huburb.c
line diff
     1.1 --- a/xenusb/xenusb_devurb.c	Wed Nov 25 22:15:52 2009 +1100
     1.2 +++ b/xenusb/xenusb_devurb.c	Thu Nov 26 19:51:45 2009 +1100
     1.3 @@ -167,6 +167,7 @@ XenUsb_EvtIoInternalDeviceControl_DEVICE
     1.4  
     1.5    UNREFERENCED_PARAMETER(input_buffer_length);
     1.6    UNREFERENCED_PARAMETER(output_buffer_length);
     1.7 +  UNREFERENCED_PARAMETER(io_control_code);
     1.8  
     1.9    //FUNCTION_ENTER();
    1.10  
     2.1 --- a/xenusb/xenusb_hub.c	Wed Nov 25 22:15:52 2009 +1100
     2.2 +++ b/xenusb/xenusb_hub.c	Thu Nov 26 19:51:45 2009 +1100
     2.3 @@ -225,12 +225,6 @@ XenUsbHub_EvtIoInternalDeviceControl(
     2.4      *(PVOID *)wrp.Parameters.Others.Arg1 = WdfDeviceWdmGetPhysicalDevice(device);
     2.5      //*(PVOID *)wrp.Parameters.Others.Arg2 = IoGetAttachedDevice(WdfDeviceWdmGetDeviceObject(device));
     2.6      *(PVOID *)wrp.Parameters.Others.Arg2 = IoGetAttachedDevice(WdfDeviceWdmGetDeviceObject(xupdd->wdf_device_bus_fdo));
     2.7 -    {
     2.8 -    //PDEVICE_OBJECT hcdTopOfStack = IoGetAttachedDevice(WdfDeviceWdmGetDeviceObject(device));
     2.9 -    PDEVICE_OBJECT hcdTopOfStack = IoGetAttachedDevice(WdfDeviceWdmGetDeviceObject(xupdd->wdf_device_bus_fdo));
    2.10 -    KdPrint((__DRIVER_NAME "     hcdTopOfStack = %p\n", hcdTopOfStack));
    2.11 -    KdPrint((__DRIVER_NAME "     hcdTopOfStack->StackSize = %p\n", hcdTopOfStack->StackSize));
    2.12 -    }
    2.13      status = STATUS_SUCCESS;
    2.14      break;
    2.15    case IOCTL_INTERNAL_USB_RESET_PORT:
    2.16 @@ -378,6 +372,7 @@ XenUsbHub_EvtDeviceUsageNotification(WDF
    2.17    PXENUSB_PDO_DEVICE_DATA xupdd = GetXupdd(device);
    2.18  
    2.19    UNREFERENCED_PARAMETER(xupdd);
    2.20 +  UNREFERENCED_PARAMETER(is_in_notification_path);  
    2.21  
    2.22    FUNCTION_ENTER();
    2.23    
    2.24 @@ -429,10 +424,15 @@ XenUsbHub_UBIH_CreateUsbDevice(
    2.25    USHORT PortNumber)
    2.26  {
    2.27    NTSTATUS status = STATUS_SUCCESS;
    2.28 -  WDFDEVICE device = BusContext;
    2.29 +  
    2.30 +  UNREFERENCED_PARAMETER(BusContext);  
    2.31 +  UNREFERENCED_PARAMETER(HubDeviceHandle);
    2.32 +  UNREFERENCED_PARAMETER(PortStatus);
    2.33 +  UNREFERENCED_PARAMETER(PortNumber);
    2.34 +  
    2.35    FUNCTION_ENTER();
    2.36  
    2.37 -  KdPrint((__DRIVER_NAME "     device = %p\n", device));
    2.38 +  KdPrint((__DRIVER_NAME "     BusContext = %p\n", BusContext));
    2.39    KdPrint((__DRIVER_NAME "     DeviceHandle = %p\n", DeviceHandle));
    2.40    KdPrint((__DRIVER_NAME "     *DeviceHandle = %p\n", *DeviceHandle));
    2.41    KdPrint((__DRIVER_NAME "     HubDeviceHandle = %p\n", HubDeviceHandle));
    2.42 @@ -681,14 +681,15 @@ XenUsbHub_UBIH_GetUsbDescriptors(
    2.43    )
    2.44  {
    2.45    NTSTATUS status = STATUS_SUCCESS;
    2.46 -  WDFDEVICE device = BusContext;
    2.47    xenusb_device_t *usb_device = DeviceHandle;
    2.48    xenusb_config_t *usb_config;
    2.49    PUCHAR ptr;
    2.50  
    2.51 +  UNREFERENCED_PARAMETER(BusContext);  
    2.52 +
    2.53    FUNCTION_ENTER();
    2.54  
    2.55 -  KdPrint((__DRIVER_NAME "     device = %p\n", device));
    2.56 +  KdPrint((__DRIVER_NAME "     BusContext = %p\n", BusContext));
    2.57    KdPrint((__DRIVER_NAME "     DeviceHandle = %p\n", DeviceHandle));
    2.58    KdPrint((__DRIVER_NAME "     DeviceDescriptorBuffer = %p\n", DeviceDescriptorBuffer));
    2.59    KdPrint((__DRIVER_NAME "     DeviceDescriptorBufferLength = %d\n", *DeviceDescriptorBufferLength));
    2.60 @@ -793,6 +794,8 @@ XenUsbHub_UBIH_QueryDeviceInformation(
    2.61    ULONG i;
    2.62    ULONG required_size;
    2.63  
    2.64 +  UNREFERENCED_PARAMETER(BusContext);  
    2.65 +
    2.66    FUNCTION_ENTER();
    2.67  
    2.68    KdPrint((__DRIVER_NAME "     BusContext = %p\n", BusContext));
    2.69 @@ -845,6 +848,8 @@ XenUsbHub_UBIH_GetControllerInformation 
    2.70    //WDFDEVICE device = BusContext;
    2.71    //xenusb_device_t *usb_device = DeviceHandle;
    2.72  
    2.73 +  UNREFERENCED_PARAMETER(BusContext);  
    2.74 +
    2.75    FUNCTION_ENTER();
    2.76  
    2.77    KdPrint((__DRIVER_NAME "     BusContext = %p\n", BusContext));
    2.78 @@ -900,6 +905,9 @@ XenUsbHub_UBIH_GetExtendedHubInformation
    2.79    PUSB_EXTHUB_INFORMATION_0 hib = HubInformationBuffer;
    2.80    ULONG i;
    2.81  
    2.82 +  UNREFERENCED_PARAMETER(BusContext);  
    2.83 +  UNREFERENCED_PARAMETER(HubPhysicalDeviceObject);
    2.84 +  
    2.85    FUNCTION_ENTER();
    2.86  
    2.87    KdPrint((__DRIVER_NAME "     BusContext = %p\n", BusContext));
    2.88 @@ -942,10 +950,11 @@ XenUsbHub_UBIH_GetRootHubSymbolicName(
    2.89    PULONG HubNameActualLength)
    2.90  {
    2.91    NTSTATUS status = STATUS_SUCCESS;
    2.92 -  WDFDEVICE device = BusContext;
    2.93    FUNCTION_ENTER();
    2.94  
    2.95 -  KdPrint((__DRIVER_NAME "     device = %p\n", device));
    2.96 +  UNREFERENCED_PARAMETER(BusContext);
    2.97 +  
    2.98 +  KdPrint((__DRIVER_NAME "     BusContext = %p\n", BusContext));
    2.99    KdPrint((__DRIVER_NAME "     HubInformationBuffer = %p\n", HubInformationBuffer));
   2.100    KdPrint((__DRIVER_NAME "     HubInformationBufferLength = %d\n", HubInformationBufferLength));
   2.101    RtlStringCbCopyW(HubInformationBuffer, HubInformationBufferLength, L"ROOT_HUB");
   2.102 @@ -976,6 +985,11 @@ XenUsbHub_UBIH_Initialize20Hub (
   2.103    ULONG TtCount)
   2.104  {
   2.105    NTSTATUS status = STATUS_SUCCESS;
   2.106 +  
   2.107 +  UNREFERENCED_PARAMETER(BusContext);
   2.108 +  UNREFERENCED_PARAMETER(HubDeviceHandle);
   2.109 +  UNREFERENCED_PARAMETER(TtCount);
   2.110 +  
   2.111    FUNCTION_ENTER();
   2.112    KdPrint((__DRIVER_NAME "     BusContext = %p\n", BusContext));
   2.113    KdPrint((__DRIVER_NAME "     HubDeviceHandle = %p\n", HubDeviceHandle));
   2.114 @@ -1134,6 +1148,10 @@ XenUsbHub_UBIU_EnumLogEntry(
   2.115    FUNCTION_ENTER();
   2.116    
   2.117    UNREFERENCED_PARAMETER(BusContext);
   2.118 +  UNREFERENCED_PARAMETER(DriverTag);
   2.119 +  UNREFERENCED_PARAMETER(EnumTag);
   2.120 +  UNREFERENCED_PARAMETER(P1);
   2.121 +  UNREFERENCED_PARAMETER(P2);
   2.122    
   2.123    KdPrint((__DRIVER_NAME "     DriverTag = %08x\n", DriverTag));
   2.124    KdPrint((__DRIVER_NAME "     EnumTag = %08x\n", EnumTag));
     3.1 --- a/xenusb/xenusb_huburb.c	Wed Nov 25 22:15:52 2009 +1100
     3.2 +++ b/xenusb/xenusb_huburb.c	Thu Nov 26 19:51:45 2009 +1100
     3.3 @@ -41,6 +41,7 @@ XenUsb_EvtIoInternalDeviceControl_ROOTHU
     3.4  
     3.5    UNREFERENCED_PARAMETER(input_buffer_length);
     3.6    UNREFERENCED_PARAMETER(output_buffer_length);
     3.7 +  UNREFERENCED_PARAMETER(io_control_code);
     3.8  
     3.9    //FUNCTION_ENTER();
    3.10