DK(4)
π NAME π
dk β disk partition (wedge) driver. This is the dk(4) page from the Kernel Interfaces Manual, and yes bestie, it's the section-4 one π
.
β¨ SYNOPSIS β¨
options DKWEDGE_AUTODISCOVER
options DKWEDGE_METHOD_APPLE
options DKWEDGE_METHOD_BSDLABEL
options DKWEDGE_METHOD_GPT
options DKWEDGE_METHOD_MBR
options DKWEDGE_METHOD_RDB
options DKWEDGE_METHOD_TOS
π¦ DESCRIPTION π¦
Okay so the dk driver gives you a disk-like interface β a wedge β pointing at some area of a physical disk. It's giving "tiny fake disk with main character energy." Wedges can be configured manually with dkctl(8), or the kernel can set them up automatically when the physical disk attaches. Literal auto-magic β¨.
Wedges need to have unique names. If a duplicate name gets detected during auto-discovery, that partition is ignored. No cap π.
π KERNEL OPTIONS π
DKWEDGE_AUTODISCOVERβ automatically detect and configure wedges using any available methods. For each partition found, a wedge with a corresponding name is created.
Currently only DKWEDGE_METHOD_GPT and DKWEDGE_METHOD_APPLE are enabled by default. iykyk π
DKWEDGE_METHOD_APPLEβ Apple partition map detection method. πDKWEDGE_METHOD_BSDLABELβ BSD disklabel detection method.
For each configured partition in disklabel(5) that is not of type FS_UNUSED, a wedge is created and named after the d_packname field followed by / and the partition letter a..p.
When the d_packname is empty or has the value fictitious, the regular partition names are used as wedge names, i.e. the device name, unit number and partition letter, for example wd0a.
DKWEDGE_METHOD_GPTβ Extensible Firmware Interface Globally Unique Identifier Partition Table (GPT) detection method.
For every GPT partition a wedge is created and named after the partition label. GPT partitions are UTF-16βencoded β this is converted into UTF-8. If a partition has no label, its UUID is used instead.
DKWEDGE_METHOD_MBRβ IBM PC-compatible Master Boot Record (MBR) partitioning detection method, with support for Extended MBRs.
For every partition in the MBR a wedge is created and named like a regular partition name, i.e. the device name, unit number and a partition letter, for example wd0e. Primary partitions start with e, extended partitions start with i.
DKWEDGE_METHOD_RDBβ Amiga Rigid Disk Block (RDB) partitioning detection method. πDKWEDGE_METHOD_TOSβ Atari's TOS partition map detection method, for disks that conform to Atari's AHDI specification.
For each partition, a wedge is created with a name of the format ATARI_{type}_{number} where type may either be GEM or BGM. The number 0 partition typically corresponds to the C: drive when read on an actual Atari, the next to D: and so on. Extended partitions (those of type XGM) are not currently supported.
π FILES π
/dev/dk*β block modedkdevice special files./dev/rdk*β raw modedkdevice special files.
π SEE ALSO π
config(1), disklabel(8), dkctl(8), fdisk(8), gpt(8), and MAKEDEV(8). Go read those too, bestie π«Ά.
β HISTORY β
The dk driver first appeared in NetBSD 3.0. Iconic behavior, honestly π.
π AUTHORS π
The dk driver was written by Jason R. Thorpe. Respect the icon who wrote it π«‘π.
This page's source/version line is Debian, dated April 2, 2024, and it's the DK(4) page β mwah, bestie πβ¨
π¦ where this page comes from
- nixpkgs unstable: netbsd-source 11.0
- Copyright (c) 2006 The NetBSD Foundation, Inc
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms