From mboxrd@z Thu Jan 1 00:00:00 1970 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 403A5C7EE2E for ; Mon, 12 Jun 2023 10:54:12 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236310AbjFLKyL (ORCPT ); Mon, 12 Jun 2023 06:54:11 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:55048 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S235882AbjFLKxu (ORCPT ); Mon, 12 Jun 2023 06:53:50 -0400 Received: from dfw.source.kernel.org (dfw.source.kernel.org [IPv6:2604:1380:4641:c500::1]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 2DFB4D17B for ; Mon, 12 Jun 2023 03:39:02 -0700 (PDT) Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by dfw.source.kernel.org (Postfix) with ESMTPS id 6B592614F0 for ; Mon, 12 Jun 2023 10:39:01 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 76B29C433D2; Mon, 12 Jun 2023 10:39:00 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1686566340; bh=bdNhbHHiZ1gjS7wN5u6aaOveVriureyTwf2YZIRJulE=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=pK3dPBq0x/Rb1l4aj5ZXH5m9mZ5Z5kinl0OGqKBId2wkxn/yG1GcInQiejWxW/RRg WWCv+cxO/Yytu386t3gXfe53WqQ0vBsMXk5v1J12bhq2e3VYfuJm50nMYtsAKUy65M Jsc0rdrsMxuAw4Bd52+ui4UUUWvGk8Xa/FZejXug= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Theodore Tso Subject: [PATCH 5.15 87/91] Revert "ext4: dont clear SB_RDONLY when remounting r/w until quota is re-enabled" Date: Mon, 12 Jun 2023 12:27:16 +0200 Message-ID: <20230612101705.761808117@linuxfoundation.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230612101702.085813286@linuxfoundation.org> References: <20230612101702.085813286@linuxfoundation.org> User-Agent: quilt/0.67 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: stable@vger.kernel.org From: Theodore Ts'o commit 1b29243933098cdbc31b579b5616e183b4275e2f upstream. This reverts commit a44be64bbecb15a452496f60db6eacfee2b59c79. Link: https://lore.kernel.org/r/653b3359-2005-21b1-039d-c55ca4cffdcc@gmail.com Signed-off-by: Theodore Ts'o Signed-off-by: Greg Kroah-Hartman --- fs/ext4/super.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) --- a/fs/ext4/super.c +++ b/fs/ext4/super.c @@ -5748,7 +5748,6 @@ static int ext4_remount(struct super_blo struct ext4_mount_options old_opts; ext4_group_t g; int err = 0; - int enable_rw = 0; #ifdef CONFIG_QUOTA int enable_quota = 0; int i, j; @@ -5949,7 +5948,7 @@ static int ext4_remount(struct super_blo if (err) goto restore_opts; - enable_rw = 1; + sb->s_flags &= ~SB_RDONLY; if (ext4_has_feature_mmp(sb)) { err = ext4_multi_mount_protect(sb, le64_to_cpu(es->s_mmp_block)); @@ -5996,9 +5995,6 @@ static int ext4_remount(struct super_blo if (!test_opt(sb, BLOCK_VALIDITY) && sbi->s_system_blks) ext4_release_system_zone(sb); - if (enable_rw) - sb->s_flags &= ~SB_RDONLY; - /* * Reinitialize lazy itable initialization thread based on * current settings