linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
To: linux-kernel@vger.kernel.org
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	stable@vger.kernel.org, Stefan Wahren <stefan.wahren@i2se.com>,
	Ojaswin Mujoo <ojaswin@linux.ibm.com>,
	stable@kernel.org, Jan Kara <jack@suse.cz>,
	Theodore Tso <tytso@mit.edu>
Subject: [PATCH 4.9 30/30] ext4: make directory inode spreading reflect flexbg size
Date: Mon, 26 Sep 2022 12:12:01 +0200	[thread overview]
Message-ID: <20220926100737.224531328@linuxfoundation.org> (raw)
In-Reply-To: <20220926100736.153157100@linuxfoundation.org>

From: Jan Kara <jack@suse.cz>

commit 613c5a85898d1cd44e68f28d65eccf64a8ace9cf upstream.

Currently the Orlov inode allocator searches for free inodes for a
directory only in flex block groups with at most inodes_per_group/16
more directory inodes than average per flex block group. However with
growing size of flex block group this becomes unnecessarily strict.
Scale allowed difference from average directory count per flex block
group with flex block group size as we do with other metrics.

Tested-by: Stefan Wahren <stefan.wahren@i2se.com>
Tested-by: Ojaswin Mujoo <ojaswin@linux.ibm.com>
Cc: stable@kernel.org
Link: https://lore.kernel.org/all/0d81a7c2-46b7-6010-62a4-3e6cfc1628d6@i2se.com/
Signed-off-by: Jan Kara <jack@suse.cz>
Link: https://lore.kernel.org/r/20220908092136.11770-3-jack@suse.cz
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
---
 fs/ext4/ialloc.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- a/fs/ext4/ialloc.c
+++ b/fs/ext4/ialloc.c
@@ -511,7 +511,7 @@ static int find_group_orlov(struct super
 		goto fallback;
 	}
 
-	max_dirs = ndirs / ngroups + inodes_per_group / 16;
+	max_dirs = ndirs / ngroups + inodes_per_group*flex_size / 16;
 	min_inodes = avefreei - inodes_per_group*flex_size / 4;
 	if (min_inodes < 1)
 		min_inodes = 1;



  parent reply	other threads:[~2022-09-26 10:17 UTC|newest]

Thread overview: 42+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-09-26 10:11 [PATCH 4.9 00/30] 4.9.330-rc1 review Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 01/30] parisc: ccio-dma: Add missing iounmap in error path in ccio_probe() Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 02/30] cifs: dont send down the destination address to sendmsg for a SOCK_STREAM Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 03/30] drm/vc4: crtc: Use an union to store the page flip callback Greg Kroah-Hartman
2022-09-26 10:38   ` Pavel Machek
2022-09-26 16:11     ` Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 04/30] video: fbdev: skeletonfb: Fix syntax errors in comments Greg Kroah-Hartman
2022-09-26 10:28   ` Pavel Machek
2022-09-26 13:46     ` Bagas Sanjaya
2022-09-26 16:06     ` Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 05/30] video: fbdev: intelfb: Use aperture size from pci_resource_len Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 06/30] video: fbdev: pxa3xx-gcu: Fix integer overflow in pxa3xx_gcu_write Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 07/30] video: fbdev: simplefb: Check before clk_put() not needed Greg Kroah-Hartman
2022-09-26 10:29   ` Pavel Machek
2022-09-26 16:09     ` Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 08/30] mips: lantiq: falcon: Fix refcount leak bug in sysctrl Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 09/30] mips: lantiq: xway: " Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 10/30] mips/pic32/pic32mzda: Fix refcount leak bugs Greg Kroah-Hartman
2022-09-26 10:40   ` Pavel Machek
2022-09-26 16:08     ` Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 11/30] mips: lantiq: Add missing of_node_put() in irq.c Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 12/30] arm: mach-spear: Add missing of_node_put() in time.c Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 13/30] wifi: mac80211: Fix UAF in ieee80211_scan_rx() Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 14/30] USB: core: Fix RST error in hub.c Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 15/30] ALSA: hda/tegra: set depop delay for tegra Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 16/30] ALSA: hda: add Intel 5 Series / 3400 PCI DID Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 17/30] mm/slub: fix to return errno if kmalloc() fails Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 18/30] netfilter: nf_conntrack_sip: fix ct_sip_walk_headers Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 19/30] netfilter: nf_conntrack_irc: Tighten matching on DCC message Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 20/30] ipvlan: Fix out-of-bound bugs caused by unset skb->mac_header Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 21/30] net: team: Unsync device addresses on ndo_stop Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 22/30] MIPS: lantiq: export clk_get_io() for lantiq_wdt.ko Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 23/30] can: gs_usb: gs_can_open(): fix race dev->can.state condition Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 24/30] perf kcore_copy: Do not check /proc/modules is unchanged Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 25/30] net: sunhme: Fix packet reception for len < RX_COPY_THRESHOLD Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 26/30] serial: Create uart_xmit_advance() Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 27/30] serial: tegra: Use uart_xmit_advance(), fixes icount.tx accounting Greg Kroah-Hartman
2022-09-26 10:11 ` [PATCH 4.9 28/30] s390/dasd: fix Oops in dasd_alias_get_start_dev due to missing pavgroup Greg Kroah-Hartman
2022-09-26 10:12 ` [PATCH 4.9 29/30] Drivers: hv: Never allocate anything besides framebuffer from framebuffer memory region Greg Kroah-Hartman
2022-09-26 10:12 ` Greg Kroah-Hartman [this message]
2022-09-26 13:35 ` [PATCH 4.9 00/30] 4.9.330-rc1 review Pavel Machek
2022-09-27  1:02 ` Shuah Khan

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20220926100737.224531328@linuxfoundation.org \
    --to=gregkh@linuxfoundation.org \
    --cc=jack@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=ojaswin@linux.ibm.com \
    --cc=stable@kernel.org \
    --cc=stable@vger.kernel.org \
    --cc=stefan.wahren@i2se.com \
    --cc=tytso@mit.edu \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).