Received: by 2002:a05:7412:8521:b0:e2:908c:2ebd with SMTP id t33csp287831rdf; Thu, 2 Nov 2023 23:58:15 -0700 (PDT) X-Google-Smtp-Source: AGHT+IFobFOkjVGqXKLHEFn64l2sMP8svwO0LQvcP8AJFJJNcCRneXfQl0/cwnS6KMNlCFhh9zWz X-Received: by 2002:a05:6870:1397:b0:1ef:aba1:1995 with SMTP id 23-20020a056870139700b001efaba11995mr14996942oas.59.1698994695660; Thu, 02 Nov 2023 23:58:15 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1698994695; cv=none; d=google.com; s=arc-20160816; b=oLbeMA7xSjB6ZScKGDZ/v/p3LxbY2OGukcNvb3uwVJ9sYGteA/UR1uEZc9yh+JHFU0 1BeB8Ig5SWwEWevXhWfCViDHIUtzwHRtfqnuDjkxzcJtnTtu+8sDYFVIjxX8ZOPZ6/oi hkWU1UE2O2iTzkpTPn+QCbNDnijqoC532UVlD7TvZmClyd04E5GsqU23hcEJ5/97nbJl sWGS39NI0wXmk8PwRPrybLSSvhXFynkhF49wPifNgTpQ4hseJwbJ64ugAMfoFsGiCEXd eSy7cQ4/6VNytsLL8vdRmQuQhiFb7WME1mSi5rx1V0yaJdoF/QLpFiha00uPaRYgv7Nx O6SA== 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=fLMa/qH+hjMZnykImPDA+vrYEs9YFDBZq1LUyYbM8QE=; fh=FsznnDxpmef1vC1z7PHIgrdOV6pY0Temw/oyToZsikg=; b=F+OojIZm9xoB7w/Vbh24xtEwz/fiKvh5H/8lps6AjYY38FCbnXSviylXehoxT6LHut RnuoO9my6fRhotrQOZzwNQF8VwcBRpCcqMZQpgS72S+RvWIGJUYCZHikQA6WuTy+rfcl /tSErYe5oCuXESZlTcE/ftINlh06dt97Um0h5LifYcV1t91e5OjtZJkuTt0zGbFyyruR feJCRoEcQx4jnaeHFne9rcRwsz9Ml5y5gkIpJWEa/qy62hkr5nkp/7UB/K7J380v0+Px ilNM3ceVSTLsygesng/j59mdYm5M2ha8F1ayqMcwvVDvuHgx7I5PezRoho/zOwN+v/vK QiTg== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::3:7 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 snail.vger.email (snail.vger.email. [2620:137:e000::3:7]) by mx.google.com with ESMTPS id v202-20020a6361d3000000b005b9083b81f5si995911pgb.487.2023.11.02.23.58.15 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 02 Nov 2023 23:58:15 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) client-ip=2620:137:e000::3:7; Authentication-Results: mx.google.com; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 2620:137:e000::3:7 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=huawei.com Received: from out1.vger.email (depot.vger.email [IPv6:2620:137:e000::3:0]) by snail.vger.email (Postfix) with ESMTP id 89ABA809501F; Thu, 2 Nov 2023 23:58:14 -0700 (PDT) X-Virus-Status: Clean X-Virus-Scanned: clamav-milter 0.103.10 at snail.vger.email Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232710AbjKCG6O (ORCPT + 99 others); Fri, 3 Nov 2023 02:58:14 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:56062 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232693AbjKCG6J (ORCPT ); Fri, 3 Nov 2023 02:58:09 -0400 Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2F7DEE3 for ; Thu, 2 Nov 2023 23:58:07 -0700 (PDT) Received: from kwepemm000013.china.huawei.com (unknown [172.30.72.57]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4SMBKZ739JzMmQ7; Fri, 3 Nov 2023 14:53:38 +0800 (CST) Received: from huawei.com (10.175.104.67) by kwepemm000013.china.huawei.com (7.193.23.81) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.31; Fri, 3 Nov 2023 14:58:01 +0800 From: Zhihao Cheng To: , CC: , , Subject: [PATCH 3/5] jbd2: Remove unused 'JBD2_CHECKPOINT_IO_ERROR' and 'j_atomic_flags' Date: Fri, 3 Nov 2023 22:52:48 +0800 Message-ID: <20231103145250.2995746-4-chengzhihao1@huawei.com> X-Mailer: git-send-email 2.39.2 In-Reply-To: <20231103145250.2995746-1-chengzhihao1@huawei.com> References: <20231103145250.2995746-1-chengzhihao1@huawei.com> MIME-Version: 1.0 Content-Transfer-Encoding: 7BIT Content-Type: text/plain; charset=US-ASCII X-Originating-IP: [10.175.104.67] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To kwepemm000013.china.huawei.com (7.193.23.81) X-CFilter-Loop: Reflected X-Spam-Status: No, score=-2.3 required=5.0 tests=BAYES_00,DATE_IN_FUTURE_06_12, RCVD_IN_DNSWL_MED,RCVD_IN_MSPIKE_H5,RCVD_IN_MSPIKE_WL,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 X-Greylist: Sender passed SPF test, not delayed by milter-greylist-4.6.4 (snail.vger.email [0.0.0.0]); Thu, 02 Nov 2023 23:58:14 -0700 (PDT) Since 'JBD2_CHECKPOINT_IO_ERROR' and j_atomic_flags' are not useful anymore after fs dev's errseq is imported into jbd2, just remove them. Signed-off-by: Zhihao Cheng --- fs/jbd2/checkpoint.c | 11 ----------- include/linux/jbd2.h | 11 ----------- 2 files changed, 22 deletions(-) diff --git a/fs/jbd2/checkpoint.c b/fs/jbd2/checkpoint.c index 118699fff2f9..1c97e64c4784 100644 --- a/fs/jbd2/checkpoint.c +++ b/fs/jbd2/checkpoint.c @@ -556,7 +556,6 @@ int __jbd2_journal_remove_checkpoint(struct journal_head *jh) struct transaction_chp_stats_s *stats; transaction_t *transaction; journal_t *journal; - struct buffer_head *bh = jh2bh(jh); JBUFFER_TRACE(jh, "entry"); @@ -569,16 +568,6 @@ int __jbd2_journal_remove_checkpoint(struct journal_head *jh) JBUFFER_TRACE(jh, "removing from transaction"); - /* - * If we have failed to write the buffer out to disk, the filesystem - * may become inconsistent. We cannot abort the journal here since - * we hold j_list_lock and we have to be careful about races with - * jbd2_journal_destroy(). So mark the writeback IO error in the - * journal here and we abort the journal later from a better context. - */ - if (buffer_write_io_error(bh)) - set_bit(JBD2_CHECKPOINT_IO_ERROR, &journal->j_atomic_flags); - __buffer_unlink(jh); jh->b_cp_transaction = NULL; percpu_counter_dec(&journal->j_checkpoint_jh_count); diff --git a/include/linux/jbd2.h b/include/linux/jbd2.h index 15798f88ade4..bdde776b90d9 100644 --- a/include/linux/jbd2.h +++ b/include/linux/jbd2.h @@ -755,11 +755,6 @@ struct journal_s */ unsigned long j_flags; - /** - * @j_atomic_flags: Atomic journaling state flags. - */ - unsigned long j_atomic_flags; - /** * @j_errno: * @@ -1403,12 +1398,6 @@ JBD2_FEATURE_INCOMPAT_FUNCS(fast_commit, FAST_COMMIT) #define JBD2_JOURNAL_FLUSH_VALID (JBD2_JOURNAL_FLUSH_DISCARD | \ JBD2_JOURNAL_FLUSH_ZEROOUT) -/* - * Journal atomic flag definitions - */ -#define JBD2_CHECKPOINT_IO_ERROR 0x001 /* Detect io error while writing - * buffer back to disk */ - /* * Function declarations for the journaling transaction and buffer * management -- 2.39.2