PARTITION_INFORMATION_EX - NtDoc

Native API online documentation, based on the System Informer (formerly Process Hacker) phnt headers
// ntdddisk.h

typedef struct _PARTITION_INFORMATION_EX {
  PARTITION_STYLE PartitionStyle;
  LARGE_INTEGER   StartingOffset;
  LARGE_INTEGER   PartitionLength;
  ULONG           PartitionNumber;
  BOOLEAN         RewritePartition;
  BOOLEAN         IsServicePartition;
  union {
    PARTITION_INFORMATION_MBR Mbr;
    PARTITION_INFORMATION_GPT Gpt;
  } DUMMYUNIONNAME;
} PARTITION_INFORMATION_EX, *PPARTITION_INFORMATION_EX;

View the official Windows Driver Kit DDI reference
// winioctl.h

typedef struct _PARTITION_INFORMATION_EX {
  PARTITION_STYLE PartitionStyle;
  LARGE_INTEGER   StartingOffset;
  LARGE_INTEGER   PartitionLength;
  DWORD           PartitionNumber;
  BOOLEAN         RewritePartition;
  BOOLEAN         IsServicePartition;
  union {
    PARTITION_INFORMATION_MBR Mbr;
    PARTITION_INFORMATION_GPT Gpt;
  } DUMMYUNIONNAME;
} PARTITION_INFORMATION_EX, *PPARTITION_INFORMATION_EX;

View the official Win32 API reference

NtDoc

No description available.

Windows Driver Kit DDI reference (ns-ntdddisk-_partition_information_ex)

PARTITION_INFORMATION_EX structure

Description

PARTITION_INFORMATION_EX is the extended version of the PARTITION_INFORMATION structure. It holds information both for partitions with a Master Boot Record and for partitions with a GUID Partition Table.

Members

PartitionStyle

Takes a PARTITION_STYLE enumerated value that specifies the type of partition table that contains the partition.

StartingOffset

Specifies the offset in bytes on drive where the partition begins.

PartitionLength

Specifies the length in bytes of the partition.

PartitionNumber

Specifies the number of the partition.

RewritePartition

Indicates, when TRUE, that the partition information has changed. When FALSE, the information has not changed. This member has a value of TRUE when the partition has changed as a result of an IOCTL_DISK_SET_DRIVE_LAYOUT IOCTL. This informs the system that the partition information needs to be rewritten.

IsServicePartition

When TRUE, indicates that the partition is service.

DUMMYUNIONNAME

DUMMYUNIONNAME.Mbr

Contains a structure of type PARTITION_INFORMATION_MBR containing information specific to a partition with a PartitionStyle member of PARTITION_STYLE_MBR.

DUMMYUNIONNAME.Gpt

Contains a structure of type PARTITION_INFORMATION_GPT containing information specific to a partition with a PartitionStyle member of PARTITION_STYLE_GPT.

Remarks

This is the extended version of the partition information structure, PARTITION_INFORMATION. IoReadPartitionTableEx and IoWritePartitionTableEx operate on an array of PARTITON_INFORMATION_EX structures contained within the extended drive layout structure, DRIVE_LAYOUT_INFORMATION_EX. PARTITION_INFORMATION_EX replaces the structure PARTITION_INFORMATION that was used with IoReadPartitionTable and IoWritePartitionTable. The principle difference is that the new structures and routines support both Master Boot Record (MBR) partitions and GUID Partition Table (GPT) partitions, whereas the older routines and structures are only used with MBR partitions.

See also

IoReadPartitionTable

IoWritePartitionTable

PARTITION_INFORMATION_GPT

PARTITION_INFORMATION_MBR


Win32 API reference (ns-winioctl-partition_information_ex)

PARTITION_INFORMATION_EX structure

Description

Contains partition information for standard AT-style master boot record (MBR) and Extensible Firmware Interface (EFI) disks.

Members

PartitionStyle

The format of the partition. For a list of values, see PARTITION_STYLE.

StartingOffset

The starting offset of the partition.

PartitionLength

The size of the partition, in bytes.

PartitionNumber

The number of the partition (1-based).

RewritePartition

If this member is TRUE, the partition is rewritable. The value of this parameter should be set to TRUE.

IsServicePartition

DUMMYUNIONNAME

DUMMYUNIONNAME.Mbr

A PARTITION_INFORMATION_MBR structure that specifies partition information specific to master boot record (MBR) disks. The MBR partition format is the standard AT-style format.

DUMMYUNIONNAME.Gpt

A PARTITION_INFORMATION_GPT structure that specifies partition information specific to GUID partition table (GPT) disks. The GPT format corresponds to the EFI partition format.

Remarks

If the partition is on a disk formatted as type master boot record (MBR), partition size totals are limited. For more information, see the Remarks section of IOCTL_DISK_SET_DRIVE_LAYOUT.

See also

File System Recognition

IOCTL_DISK_GET_PARTITION_INFO_EX

IOCTL_DISK_SET_PARTITION_INFO_EX

PARTITION_INFORMATION_GPT

PARTITION_INFORMATION_MBR

PARTITION_STYLE