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 kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 6FECFC52D76 for ; Tue, 6 Aug 2024 17:33:39 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id E3E6C6B0083; Tue, 6 Aug 2024 13:33:38 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id DEEBC6B0085; Tue, 6 Aug 2024 13:33:38 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C90AE6B0088; Tue, 6 Aug 2024 13:33:38 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id AB2266B0083 for ; Tue, 6 Aug 2024 13:33:38 -0400 (EDT) Received: from smtpin09.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay04.hostedemail.com (Postfix) with ESMTP id 4D9401A0264 for ; Tue, 6 Aug 2024 17:33:38 +0000 (UTC) X-FDA: 82422517716.09.85EB960 Received: from galois.linutronix.de (Galois.linutronix.de [193.142.43.55]) by imf23.hostedemail.com (Postfix) with ESMTP id 6C16C14002B for ; Tue, 6 Aug 2024 17:33:36 +0000 (UTC) Authentication-Results: imf23.hostedemail.com; dkim=pass header.d=linutronix.de header.s=2020 header.b=pvhv4wmv; dkim=pass header.d=linutronix.de header.s=2020e header.b=P6epufFH; dmarc=pass (policy=none) header.from=linutronix.de; spf=pass (imf23.hostedemail.com: domain of tglx@linutronix.de designates 193.142.43.55 as permitted sender) smtp.mailfrom=tglx@linutronix.de ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1722965570; a=rsa-sha256; cv=none; b=B4QOUQ5AOfUqGCyLHjmMaDKxD3F7jVTgkOKCTGAYxqxcZxUMC2K3cgpolDLDtC5x3gjInn h2mmhkUhVunQJOwSMN11S2cFDECBENfZ0eETTHf3UsVEmqk9Kxz+xjuZhAuTUaWOpIbAFK xfkYf9tZM/vfNS7fQEEfsI0xdrTFCjs= ARC-Authentication-Results: i=1; imf23.hostedemail.com; dkim=pass header.d=linutronix.de header.s=2020 header.b=pvhv4wmv; dkim=pass header.d=linutronix.de header.s=2020e header.b=P6epufFH; dmarc=pass (policy=none) header.from=linutronix.de; spf=pass (imf23.hostedemail.com: domain of tglx@linutronix.de designates 193.142.43.55 as permitted sender) smtp.mailfrom=tglx@linutronix.de ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1722965570; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=lW3oZDM/W2dmHd7S9JZ3PSe6gHz+R+5ylzsov77+p/4=; b=hRc5kPuHOpgLTz09//f4xHzh2x42LacIceC/dy5TBmopEtOwTbRET7hmA+UNOodR4ApL55 J4bqbMPx3sE5O3BNsHVToVQILnYrmhdez1J+alDGyRfHqEzmyXjRdjp3jc+cfnJdzsSMNv hnztFsn2cfQaFp2Z9J25UA4elTGg6HU= From: Thomas Gleixner DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1722965614; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=lW3oZDM/W2dmHd7S9JZ3PSe6gHz+R+5ylzsov77+p/4=; b=pvhv4wmv94VM56UvsCebp/kuT37AUhDmwNpCPjpw1t5BWGJoU30bPphbZE9RbmLU6yVQyW N0UrTx/uBFyDtg9nsXcx2jVrKiQg+UtzzsaroNSaPWCi4M2m8h6WXe5iQ5/LtHH9bsL5HL 6UZNIgdbMo0G6N1oFM/lYsK4OwFeOUEgjWYN88PCM7W2NDOZ9Ck5CDCZMCZ+9/DRyMn/iz EWkL/f/P9l77HLTdmsSeogl3HJBPjL3OCrkToL5+J700fT7axVk/CssdQ3UC9JfqYOX3Gf SQEH35kLiZlhFsNQZeJUb7J12k84X0rLx7NxCKzmrxxiLW2JA9y8+lIyaJyuuA== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1722965614; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: in-reply-to:in-reply-to:references:references; bh=lW3oZDM/W2dmHd7S9JZ3PSe6gHz+R+5ylzsov77+p/4=; b=P6epufFH3NyZMxPwej0/sQTU1kLGxA4FlbL3F20x4CC5fCtTaWJXgZKjEoadaAplZazUw4 /Uyi5ZXx5BudxlCQ== To: Vlastimil Babka , Linus Torvalds , Guenter Roeck Cc: linux-kernel@vger.kernel.org, Linux-MM Subject: Re: [PATCH 6.10 000/809] 6.10.3-rc3 review In-Reply-To: <53b2e1f2-4291-48e5-a668-7cf57d900ecd@suse.cz> References: <20240731095022.970699670@linuxfoundation.org> <718b8afe-222f-4b3a-96d3-93af0e4ceff1@roeck-us.net> <53b2e1f2-4291-48e5-a668-7cf57d900ecd@suse.cz> Date: Tue, 06 Aug 2024 19:33:33 +0200 Message-ID: <87le194kuq.ffs@tglx> MIME-Version: 1.0 Content-Type: text/plain X-Rspamd-Queue-Id: 6C16C14002B X-Rspam-User: X-Rspamd-Server: rspam05 X-Stat-Signature: 8hwqhjq6udk5pfredir5t5pqeprh314i X-HE-Tag: 1722965616-913292 X-HE-Meta: U2FsdGVkX18xF2Ogt2/6PPnAQ5gPrpTyMujO/A311rs6ZYbb3BeZBzq3Otr36sGyTku8XrSHAiRq1bU04Ojsh5ft/dKtX2p4PRhx+sXXMJU1123C2LKPNSHoNlSHUBs1kbF98fDO83hoRijsP8zv9QWBkckG/B86ErZ0EZes/GjqxVvZCYo1CduIYcm+jU7EQHCaG3q0I74UUiPUpzuq9LnI3/pv/SxpwaszIrH9DONBDRe0DbS5Yu84eGId4Q7KCUABKjjFkfRPlF5ZR0oFVpCr3sdt+V+U4EsosSNfOw8wuPQCxn9K03/vYkcDvikus80R8z1bLS9T2x189GvfIlcVika/ORPmCTJQo6YhRGfTuE4AC3Xy7cV2XUDtA/TM5FeCgELZFtmI+x2Tc/0PTiKR+MhWWVsldKESMx/vt00hbodFZMbXwAXqtlJ9pCgcS2aS/I26Mqg7gCeYeVOkaoG+ChgSq9D9pC8BnXWKewfMpDs7CNPDo/O699KHBkVlzdCeXfZAxGj7tzfNmfVfPGZFEOR4iivu0xdGJyEDHPCLxiwrTiSyIxqv7FvgiWO+9YrZKRAjsUbarOFJS/YW2aSlhBBzEYBrl7QBqeHt/BAUNXedOnotDaK0C2mOkVCCH4NoofMqU+pLBxBBKLY0vzK89REMKpPbVg9rctJfY0jIpzpYvZ6iHPPfb90E7gZql32hvBCnIIV76Y2dqWyI0q1ur1F62p/6O79X4vNSsKTO03oRZMcRpCIMevzvmGEl5EOLNnmXFUo9NskCWRnDBrQ7vnTyAMYP7wumTcUaWrgR0jt+oS6g5xmOdzYrr07cq61aq8vG9ub2tuglWpH+bBG/KPwXBKmihpL8osGIi+wEPoXfWqEodElqbChFQu7D7AoMSdl4zlUBYPmJ0DOGNCvsa0kaH1KdRaH5Ly+jmcQMkfz+y/Zd5ouqryuqbHBjbOwDRyQFddnIWZwQEXR 6QRFB7Em y6nuJaIFi+oHNSmrphqS7eX82enlZW2AgXIYybpUGEdn/c1s3RwnfsE1yxowK2+um5LS8eTrzW3csw0QCM+mbqJMbGPTjop/+JA6uZRdmddJB0gmMPXT5BNEC4rbj8ooRso79 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: List-Subscribe: List-Unsubscribe: On Tue, Aug 06 2024 at 13:02, Vlastimil Babka wrote: > On 8/6/24 04:40, Linus Torvalds wrote: > It looks like maxobj calculation is bogus, would be useful to see what values it > calculates from. I'm attaching a diff, but maybe it will also hide the issue... It does hide it :( > If someone has a /proc/slabinfo from a working boot with otherwise same config > it might be also enough to guess what values should be expected there, > at least the s-size. > > objects=21 vs 25 also seem odd though > > used=5 with used=6 in the first two also suggests we already passed this code > successfully for creating a number of kmalloc caches and only then it started > failing, that's also weird. I added a printk() to check_slab() and on the non-failing boot this looks like: [ 0.000000] c 000000004017b0f8 c 0000000041ed0000 objects 21 max 21 order 0 size 192, inuse 2 [ 0.000000] c 000000004017b1c8 c 0000000041ed0080 objects 25 max 25 order 1 size 320, inuse 1 [ 0.000000] c 0000000043402010 c 0000000041ed0080 objects 25 max 25 order 1 size 320, inuse 2 [ 0.000000] c 0000000043402010 c 0000000041ed0080 objects 25 max 25 order 1 size 320, inuse 3 [ 0.000000] c 0000000043402150 c 0000000041ed0000 objects 21 max 21 order 0 size 192, inuse 3 [ 0.000000] c 0000000043402010 c 0000000041ed0080 objects 25 max 25 order 1 size 320, inuse 4 [ 0.000000] c 0000000043402150 c 0000000041ed0000 objects 21 max 21 order 0 size 192, inuse 4 [ 0.000000] c 0000000043402010 c 0000000041ed0080 objects 25 max 25 order 1 size 320, inuse 5 [ 0.000000] c 0000000043402150 c 0000000041ed0000 objects 21 max 21 order 0 size 192, inuse 5 [ 0.000000] c 0000000043402010 c 0000000041ed0080 objects 25 max 25 order 1 size 320, inuse 6 [ 0.000000] c 0000000043402150 c 0000000041ed0000 objects 21 max 21 order 0 size 192, inuse 6 I did some more experiments to figure out why adding or removing text cures it. The minimal change which makes it boot again is: asmlinkage __visible void __softirq_entry __do_softirq(void) { + current->flags &= ~PF_MEMALLOC; handle_softirqs(false); } That results in the following System.map delta: --- ../upstream.txt 2024-08-06 16:52:49.746528992 +0200 +++ ../build-misc/System.map 2024-08-06 19:02:32.652201977 +0200 @@ -47600,15 +47600,15 @@ 0000000041218c30 T __do_softirq 0000000041218c30 T __irqentry_text_end 0000000041218c30 T __softirqentry_text_start -0000000041218c70 T $$divoI -0000000041218c70 T __softirqentry_text_end -00000000412190d0 T $$divI_2 -00000000412190d0 T $$divide_by_constant -00000000412190e0 T $$divI_4 -00000000412190f0 T $$divI_8 -0000000041219100 T $$divI_16 -00000000412192d8 T $$divI_17 -000000004121930c T $$divU_17 +0000000041218c80 T $$divoI +0000000041218c80 T __softirqentry_text_end +00000000412190e0 T $$divI_2 +00000000412190e0 T $$divide_by_constant +00000000412190f0 T $$divI_4 +0000000041219100 T $$divI_8 +0000000041219110 T $$divI_16 +00000000412192e8 T $$divI_17 +000000004121931c T $$divU_17 000000004121a000 D __start_opd 000000004121a000 D _etext 000000004121a000 D _sdata So this change adds 16 bytes to __softirq() which moves the division functions up by 16 bytes. That's all it takes to make the stupid go away.... I wonder whether this is some qemu stupid. Thanks, tglx