 |
Index for Section 9 |
|
 |
Alphabetical listing for G |
|
 |
Bottom of page |
|
get_def_partitionmap(9r)
NAME
get_def_partitionmap - Disk: Calculates a default partition map
SYNOPSIS
int get_def_partitionmap(
register struct DEVGEOMST *geom,
register struct pt_tbl *pmap );
ARGUMENTS
geom
Specifies a pointer to the disk's geometry structure.
pmap
Specifies a pointer to the partition map to be filled in.
DESCRIPTION
The get_def_partitionmap interface calculates a default partition map when
supplied with a disk geometry. It uses the disk capacity and sector size
for the calculation and ignores other aspects of the geometry. The
partitions are layed out as follows:
· Partition a
Starts at block 0 and spans the number of blocks specified by the
global variable ddr_def_partsz_a.
· Partition b
Starts after partition a and spans the number of blocks specified by
the global variable ddr_def_partsz_b.
· Partition c
Spans the entire disk.
· Partitions d, e, and f
Are undefined with lengths of zero.
· Partition g
Starts after partition b and spans half of the remainder of the disk.
· Partition h
Starts after partition g and spans the remainder of the disk.
The get_def_partitionmap interface is called by a disk device driver's open
interface and DIOCGDEFPT ioctl command to create a default partition map.
EXAMPLE
See Writing Device Drivers: Advanced Topics for a code example of the
get_def_partitionmap interface.
RETURN VALUES
Upon successful completion, get_def_partitionmap returns the value zero
(0). Otherwise, it returns the value 1 to indicate the partition map could
not be updated.
SEE ALSO
ioctl Commands: DEVGETGEOM(9r)
Data Structures: DEVGEOMST(9s), pt_tbl(9s)
 |
Index for Section 9 |
|
 |
Alphabetical listing for G |
|
 |
Top of page |
|