dpme(4) dpme(4)NAME dpme - format of disk partition map entries SYNOPSIS #include <apple/dpme.h> DESCRIPTION Starting at physical block 1 (offset 512 bytes) of each disk resides a disk partition map. This map describes the layout of the partitions for that disk. The disk partition map consists of one or more disk partition map entries. Each entry corresponds to at most one disk partition. The format of a disk partition map entry is: typedef struct { u16 dpme_signature; u16 dpme_reserved_1; u32 dpme_map_entries; u32 dpme_pblock_start; u32 dpme_pblocks; DPIDENT dpme_dpident; u32 dpme_lblock_start; u32 dpme_lblocks; u32 dpme_reserved_2: 23; /* Bit 9 through 31 */ u32 dpme_os_specific_1: 1; /* Bit 8 */ u32 dpme_os_specific_2: 1; /* Bit 7 */ u32 dpme_os_pic_code: 1; /* Bit 6 */ u32 dpme_writable: 1; /* Bit 5 */ u32 dpme_readable: 1; /* Bit 4 */ u32 dpme_bootable: 1; /* Bit 3 */ u32 dpme_in_use: 1; /* Bit 2 */ u32 dpme_allocated: 1; /* Bit 1 */ u32 dpme_valid: 1; /* Bit 0 */ u32 dpme_boot_block; u32 dpme_boot_bytes; u8 *dpme_load_addr; u8 *dpme_load_addr_2; u8 *dpme_goto_addr; u8 *dpme_goto_addr_2; u32 dpme_checksum; char dpme_process_id[16]; u32 dpme_boot_args[32]; u32 dpme_reserved_3[62]; } DPME; #define DPME_SIGNATURE 0x504d /* Signature value */ #define DPM_OFF 512 /* byte offset of dp map */ #define DPISTRLEN 32 struct dpident { April, 1990 1
dpme(4) dpme(4)char dpiname[DPISTRLEN]; /* name of partition */ char dpitype[DPISTRLEN]; /* type of partition */ }; typedef struct dpident DPIDENT; FIELD DESCRIPTIONS dpme_signature This field should always contain the magic number DPME_SIGNATURE. dpme_reserved_1 This field is not used by A/UX. dpme_map_entries This field indicates the size of the disk partition map measured in units of disk partition map entries. Since each disk partition map entry is one block big, this field also indicates the number of blocks in the parti- tion map. The value of this field is only meaningful for the first entry in the disk partition map. dpme_pblock_start This field indicates the physical block number of the starting block of the physical partition. dpme_pblocks This field indicates the number of physical blocks in the partition. This is usually referred to as the size of the physical partition. dpme_dpident This field is a structure that contains two string fields. The first field, dpiname, contains the name of the partition. The second field, dpitype, contains the type of the partition. If the partition name (or type) is less than DPISTRLEN bytes long, it must be terminat- ed by a NULL (binary zero) byte. An empty partition name or type (first byte NULL) is legal. These strings are case sensitive. dpme_lblock_start For A/UX partitions, this field will always be zero. This field designates the first data block of the logi- cal partition. dpme_lblocks This field designates the number of blocks in the data area of the partition. This is usually referred to as the size of the logical partition. For alternate bad blocking to occur it is necessary for the logical par- tition to be smaller than the physical partition. Those blocks between the end of the logical partition 2 April, 1990
dpme(4) dpme(4)and the end of the physical partition are usually used for alternate bad blocking. dpme_reserved_2 This field is not used by A/UX. dpme_os_specific_1 This field is not used by A/UX. dpme_os_specific_2 This field is not used by A/UX. dpme_os_pic_code This field is not used by A/UX. dpme_writable This bit indicates that the creating/controlling operating system allows writing of the logical disk that comprises this partition. Whether or not the writing is allowed by other operating systems and/or processors is not defined. Mainly informative. dpme_readable This field is not used by A/UX. dpme_bootable This field is not used by A/UX. dpme_in_use This field is not used by A/UX. dpme_allocated This bit indicates whether or not an operating system has laid claim to the partition described by this en- try. dpme_valid This bit indicated whether or not this partition entry is valid or not. dpme_boot_block This field is not used by A/UX. dpme_boot_bytes This field is not used by A/UX. dpme_load_addr This field is not used by A/UX. dpme_load_addr_2 This field is not used by A/UX. April, 1990 3
dpme(4) dpme(4)dpme_goto_addr This field is not used by A/UX. dpme_goto_addr_2 This field is not used by A/UX. dpme_checksum This field is not used by A/UX. dpme_process_id This field is not used by A/UX. dpme_boot_args dpme_reserved_3 This field is not used by A/UX. SEE ALSO dp(1M), pname(1M), altblk(4), bzb(4), gd(7). FILES /dev/rdsk/c?d?s31 /usr/include/apple/dpme.h BUGS It could be argued that the dpme_boot_args and dpme_signature fields would more appropriately be named dpme_os_specific and dpme_magic, respectively. 4 April, 1990