FAT/FAT32 Mirroring

FAT32 Features

The following topics describe the FAT32 file system.

FAT Mirroring

Mirroring Description
When Enabled (bit 0x0080 clear) With mirroring enabled, whenever a FAT sector is written, it will also be written to every other FAT. Also, a mirrored FAT sector can be read from any FAT. A FAT32 drive with multiple FATs will behave the same as FAT16 and FAT12 drives with multiple FATs. That is, the multiple FATs are backups of each other.
When Disabled (bit 0x0080 set) With mirroring disabled, only one of the FATs is active. The active FAT is the one specified by bits 0 through 3 of the extdpb_flags member of DPB. The other FATs are ignored. Disabling mirroring allows better handling of a drive with a bad sector in one of the FATs. If a bad sector exists, access to the damaged FAT can be completely disabled. Then, a new FAT can be built in one of the inactive FATs and then made accessible by changing the active FAT value in extdpb_flags.

DPB (FAT32)

The DPB was extended to include FAT32 information. Changes are effective for Windows 95 OEM Service Release 2 and later.

  • DPB STRUC
  • dpb_drive DB ?
  • dpb_unit DB ?
  • dpb_sector_size DW ?
  • dpb_cluster_mask DB ?
  • dpb_cluster_shift DB ?
  • dpb_first_fat DW ?
  • dpb_fat_count DB ?
  • dpb_root_entries DW ?
  • dpb_first_sector DW ?
  • dpb_max_cluster DW ?
  • dpb_fat_size DW ?
  • dpb_dir_sector DW ?
  • dpb_reserved2 DD ?
  • dpb_media DB ?
  • fdef NOTFAT32
  • dpb_first_access DB ?
  • else
  • dpb_reserved DB ?
  • endif
  • dpb_reserved3 DD ?
  • dpb_next_free DW ?
  • dpb_free_cnt DW ?
  • ifndef NOTFAT32
  • extdpb_free_cnt_hi DW ?
  • extdpb_flags DW ?
  • extdpb_FSInfoSec DW ?
  • extdpb_BkUpBootSec DW ?
  • extdpb_first_sector DD ?
  • extdpb_max_cluster DD ?
  • extdpb_fat_size DD ?
  • extdpb_root_clus DD ?
  • extdpb_next_free DD ?
  • endif
  • DPB ENDS

Members

Value Description
BGBPB_F_ActiveFATMsk (000Fh) Mask for low four bits.
BGBPB_F_NoFATMirror (0080h) Do not mirror active FAT to inactive FATs.

*Bits 4-6 and 8-15 are reserved.