mirror of
https://github.com/reactos/reactos.git
synced 2025-02-25 01:39:30 +00:00
Attach the PDOs to device stack and report device unique IDs if available.
svn path=/trunk/; revision=14207
This commit is contained in:
parent
e7f2044681
commit
621ded7636
1 changed files with 12 additions and 10 deletions
|
@ -60,12 +60,7 @@ AcpiCreateDeviceIDString(PUNICODE_STRING DeviceID,
|
||||||
L"ACPI\\%S",
|
L"ACPI\\%S",
|
||||||
Node->device.id.hid);
|
Node->device.id.hid);
|
||||||
|
|
||||||
if (!AcpiCreateUnicodeString(DeviceID, Buffer, PagedPool))
|
return AcpiCreateUnicodeString(DeviceID, Buffer, PagedPool);
|
||||||
{
|
|
||||||
return FALSE;
|
|
||||||
}
|
|
||||||
|
|
||||||
return TRUE;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -108,8 +103,15 @@ BOOLEAN
|
||||||
AcpiCreateInstanceIDString(PUNICODE_STRING InstanceID,
|
AcpiCreateInstanceIDString(PUNICODE_STRING InstanceID,
|
||||||
BM_NODE *Node)
|
BM_NODE *Node)
|
||||||
{
|
{
|
||||||
/* FIXME: Create unique instnce id. */
|
WCHAR Buffer[10];
|
||||||
return AcpiCreateUnicodeString(InstanceID, L"0000", PagedPool);
|
|
||||||
|
if (Node->device.id.uid[0])
|
||||||
|
swprintf(Buffer, L"%S", Node->device.id.uid);
|
||||||
|
else
|
||||||
|
/* FIXME: Generate unique id! */
|
||||||
|
swprintf(Buffer, L"0000");
|
||||||
|
|
||||||
|
return AcpiCreateUnicodeString(InstanceID, Buffer, PagedPool);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@ -188,8 +190,8 @@ FdoQueryBusRelations(
|
||||||
|
|
||||||
PdoDeviceExtension->Common.DevicePowerState = PowerDeviceD0;
|
PdoDeviceExtension->Common.DevicePowerState = PowerDeviceD0;
|
||||||
|
|
||||||
// PdoDeviceExtension->Common.Ldo = IoAttachDeviceToDeviceStack(DeviceObject,
|
PdoDeviceExtension->Common.Ldo = IoAttachDeviceToDeviceStack(DeviceObject,
|
||||||
// Device->Pdo);
|
Device->Pdo);
|
||||||
|
|
||||||
RtlInitUnicodeString(&PdoDeviceExtension->DeviceID, NULL);
|
RtlInitUnicodeString(&PdoDeviceExtension->DeviceID, NULL);
|
||||||
RtlInitUnicodeString(&PdoDeviceExtension->InstanceID, NULL);
|
RtlInitUnicodeString(&PdoDeviceExtension->InstanceID, NULL);
|
||||||
|
|
Loading…
Reference in a new issue