Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
mkfs.fat: Fix upper limit for CHS overflow in MBR
Maximal head value in MBR CHS is 255. But due to bug in MS-DOS which cause system crash when head value in MBR CHS is 255, it is common to use only maximal head value 254. Head value in MBR CHS is zero indexed. So number of disk heads (stored in FAT boot sector) is maximal head value in MBR CHS + 1. So fix upper limit for number of heads to 255 which can be still represented in MBR CHS without MS-DOS crash.
- Loading branch information