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 E639FC7618D for ; Thu, 16 Mar 2023 11:29:57 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229970AbjCPL32 (ORCPT ); Thu, 16 Mar 2023 07:29:28 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:43964 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229852AbjCPL3X (ORCPT ); Thu, 16 Mar 2023 07:29:23 -0400 Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AE5B3B5B57; Thu, 16 Mar 2023 04:29:22 -0700 (PDT) Received: from dggpeml500021.china.huawei.com (unknown [172.30.72.54]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4PclMJ5pl0znWs8; Thu, 16 Mar 2023 19:26:20 +0800 (CST) Received: from huawei.com (10.175.127.227) by dggpeml500021.china.huawei.com (7.185.36.21) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.21; Thu, 16 Mar 2023 19:29:19 +0800 From: Baokun Li To: CC: , , , , , , , , Subject: [PATCH 1/3] ext4: correct error ctx->mask_s_##name in ctx_set_##name Date: Thu, 16 Mar 2023 19:28:30 +0800 Message-ID: <20230316112832.2711783-2-libaokun1@huawei.com> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20230316112832.2711783-1-libaokun1@huawei.com> References: <20230316112832.2711783-1-libaokun1@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: dggems703-chm.china.huawei.com (10.3.19.180) To dggpeml500021.china.huawei.com (7.185.36.21) X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org We should only save the flag to be cleared in ctx->mask_s_##name. Fixes: 6e47a3cc68fc ("ext4: get rid of super block and sbi from handle_mount_ops()") Signed-off-by: Baokun Li --- fs/ext4/super.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ext4/super.c b/fs/ext4/super.c index f43e526112ae..5b4a323c218b 100644 --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -2023,7 +2023,7 @@ static int ext4_parse_test_dummy_encryption(const struct fs_parameter *param, static inline void ctx_set_##name(struct ext4_fs_context *ctx, \ unsigned long flag) \ { \ - ctx->mask_s_##name |= flag; \ + ctx->mask_s_##name &= ~flag; \ ctx->vals_s_##name |= flag; \ } -- 2.31.1