Received: by 2002:ad5:4acb:0:0:0:0:0 with SMTP id n11csp495646imw; Wed, 13 Jul 2022 02:29:11 -0700 (PDT) X-Google-Smtp-Source: AGRyM1ux7Ieku0UVXyN4H/X6I+mFYBKEUWAM3pwgYB7vaNn65bP0j6isjGKU3iv8yosYT+YvgNNu X-Received: by 2002:a17:902:cecb:b0:16c:40a8:88ff with SMTP id d11-20020a170902cecb00b0016c40a888ffmr2213293plg.33.1657704550959; Wed, 13 Jul 2022 02:29:10 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1657704550; cv=none; d=google.com; s=arc-20160816; b=Ri035XqQ2QkKW2wP1rv4eAJ2Y3YHI6Owit0BniXvss32sKkbQ+6bW23dHGG5fSuNPI Hr7+OoWGSJ1ZA+QpAKm+u3kwskfh8+pjdiG15JkPKqRzfV0gFr6m8cR1/h3GRLk4Y3FM S+lbRzq9Y3iXuj+bF2EQ/vUNsT2ZwKhTOaSPyn5CPF/EsubSJCeVipXaTfGYqV4yADKF GKqLVWvjl2hB+IRapDGnadfl+h0dCBejI7j/xat8ZM/RyV1XDtCqA3jNIShMTMOOQZEg PAzV2HXPIaT5nmgsLhiaR7M44/fOLr29q6+KJ9LGTzJtdY0fTw9gc0nTV+9MX/vc5s0u NdTg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from; bh=qMOL1/9Tb6tL1yb1qdPHHVmK9hfgp/1YyQHYSaz4h5E=; b=Km2pLlh24Nn9U62e61L9Jruju0ZdCqqKcBO6Rj10o5BaV9Bb1N+Vhp5driFZ+qrd8s Hwdch+T2O71IRrkAM2mbyvrMVK+LLdsIZtvvF/PnvrUpXJCvAbeTK/68wjSz2myHERAe 4bdKnlEdtx5EJeBM4uB1Drar2knKsmNjpgJW2VwoqBD2fjcyks8PfjJjl0eG75rkG8PM PMFE5zw/Eg375YYEzDDqvCYAZY5iz781g3hYx4dny9m5oTKYKckFTKC5dDVLGE5WVM6S XU5f4ShhVh5lzNQF9llAfLufLv80X0mBeMw9Ix/Rhai3h+Vew/Pu/UIZkRxekA7wW1Kb t1PA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id x186-20020a6386c3000000b0041678569fcbsi6636631pgd.503.2022.07.13.02.28.56; Wed, 13 Jul 2022 02:29:10 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236026AbiGMJQx (ORCPT + 99 others); Wed, 13 Jul 2022 05:16:53 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:32788 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235829AbiGMJQn (ORCPT ); Wed, 13 Jul 2022 05:16:43 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 808A3EF9F2; Wed, 13 Jul 2022 02:16:40 -0700 (PDT) Received: from dggemv704-chm.china.huawei.com (unknown [172.30.72.56]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4LjX4C27znzhZ8Q; Wed, 13 Jul 2022 17:14:03 +0800 (CST) Received: from kwepemm600010.china.huawei.com (7.193.23.86) by dggemv704-chm.china.huawei.com (10.3.19.47) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Wed, 13 Jul 2022 17:16:38 +0800 Received: from huawei.com (10.175.127.227) by kwepemm600010.china.huawei.com (7.193.23.86) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2375.24; Wed, 13 Jul 2022 17:16:37 +0800 From: Sun Ke To: CC: , , Subject: [PATCH v3 2/2] ext4: set 256 blocks in a block group then apply io pressure Date: Wed, 13 Jul 2022 17:28:59 +0800 Message-ID: <20220713092859.3881376-3-sunke32@huawei.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20220713092859.3881376-1-sunke32@huawei.com> References: <20220713092859.3881376-1-sunke32@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.127.227] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To kwepemm600010.china.huawei.com (7.193.23.86) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-4.2 required=5.0 tests=BAYES_00,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_PASS,T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org Set 256 blocks in a block group, then inject I/O pressure, it will trigger off kernel BUG in ext4_mb_mark_diskspace_used. Regression test for commit a08f789d2ab5 ext4: fix bug_on ext4_mb_use_inode_pa. Signed-off-by: Sun Ke --- tests/ext4/058 | 33 +++++++++++++++++++++++++++++++++ tests/ext4/058.out | 2 ++ 2 files changed, 35 insertions(+) create mode 100755 tests/ext4/058 create mode 100644 tests/ext4/058.out diff --git a/tests/ext4/058 b/tests/ext4/058 new file mode 100755 index 00000000..ddc96f30 --- /dev/null +++ b/tests/ext4/058 @@ -0,0 +1,33 @@ +#! /bin/bash +# SPDX-License-Identifier: GPL-2.0 +# Copyright (c) 2022 HUAWEI. All Rights Reserved. +# +# FS QA Test 058 +# +# Set 256 blocks in a block group, then inject I/O pressure, +# it will trigger off kernel BUG in ext4_mb_mark_diskspace_used +# +# Regression test for commit +# a08f789d2ab5 ext4: fix bug_on ext4_mb_use_inode_pa +# +. ./common/preamble +_begin_fstest auto quick + +# real QA test starts here + +_supported_fs ext4 +_fixed_by_kernel_commit a08f789d2ab5 \ + "ext4: fix bug_on ext4_mb_use_inode_pa" +_require_scratch + +# set 256 blocks in a block group +_scratch_mkfs -g 256 >> $seqres.full 2>&1 || _fail "mkfs failed" +_scratch_mount + +$FSSTRESS_PROG -d $SCRATCH_MNT/stress -n 1000 >> $seqres.full 2>&1 + +echo "Silence is golden" + +# success, all done +status=0 +exit diff --git a/tests/ext4/058.out b/tests/ext4/058.out new file mode 100644 index 00000000..fb5ca60b --- /dev/null +++ b/tests/ext4/058.out @@ -0,0 +1,2 @@ +QA output created by 058 +Silence is golden -- 2.13.6