adfs: reject disc records smaller than one filesystem block
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v2 Latest2 patches 5 repliesIn review
- v11 patch 1 replySuperseded
Changes in v2 from the cover letter
- Split the selftest into a separate patch.
- Added a tools/testing/selftests/filesystems/adfs test target.
- Added generated-good-image and generated-bad-image mount validation.
Patches in v2 No applies recorded yet
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/2 | adfs: reject disc records smaller than one filesystem blockfs/ | +4 | 5 replies | |
| 2/2 | selftests: filesystems: add ADFS mount validation testtools/ tools/ tools/ +1 more | +121 | 0 replies |
Reviews trailers per patch
No Reviewed-by, Acked-by or Tested-by trailers for v2 yet.
Cover letter [PATCH v2 0/2] adfs: reject disc records smaller than one filesystem block
Hi,
This v2 splits the ADFS fix and the requested selftest into separate patches.
Patch 1 rejects ADFS disc records whose declared disc size is smaller than one filesystem block. Such an image can otherwise mount and later hit a divide-by-zero in statfs because f_blocks is zero.
Patch 2 adds a filesystems/adfs selftest that generates two minimal ADFS
images: a valid image with a one-block disc size, and an otherwise identical invalid image whose disc size is smaller than one filesystem block. The test verifies that the valid image mounts and statfs succeeds, and that the invalid image is rejected at mount time.
Changes since v1:
- Split the selftest into a separate patch.
- Added a tools/testing/selftests/filesystems/adfs test target.
- Added generated-good-image and generated-bad-image mount validation.
Thanks,
Sam
Samuel Moelius (2):
adfs: reject disc records smaller than one filesystem block
selftests: filesystems: add ADFS mount validation test
fs/adfs/super.c | 4 + tools/testing/selftests/Makefile | 1 + .../selftests/filesystems/adfs/Makefile | 5 + .../filesystems/adfs/adfs_mount_check.sh | 113 ++++++++++++++++++ .../testing/selftests/filesystems/adfs/config | 2 + 5 files changed, 125 insertions(+) create mode 100644 tools/testing/selftests/filesystems/adfs/Makefile create mode 100755 tools/testing/selftests/filesystems/adfs/adfs_mount_check.sh create mode 100644 tools/testing/selftests/filesystems/adfs/config
Signature · 1 line
2.43.0