Author: tfaber
Date: Mon Sep 18 11:50:42 2017
New Revision: 75906
URL: 
http://svn.reactos.org/svn/reactos?rev=75906&view=rev
Log:
[USBPORT]
- Rename NumInterfaces to NumEndpoints in USBPORT_OpenInterface
Modified:
    trunk/reactos/drivers/usb/usbport/device.c
Modified: trunk/reactos/drivers/usb/usbport/device.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/drivers/usb/usbport/device…
==============================================================================
--- trunk/reactos/drivers/usb/usbport/device.c  [iso-8859-1] (original)
+++ trunk/reactos/drivers/usb/usbport/device.c  [iso-8859-1] Mon Sep 18 11:50:42 2017
@@ -256,7 +256,7 @@
     PUSBPORT_PIPE_HANDLE PipeHandle;
     PUSB_ENDPOINT_DESCRIPTOR Descriptor;
     PUSBD_PIPE_INFORMATION PipeInfo;
-    ULONG NumInterfaces;
+    ULONG NumEndpoints;
     SIZE_T Length;
     SIZE_T HandleLength;
     BOOLEAN IsAllocated = FALSE;
@@ -273,10 +273,10 @@
InterfaceInfo->AlternateSetting,
&InterfaceInfo->AlternateSetting);
-    NumInterfaces = InterfaceDescriptor->bNumEndpoints;
+    NumEndpoints = InterfaceDescriptor->bNumEndpoints;
     Length = sizeof(USBD_INTERFACE_INFORMATION) +
-             (NumInterfaces - 1) * sizeof(USBD_PIPE_INFORMATION);
+             (NumEndpoints - 1) * sizeof(USBD_PIPE_INFORMATION);
     if (InterfaceInfo->AlternateSetting && IsSetInterface)
     {
@@ -290,7 +290,7 @@
     else
     {
         HandleLength = sizeof(USBPORT_INTERFACE_HANDLE) +
-                       (NumInterfaces - 1) * sizeof(USBPORT_PIPE_HANDLE);
+                       (NumEndpoints - 1) * sizeof(USBPORT_PIPE_HANDLE);
         InterfaceHandle = ExAllocatePoolWithTag(NonPagedPool,
                                                 HandleLength,
@@ -304,11 +304,11 @@
         RtlZeroMemory(InterfaceHandle, HandleLength);
-        if (NumInterfaces > 0)
+        if (NumEndpoints > 0)
         {
             PipeHandle = &InterfaceHandle->PipeHandle[0];
-            for (ix = 0; ix < NumInterfaces; ++ix)
+            for (ix = 0; ix < NumEndpoints; ++ix)
             {
                 PipeHandle->Flags = PIPE_HANDLE_FLAG_CLOSED;
                 PipeHandle->Endpoint = NULL;
@@ -335,11 +335,11 @@
     Descriptor = (PUSB_ENDPOINT_DESCRIPTOR)((ULONG_PTR)InterfaceDescriptor +
                                             InterfaceDescriptor->bLength);
-    if (NumInterfaces)
+    if (NumEndpoints)
     {
         PipeHandle = &InterfaceHandle->PipeHandle[0];
-        for (ix = 0; ix < NumInterfaces; ++ix)
+        for (ix = 0; ix < NumEndpoints; ++ix)
         {
             while (Descriptor->bDescriptorType != USB_ENDPOINT_DESCRIPTOR_TYPE)
             {
@@ -387,12 +387,12 @@
     if (USBD_SUCCESS(USBDStatus))
     {
-        if (NumInterfaces)
+        if (NumEndpoints)
         {
             PipeInfo = &InterfaceInfo->Pipes[0];
             PipeHandle = &InterfaceHandle->PipeHandle[0];
-            for (ix = 0; ix < NumInterfaces; ++ix)
+            for (ix = 0; ix < NumEndpoints; ++ix)
             {
                 Status = USBPORT_OpenPipe(FdoDevice,
                                           DeviceHandle,
@@ -424,7 +424,7 @@
     {
         if (InterfaceHandle)
         {
-            if (NumInterfaces)
+            if (NumEndpoints)
             {
                 DPRINT1("USBPORT_OpenInterface: USBDStatus - %lx\n",
USBDStatus);
             }