DeviceNode->ResourceList and DeviceNode->ResourceListTranslated should not share...
authorHervé Poussineau <hpoussin@reactos.org>
Sun, 17 Sep 2006 15:24:55 +0000 (15:24 +0000)
committerHervé Poussineau <hpoussin@reactos.org>
Sun, 17 Sep 2006 15:24:55 +0000 (15:24 +0000)
svn path=/trunk/; revision=24170

reactos/ntoskrnl/io/pnpmgr/pnpmgr.c

index 8b97c5b..22c1b2c 100644 (file)
@@ -132,6 +132,12 @@ IopStartDevice(
    Stack.Parameters.StartDevice.AllocatedResources = DeviceNode->ResourceList;
    Stack.Parameters.StartDevice.AllocatedResourcesTranslated = DeviceNode->ResourceListTranslated;
 
+   /* FIXME: Not sure of this! */
+   if (!Stack.Parameters.StartDevice.AllocatedResources)
+      Stack.Parameters.StartDevice.AllocatedResources = DeviceNode->BootResources;
+   if (!Stack.Parameters.StartDevice.AllocatedResourcesTranslated)
+      Stack.Parameters.StartDevice.AllocatedResourcesTranslated = DeviceNode->BootResources;
+
    Status = IopInitiatePnpIrp(
       Fdo,
       &IoStatusBlock,
@@ -1233,13 +1239,6 @@ IopAssignDeviceResources(PDEVICE_NODE DeviceNode)
    ULONG i;
    NTSTATUS Status;
 
-   if (DeviceNode->BootResources)
-   {
-      /* FIXME: Not sure of this! */
-      DeviceNode->ResourceList = DeviceNode->ResourceListTranslated = DeviceNode->BootResources;
-      return STATUS_SUCCESS;
-   }
-
    /* Fill DeviceNode->ResourceList and DeviceNode->ResourceListTranslated;
     * by using DeviceNode->ResourceRequirements */