-
623aea0e
by Robert Gerigk at 2026-05-27T22:11:01+02:00
ntoskrnl: Store DEVPKEY_Device_Parent when enumerating child devices.
When handle_bus_relations enumerates child devices via
IRP_MN_QUERY_DEVICE_RELATIONS, store the parent's device instance ID
as DEVPKEY_Device_Parent on each child device.
This enables CM_Get_Parent to look up the parent device node
through the standard device property mechanism.
Signed-off-by: Jan Robert Gerigk <Robert-Gerigk@online.de>
-
b5339d5d
by Robert Gerigk at 2026-05-27T22:11:03+02:00
ntoskrnl/tests: Add DEVPKEY_Device_Parent test.
Verify that DEVPKEY_Device_Parent is set on child devices after
bus enumeration.
Signed-off-by: Jan Robert Gerigk <Robert-Gerigk@online.de>
-
0ca58250
by Robert Gerigk at 2026-05-27T22:11:05+02:00
ntoskrnl: Store DEVPKEY_Device_Children on parent after bus enumeration.
After enumerating child devices via IRP_MN_QUERY_DEVICE_RELATIONS,
store the list of child device instance IDs as DEVPKEY_Device_Children
on the parent device.
Signed-off-by: Jan Robert Gerigk <Robert-Gerigk@online.de>
-
aba27d7e
by Robert Gerigk at 2026-05-27T22:11:07+02:00
ntoskrnl/tests: Add DEVPKEY_Device_Children test.
Verify that DEVPKEY_Device_Children is set on the bus PDO after
child enumeration and contains the child's instance ID as a
MULTI_SZ entry.
Signed-off-by: Jan Robert Gerigk <Robert-Gerigk@online.de>
-
0ecfa788
by Robert Gerigk at 2026-05-27T22:11:08+02:00
ntoskrnl: Store DEVPKEY_Device_Siblings on each child after bus enumeration.
After enumerating child devices via IRP_MN_QUERY_DEVICE_RELATIONS,
store the list of sibling device instance IDs (all other children of
the same parent) as DEVPKEY_Device_Siblings on each child device.
Signed-off-by: Jan Robert Gerigk <Robert-Gerigk@online.de>
-
46ee7c8b
by Robert Gerigk at 2026-05-27T22:11:10+02:00
ntoskrnl/tests: Add DEVPKEY_Device_Siblings test.
The test setup registers exactly one child, so the siblings list is
empty. Verify that DEVPKEY_Device_Siblings is set on the child PDO and
holds a properly-terminated empty MULTI_SZ (a single trailing NUL).
Signed-off-by: Jan Robert Gerigk <Robert-Gerigk@online.de>
-
b3589555
by Robert Gerigk at 2026-05-27T22:11:11+02:00
cfgmgr32: Implement CM_Get_Parent using DEVPKEY_Device_Parent property.
Implement CM_Get_Parent by reading the DEVPKEY_Device_Parent property
that ntoskrnl stores when enumerating child devices.
Move the implementation from setupapi (which was a stub) to cfgmgr32,
and have setupapi forward to it.
Signed-off-by: Jan Robert Gerigk <Robert-Gerigk@online.de>
-
748ce681
by Robert Gerigk at 2026-05-27T22:11:15+02:00
ntoskrnl/tests: Test CM_Get_Parent on the PnP-managed child device.
Move the CM_Get_Parent positive-path assertion into test_pnp_devices,
where the child device has DEVPKEY_Device_Parent reliably populated by
the bus driver. With the property in place, the result is always
CR_SUCCESS and the returned parent maps back to the bus instance ID
"ROOT\\WINETEST\\0".
The setupapi-side test is reduced to the parameter-validation check
(CR_INVALID_POINTER for a NULL output pointer), which does not depend
on PnP state.
Signed-off-by: Jan Robert Gerigk <Robert-Gerigk@online.de>