reactos/drivers/storage/partmgr
Hermès Bélusca-Maïto e80cd6760c
[PARTMGR] Reimplement IOCTL_MOUNTDEV_QUERY_UNIQUE_ID for MBR and GPT partitions (#6926)
CORE-15575

In addition, fix a PartitionId assignment copy-paste error in PartitionCreateDevice().

The returned standard UniqueId has the following format:

- Basic volume on MBR disk: disk Mbr.Signature + partition StartingOffset (length: 0x0C)
- Basic volume on GPT disk: "DMIO:ID:" + Gpt.PartitionGuid (length: 0x18)
- Volume on Basic disk (NT <= 4): 8-byte FTDisk identifier (length: 0x08)
- Volume on Dynamic disk (NT 5+): "DMIO:ID:" + dmio VolumeGuid (length: 0x18)
- Super-floppy (single-partition with StartingOffset == 0),
  or Removable media: DiskInterfaceName.
- As fallback, we use the VolumeInterfaceName.

References:
- https://winreg-kb.readthedocs.io/en/latest/sources/system-keys/Mounted-devices.html
- https://stackoverflow.com/a/72787681/21852502
- Manual testing on Windows.
2024-06-12 12:15:31 +02:00
..
CMakeLists.txt [BOOTDATA] Fix boot (addendum to dd56e065bc) 2020-12-06 01:55:20 +03:00
debug.h [PARTMGR] Add the Partition Manager driver 2020-11-13 03:04:15 +03:00
guid.c [PARTMGR] Add the Partition Manager driver 2020-11-13 03:04:15 +03:00
partition.c [PARTMGR] Reimplement IOCTL_MOUNTDEV_QUERY_UNIQUE_ID for MBR and GPT partitions (#6926) 2024-06-12 12:15:31 +02:00
partmgr.c [PARTMGR] Detect and flag partitionless ("super-floppy") disks (#6926) 2024-06-12 12:15:22 +02:00
partmgr.h [PARTMGR] Reimplement IOCTL_MOUNTDEV_QUERY_UNIQUE_ID for MBR and GPT partitions (#6926) 2024-06-12 12:15:31 +02:00
partmgr.rc [PARTMGR] Add the Partition Manager driver 2020-11-13 03:04:15 +03:00
partmgr_reg.inf [PARTMGR] Add the Partition Manager driver 2020-11-13 03:04:15 +03:00
utils.c [PARTMGR] Add the Partition Manager driver 2020-11-13 03:04:15 +03:00