public inbox for ltp@lists.linux.it
 help / color / mirror / Atom feed
* [LTP] [PATCH v3 0/3] Fix ioctl_ficlone(range) failures on certain FS
@ 2024-10-02 12:22 Andrea Cervesato
  2024-10-02 12:22 ` [LTP] [PATCH v3 1/3] Filter mkfs version in tst_fs Andrea Cervesato
                   ` (2 more replies)
  0 siblings, 3 replies; 8+ messages in thread
From: Andrea Cervesato @ 2024-10-02 12:22 UTC (permalink / raw)
  To: ltp

Filesystems implementing copy-on-write are usually supported by the kernel
from a certain version. This is the case of XFS which carried an
experimental support for CoW from 4.9 until 4.16.
At the same time, some mkfs tools might not support CoW before a certain
version. This is the case of mkfs.xfs < 1.5.0.

For these reasons, this LTP patch series is meant to cover a particular
scenario, where kernel and mkfs tools versions have to be cross-checked
in order to run ioctl_ficlone(range) tests.

Two new flags have been added to the tst_fs struct:
- mkfs_ver: test the mkfs tool version before using it and eventually
  skip test if it's not satisfied
- min_kver: test the minimum kernel version and skip the test if running
  kernel is too old

Signed-off-by: Andrea Cervesato <andrea.cervesato@suse.com>
---
Changes in v3:
- invert skip flag logic in check_kver and tst_check_cmd, so now it
  TBROK if defined
- test skip if FS is not supported by kernel
- remove bcachefs version check
- Link to v2: https://lore.kernel.org/r/20241001-ioctl_ficlone01_fix-v2-0-dd0b021dd31d@suse.com

Changes in v2:
- add mkfs_ver
- add min_kver
- fix mkfs.xfs version when using CoW
- fix bcachefs version
- Link to v1: https://lore.kernel.org/r/20240924-ioctl_ficlone01_fix-v1-1-7741e2e13cc2@suse.com

---
Andrea Cervesato (3):
      Filter mkfs version in tst_fs
      Add minimum kernel requirement for FS setup
      Setup minimal kernel for ioctl_clone(range) tests

 include/tst_private.h                              |   6 +-
 include/tst_test.h                                 |   9 ++
 lib/tst_cmd.c                                      | 125 ++++++++++++++-------
 lib/tst_test.c                                     |  44 ++++++--
 testcases/kernel/syscalls/ioctl/ioctl_ficlone01.c  |   4 +-
 testcases/kernel/syscalls/ioctl/ioctl_ficlone03.c  |   4 +-
 .../kernel/syscalls/ioctl/ioctl_ficlonerange01.c   |   4 +-
 .../kernel/syscalls/ioctl/ioctl_ficlonerange02.c   |   4 +-
 testcases/lib/tst_run_shell.c                      |  10 ++
 9 files changed, 154 insertions(+), 56 deletions(-)
---
base-commit: 701212f08d6e850457cc2b10238f28662ef48471
change-id: 20240924-ioctl_ficlone01_fix-88a17ef58543

Best regards,
-- 
Andrea Cervesato <andrea.cervesato@suse.com>


-- 
Mailing list info: https://lists.linux.it/listinfo/ltp

^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2024-10-08 11:51 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-02 12:22 [LTP] [PATCH v3 0/3] Fix ioctl_ficlone(range) failures on certain FS Andrea Cervesato
2024-10-02 12:22 ` [LTP] [PATCH v3 1/3] Filter mkfs version in tst_fs Andrea Cervesato
2024-10-04 14:00   ` Cyril Hrubis
2024-10-02 12:22 ` [LTP] [PATCH v3 2/3] Add minimum kernel requirement for FS setup Andrea Cervesato
2024-10-04 14:08   ` Cyril Hrubis
2024-10-08 11:34     ` Andrea Cervesato via ltp
2024-10-08 11:50       ` Cyril Hrubis
2024-10-02 12:22 ` [LTP] [PATCH v3 3/3] Setup minimal kernel for ioctl_clone(range) tests Andrea Cervesato

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox