BIOS parameter block
From Wikipedia, the free encyclopedia
In computing, the BIOS parameter block, often shortened to BPB, is a data structure describing the physical layout of a data storage volume. On partitioned devices, such as hard disks, the BPB describes the volume partition, whereas, on unpartitioned devices, such as floppy disks, it describes the entire medium. A basic BPB can appear and be used on any partition, including floppy disks where its presence is often necessary, however, certain filesystems also make use of it in describing basic filesystem structures. Filesystems making use of a BIOS parameter block include FAT16, FAT32, HPFS, and NTFS. ECMA-107 or ISO/IEC 9293 (which describes FAT as for flexible/floppy and optical disk cartridges) also describes this as an FDC Descriptor or an FDC Extended Descriptor.
The FAT12/16 BPB is as follows:
| Field | Hex offset | |
|---|---|---|
| BytesPerSector | dw ? | 0x000B |
| SectorsPerCluster | db ? | 0x000D |
| ReservedSectors | dw ? | 0x000E |
| FatCopies | db ? | 0x0010 |
| RootDirEntries | dw ? | 0x0011 |
| NumSectors | dw ? | 0x0013 |
| MediaType | db ? | 0x0015 |
| SectorsPerFAT | dw ? | 0x0016 |
| SectorsPerTrack | dw ? | 0x0018 |
| NumberOfHeads | dw ? | 0x001A |
| HiddenSectors | dd ? | 0x001C |
| SectorsBig | dd ? | 0x0020 |
[edit] Further reading
- Jonathan de Boyne Pollard. "All about BIOS Parameter Blocks". Frequently Given Answers. http://homepages.tesco.net./~J.deBoynePollard/FGA/bios-parameter-block.html. — a description of BPBs, from version 2.0 to version 7.0
- Ken W. Christopher, Barry A. Feigenbaum, & Shon O. Saliga (1990). "9: DOS Disk Usage". Developing applications using DOS. Wiley. ISBN 0-471-52231-7. — In the "processing the BIOS parameter block" section the authors describe the evolution of the BIOS parameter block from the MS-DOS version 2.0 BPB to the PC-DOS version 4.0 BPB, and label each field with the DOS version that introduced it.
- Carl Townsend (1989). "4: Disk organization and management". Advanced MS-DOS Expert Techniques for programmers. Howard M. Sams. ISBN 0-672-22667-7. — Figure 4.3 contains a diagram of the version 4.0 BPB and states that the layout of BPBs "is not defined by Microsoft and can vary with different vendors". At the time that the book was written, this was true. Microsoft first publicly documented the BPB structure in the OS/2 Developers' Toolkit.
- Alex Verstak (1998-03-10). "FAT Boot Sector". http://averstak.tripod.com/fatdox/bootsec.htm. — Verstak reverse engineers the BIOS parameter block. The paper contains several errors. One such is its statement that "the presence of the EBPB in FAT32 is not documented by Microsoft". See:
- Microsoft. "Chapter 10 - Disks and File Systems". Microsoft Windows 98 Resource Kit. http://www.microsoft.com/technet/archive/win98/reskit/part2/wrkc10.mspx. — Microsoft documents a version 4.0 BPB and a new "FAT32 BIOS Parameter Block (BPB)" (a version 7.0 BPB) for DOS-Windows 98 that is "larger than a standard BPB", has an "identical structure to a standard BPB", but that also "includes several extra fields".
- Microsoft. "Chapter 32 - Disk Concepts and Troubleshooting". Microsoft Windows 2000 Professional Resource Kit. http://www.microsoft.com/technet/prodtechnol/Windows2000Pro/reskit/part7/proch32.mspx. — Microsoft documents extended BPBs on both FAT16 and FAT32 volumes. It also documents BPBs on NTFS volumes.
- Microsoft. "How NTFS Works". Microsoft Windows Server 2003 NTFS Technical Reference. http://technet2.microsoft.com/WindowsServer/en/Library/8cc5891d-bf8e-4164-862d-dac5418c59481033.mspx#w2k3tr_ntfs_how_dhao. — The table "BPB and Extended BPB Fields on NTFS Volumes" describes BPBs on NTFS volumes. The descriptions of several fields contradict those given in the Windows 2000 Resource Kit.

