From patchwork Tue Jun 28 18:25:43 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Theodore Ts'o X-Patchwork-Id: 12898704 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id C4A43C433EF for ; Tue, 28 Jun 2022 18:25:58 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S233384AbiF1SZ5 (ORCPT ); Tue, 28 Jun 2022 14:25:57 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:34140 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232422AbiF1SZz (ORCPT ); Tue, 28 Jun 2022 14:25:55 -0400 Received: from outgoing.mit.edu (outgoing-auth-1.mit.edu [18.9.28.11]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2CB862126D for ; Tue, 28 Jun 2022 11:25:54 -0700 (PDT) Received: from cwcc.thunk.org (pool-173-48-118-63.bstnma.fios.verizon.net [173.48.118.63]) (authenticated bits=0) (User authenticated as tytso@ATHENA.MIT.EDU) by outgoing.mit.edu (8.14.7/8.12.4) with ESMTP id 25SIPneH025907 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-GCM-SHA384 bits=256 verify=NOT); Tue, 28 Jun 2022 14:25:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=mit.edu; s=outgoing; t=1656440750; bh=pOckgTVCuMooqwl2VCGxJiy8hryQhb6ybvoL/Ts85ro=; h=From:To:Cc:Subject:Date:In-Reply-To:References; b=bnS0jQ4RzoRD38XKfppq6qddqig6t59q7CjdlXGiqPQQ1Emr0kFRZOcBx58gmk1X7 5n7/CNhS4vAk9tM2XkP1R9pF1ZKKWhKqrQUp57QUDqaaO6TIqkSh/6qvMJMNm6EyKP M0Do/1qsP/LDY/9pWDcIMrH28ADiv2dpmB0YNlnJHHzZiPHwS1+rqbi1s6jg4wolgs 9NxggxBeklzPGmcapXm/BT6q49WtjNEEYvj57OrQcB0GddM2LtOCZ/4L0+Wbicj/js zhriXbd6kxGF35V7Iakm6DK3FYeT4UzmnUitZLHW8KNuIfFfth1wuJyfW/MuCLnXk3 rFnBFylAJpCEw== Received: by cwcc.thunk.org (Postfix, from userid 15806) id 81DEE15C4317; Tue, 28 Jun 2022 14:25:49 -0400 (EDT) From: "Theodore Ts'o" To: fstests@vger.kernel.org Cc: "Theodore Ts'o" , Zorro Lang Subject: [PATCH 4/6] ext4/054: skip test if the dax mount option is enabled Date: Tue, 28 Jun 2022 14:25:43 -0400 Message-Id: <20220628182545.1834145-5-tytso@mit.edu> X-Mailer: git-send-email 2.31.0 In-Reply-To: <20220628182545.1834145-1-tytso@mit.edu> References: <20220628182545.1834145-1-tytso@mit.edu> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: fstests@vger.kernel.org The ext4/054 test explicitly creates a file system with a 1k blocksize. This can't possibly work on if the dax mount option is enabled, so change ext4/054 to use _scratch_mkfs_blocksized, and and a check to _scratch_mkfs_blocksized to _notrun the test if the block size is less than the page size. Also remove an unnecessary _require_test declaration since this test does not use the test device. Signed-off-by: Theodore Ts'o Reviewed-by: Zorro Lang --- common/rc | 3 +++ tests/ext4/054 | 5 ++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/common/rc b/common/rc index 9378ff26..3014f5fc 100644 --- a/common/rc +++ b/common/rc @@ -1220,6 +1220,9 @@ _scratch_mkfs_blocksized() if ! [[ $blocksize =~ $re ]] ; then _notrun "error: _scratch_mkfs_sized: block size \"$blocksize\" not an integer." fi + if [ $blocksize -lt $(get_page_size) ]; then + _exclude_scratch_mount_option dax + fi case $FSTYP in btrfs) diff --git a/tests/ext4/054 b/tests/ext4/054 index 9a11719f..e23acbb1 100755 --- a/tests/ext4/054 +++ b/tests/ext4/054 @@ -19,7 +19,6 @@ _begin_fstest auto quick dangerous_fuzzers # real QA test starts here _supported_fs ext4 -_require_test _require_scratch_nocheck _require_xfs_io_command "falloc" _require_xfs_io_command "pwrite" @@ -28,8 +27,8 @@ _require_xfs_io_command "fpunch" _require_command "$DEBUGFS_PROG" debugfs # In order to accurately construct the damaged extent in the following -# test steps, the blocksize is set to 1024 here -_scratch_mkfs "-b 1024" > $seqres.full 2>&1 +# test steps, the block size is set to 1024 here +_scratch_mkfs_blocksized 1024 >> $seqres.full 2>&1 _scratch_mount TEST_FILE="${SCRATCH_MNT}/testfile"