Received: by 2002:a25:4158:0:0:0:0:0 with SMTP id o85csp273580yba; Mon, 20 May 2019 08:29:05 -0700 (PDT) X-Google-Smtp-Source: APXvYqwlyLMHzw4XUUABBbUMlVJ7yqrqdT8mNbIS9SObKtNlOGBif5JwkhgjSO1cYTIqBzCxjBGH X-Received: by 2002:a63:f10e:: with SMTP id f14mr75076268pgi.226.1558366145556; Mon, 20 May 2019 08:29:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1558366145; cv=none; d=google.com; s=arc-20160816; b=KZEPJCfuG34BJxqgz9g4CFRd4MZNeK99pswaW86E5+FlvqM+Z3cZtYXShovNmjNYek dq7iOH5SrPvRoq0ANoTkRqRxqC61XM3wFZh7tTV5SRQ3caHYGG+5/tDtTBBYOVzsXNjI POVQGX/y/PE/nSemXmW9uuiEc0nkB591CrxjuVKhQAA/Lk+hWnGKAwXEgUMk0iOKLZ8T IDkswOzvMqQQxm2MCzDhE4wZdO6HYBQPZu0UW8vOFdFxBm2Ic0inwRBMVjiodX5W9tEw Br4tXPUm/23U0AG82ZmT2VpJJL4ancqL5PF2vzlBjcRBD0rzARykyjRjsmdGDhK/+2mZ uCow== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=OnjIj4L8j6g4kP94EkA1TfYOirFD5+ztdup25T7ULt0=; b=bJQLE79LPRUtZ08uGYbh6liYBxQbxprvVHX10rJjfZ3DYsmhJEfZEEpa2nLM7udUMY +4mdEWQtudvgXBhNcn+v9wphOlS59Kh+4KzkAsxjy2xGKp7BKMvlps98pgpo8aWR4GqM Ex/vUzTce0CDjkkKf9xMT/HjGeZcp1c/XBEKbRrDE3Hi0ZpXicoMsCdZb1T3nbZDPTUz xm3uV8CyDgEtI9fjyaTDYjHOmofL2ZozbaSa8m9CR44bYdnHPFKQt5yAwfPJrtE2mZnf rIv7CFHKDdWw3N7R914mRWovZ5z6ZMvY0ZxTIcstXAaEkr+DDP/lAocHDlhZza1TooKk EW9Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="D5hSu/fQ"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b3si4121467pgt.583.2019.05.20.08.28.50; Mon, 20 May 2019 08:29:05 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b="D5hSu/fQ"; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2388709AbfETMXy (ORCPT + 99 others); Mon, 20 May 2019 08:23:54 -0400 Received: from mail.kernel.org ([198.145.29.99]:38592 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2388700AbfETMXx (ORCPT ); Mon, 20 May 2019 08:23:53 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 023A321019; Mon, 20 May 2019 12:23:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1558355032; bh=WupPEC+hMOVZof/t7zKnzKz3HLKKT+Ri07zHZ5ruEwI=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=D5hSu/fQFxK5em0xTVJVSc1xPBWKLA3F1zwQDx0HuDKA4nt//Y7XieWpw6NnVmN1X RY5Ge7A1dFy8hurGgIPGVNhrBGsDbMwHWuTsyp+vYLwSLZWq9IWgq8UFtL/uFB9dg6 HVTIi2T0Zj+MAJxk0Gz/OtWHxvlzente1JQ/Za0g= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Kirill Tkhai , Theodore Tso , Jan Kara , stable@kernel.org Subject: [PATCH 4.19 071/105] ext4: actually request zeroing of inode table after grow Date: Mon, 20 May 2019 14:14:17 +0200 Message-Id: <20190520115252.087715801@linuxfoundation.org> X-Mailer: git-send-email 2.21.0 In-Reply-To: <20190520115247.060821231@linuxfoundation.org> References: <20190520115247.060821231@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Kirill Tkhai commit 310a997fd74de778b9a4848a64be9cda9f18764a upstream. It is never possible, that number of block groups decreases, since only online grow is supported. But after a growing occured, we have to zero inode tables for just created new block groups. Fixes: 19c5246d2516 ("ext4: add new online resize interface") Signed-off-by: Kirill Tkhai Signed-off-by: Theodore Ts'o Reviewed-by: Jan Kara Cc: stable@kernel.org Signed-off-by: Greg Kroah-Hartman --- fs/ext4/ioctl.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/fs/ext4/ioctl.c +++ b/fs/ext4/ioctl.c @@ -977,7 +977,7 @@ mext_out: if (err == 0) err = err2; mnt_drop_write_file(filp); - if (!err && (o_group > EXT4_SB(sb)->s_groups_count) && + if (!err && (o_group < EXT4_SB(sb)->s_groups_count) && ext4_has_group_desc_csum(sb) && test_opt(sb, INIT_INODE_TABLE)) err = ext4_register_li_request(sb, o_group);