To: Evgeniy Dushistov <dushistov@xxxxxxx> CC: linux-fsdevel@xxxxxxxxxxxxxxx Subject: ufs filesystem cannot mount NetBSD/arm64 partition The disk obtained by $ wget http://nycdn.netbsd.org/pub/NetBSD-daily/netbsd-9/latest/evbarm-aarch64/binary/gzimg/arm64.img.gz $ gunzip arm64.img contains two partitions, as shown by $ fdisk arm64.img Device Boot Start End Sectors Size Id Type arm64.img1 * 32768 196607 163840 80M c W95 FAT32 (LBA) arm64.img2 196608 2366335 2169728 1G a9 NetBSD The second partition is of type ufs, with subtype 44bsd (as all NetBSD UFS partitions). But Linux cannot mount them. How to reproduce: # kpartx -av arm64.img add map loopXXp1 ... add map loopXXp2 ... # mount -r -t ufs -o ufstype=44bsd /dev/mapper/loopXXp2 /mnt mount: /mnt: wrong fs type, bad option, bad superblock on /dev/mapper/loopXXp2, missing codepage or helper program, or other error. dmesg(1) may have more information after failed mount system call. # dmesg ... [ 285.212612] ufs: UFSD (fs/ufs/super.c, 797): ufs_fill_super: [ 285.212619] ufs: ENTER [ 285.212622] ufs: UFSD (fs/ufs/super.c, 812): ufs_fill_super: [ 285.212625] ufs: flag 1 [ 285.212629] ufs: UFSD (fs/ufs/super.c, 387): ufs_parse_options: [ 285.212632] ufs: ENTER [ 285.212636] ufs: UFSD (fs/ufs/super.c, 852): ufs_fill_super: [ 285.212639] ufs: ufstype=44bsd [ 285.212739] ufs: ufs_fill_super(): fragment size 8192 is too large [ 285.212745] ufs: UFSD (fs/ufs/super.c, 1300): ufs_fill_super: [ 285.212749] ufs: EXIT (FAILED) Reproduced on Ubuntu 23.10 with a vanilla linux-6.7.0. Whereas this partition can be mounted fine on FreeBSD, NetBSD, OpenBSD. FreeBSD 11: # mount -r -t ufs /dev/ada1s2 /mnt NetBSD 9.3: # mount -r -t ffs /dev/wd1a /mnt OpenBSD 7.4: # mount -r -t ffs /dev/wd1j /mnt The source code line which emits the ufs: ufs_fill_super(): fragment size 8192 is too large error is obviously linux/fs/ufs/super.c:1083. Bruno