On Mon, Jun 21, 2021 at 12:48:51PM -0400, Theodore Ts'o wrote: > ext4/048 will fail when running on older kernels that don't support > the filename wipe feature. The journal checkpoint ioctl is a related I think that depends on if we treat it as a feature or a bugfix. We should let the test fail on old kernels if that's a bugfix, and skip the test if it's a feature. Apparently, we take it as a feature here. > feature, and landed just a little bit after filename wipe feature, so > use support for the journal checkpoint ioctl as a proxy for support > for the filename wipe feature. This seems fragile, they're related features but not always bounded together, I think it's possible for distros developers decide to backport only one of the features (though quite unlikely). Is it worth to introduce features sysfs entry for journal checkpoint and filename wipe in ext4? In fstests' point of view, it's great to have such entries that could be checked. If it's not worth it, I think the "feature proxy" way is acceptable, given that the two features are closely related and aimed to the same security issue. Thanks, Eryu > > Without this change, this test will fail when tesing 5.10, 5.4, and > other LTS kernels. > > Signed-off-by: Theodore Ts'o <tytso@xxxxxxx> > Cc: Leah Rumancik <leah.rumancik@xxxxxxxxx> > --- > tests/ext4/048 | 8 ++++++++ > 1 file changed, 8 insertions(+) > > diff --git a/tests/ext4/048 b/tests/ext4/048 > index 51189618..35e6aa7f 100755 > --- a/tests/ext4/048 > +++ b/tests/ext4/048 > @@ -93,6 +93,14 @@ _scratch_mkfs_sized $((128 * 1024 * 1024)) >> $seqres.full 2>&1 > # create scratch dir for testing > # create some files with no name a substr of another name so we can grep later > _scratch_mount >> $seqres.full 2>&1 > + > +# Use the presence of the journal checkpoint ioctl as a proxy of filename > +# wipe being supported > +if test -x $here/src/checkpoint_journal && \ > + ! $here/src/checkpoint_journal $SCRATCH_MNT --dry-run ; then > + _notrun "filename wipe not supported" > +fi > + > blocksize="$(_get_block_size $SCRATCH_MNT)" > mkdir $testdir > file_num=1 > -- > 2.31.0