Christian Taedcke 08f622a127 fs: fat: calculate FAT type based on cluster count
This fixes an issue where the FAT type (FAT12, FAT16) is not
correctly detected, e.g. when the BPB field BS_FilSysType contains the
valid value "FAT     ".

According to the FAT spec the field BS_FilSysType has only
informational character and does not determine the FAT type.

The logic of this code is based on the linux kernel implementation
from the file fs/fat/inode.c function fat_fill_super().

For details about FAT see http://elm-chan.org/docs/fat_e.html

Signed-off-by: Christian Taedcke <christian.taedcke@weidmueller.com>
2023-11-28 20:10:24 -05:00
..
2023-05-05 17:48:44 -04:00
2023-08-25 13:54:33 -04:00
2023-08-08 10:22:03 -04:00
2023-10-27 13:15:57 +03:00
2023-07-17 15:38:11 -04:00
2023-08-19 04:12:53 +02:00
2023-10-27 13:14:47 +03:00
2023-10-23 17:07:06 +03:00
2023-05-02 14:23:34 -04:00
2023-05-15 10:00:30 +02:00
2023-10-31 09:08:51 +01:00
2023-04-27 13:51:06 -04:00
2023-10-27 13:15:57 +03:00
2023-08-19 04:12:53 +02:00
2023-10-11 15:43:55 -04:00
2023-11-05 16:11:38 -05:00
2023-09-11 16:27:49 -04:00
2023-10-15 12:23:48 +02:00
2023-10-24 09:39:02 -04:00
2023-10-09 15:24:31 -04:00
2023-10-27 13:14:47 +03:00
2023-11-14 20:04:00 -07:00