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 2FD66C352A1 for ; Sun, 27 Nov 2022 23:11:16 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 8433F6B0072; Sun, 27 Nov 2022 18:11:15 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id 7CC3F6B0073; Sun, 27 Nov 2022 18:11:15 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 6939E6B0074; Sun, 27 Nov 2022 18:11:15 -0500 (EST) 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 55DCC6B0072 for ; Sun, 27 Nov 2022 18:11:15 -0500 (EST) Received: from smtpin29.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id 2B3BE402E6 for ; Sun, 27 Nov 2022 23:11:15 +0000 (UTC) X-FDA: 80180770110.29.495A507 Received: from smtp-out1.suse.de (smtp-out1.suse.de [195.135.220.28]) by imf26.hostedemail.com (Postfix) with ESMTP id 82E8014000F for ; Sun, 27 Nov 2022 23:11:14 +0000 (UTC) Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by smtp-out1.suse.de (Postfix) with ESMTPS id 1895721B95; Sun, 27 Nov 2022 23:11:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1669590673; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=lq+hxk2jZLq7sWjpYaRCMKOHOLgy8Wwlbt7cndUUYuU=; b=bFAgYyVJLutsJ3njue2hOhs/rgjP0WZ7Yn/10rMyL+wzjqDh6NmrqcxZ5/w0KB0XCRVTa7 Bg6HQYJjNftkG+lbHhejipO34cFgk0uNm1NW3OKRFoH1ZpQIhaApc3XUWYku5+1SmCb4JJ B4/8FHifmitpaa6K/IaI/r6cu9yW690= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1669590673; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=lq+hxk2jZLq7sWjpYaRCMKOHOLgy8Wwlbt7cndUUYuU=; b=+yiqcfcmf0/ChHbECZGhFGNJysdm68XNY/oawDfGWE817SRlLy8gFDcQPnaBWLgAu5lBLq f4RfxAOZpPcGQlAA== Received: from imap2.suse-dmz.suse.de (imap2.suse-dmz.suse.de [192.168.254.74]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature ECDSA (P-521) server-digest SHA512) (No client certificate requested) by imap2.suse-dmz.suse.de (Postfix) with ESMTPS id D9846134CE; Sun, 27 Nov 2022 23:11:12 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id AIhhNJDug2PZAwAAMHmgww (envelope-from ); Sun, 27 Nov 2022 23:11:12 +0000 Message-ID: Date: Mon, 28 Nov 2022 00:11:12 +0100 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.5.0 Subject: Re: [PATCH 07/12] mm, slab: ignore SLAB_RECLAIM_ACCOUNT with CONFIG_SLUB_TINY Content-Language: en-US To: Christoph Lameter , David Rientjes , Joonsoo Kim , Pekka Enberg Cc: Hyeonggon Yoo <42.hyeyoo@gmail.com>, Roman Gushchin , Andrew Morton , Linus Torvalds , Matthew Wilcox , patches@lists.linux.dev, linux-mm@kvack.org, linux-kernel@vger.kernel.org References: <20221121171202.22080-1-vbabka@suse.cz> <20221121171202.22080-8-vbabka@suse.cz> From: Vlastimil Babka In-Reply-To: <20221121171202.22080-8-vbabka@suse.cz> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit ARC-Authentication-Results: i=1; imf26.hostedemail.com; dkim=pass header.d=suse.cz header.s=susede2_rsa header.b=bFAgYyVJ; dkim=pass header.d=suse.cz header.s=susede2_ed25519 header.b=+yiqcfcm; spf=pass (imf26.hostedemail.com: domain of vbabka@suse.cz designates 195.135.220.28 as permitted sender) smtp.mailfrom=vbabka@suse.cz; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1669590674; a=rsa-sha256; cv=none; b=PxZLMyHD+mgKJGk3f4c5ssCeC5Sol1fDvv7kbUa3VpYBXSvk8riuhyfzl2sJ80NRA7F0c4 0MxVWDwrIKUWDvMpcwmUNQlzoPIa7Kq2ZfG8p+lSdq2ZK+nA9aH1/07YOop3LCpUI2RAa3 xZcfUsLqWjyyyXQGqlBwPBvPSwkn0EQ= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1669590674; 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:content-transfer-encoding: in-reply-to:in-reply-to:references:references:dkim-signature; bh=lq+hxk2jZLq7sWjpYaRCMKOHOLgy8Wwlbt7cndUUYuU=; b=fWGNReZbfu1Ka0fsHNDI201/WOlh8Tl9s5Frxxw9agZCN1N4b7paaJX2YRYy4Rlc7m6npt 95EB4KFW6GICK7GfdLT60AohmTBg0/0jdrJWWZ5eEaoNMVWtW47Dk8jwZ5hfBs1/TPlXsj OZKTg40Lm0S6bmg4MvA1N18oBih4ggg= X-Rspamd-Queue-Id: 82E8014000F X-Rspam-User: Authentication-Results: imf26.hostedemail.com; dkim=pass header.d=suse.cz header.s=susede2_rsa header.b=bFAgYyVJ; dkim=pass header.d=suse.cz header.s=susede2_ed25519 header.b=+yiqcfcm; spf=pass (imf26.hostedemail.com: domain of vbabka@suse.cz designates 195.135.220.28 as permitted sender) smtp.mailfrom=vbabka@suse.cz; dmarc=none X-Rspamd-Server: rspam02 X-Stat-Signature: xru3xcp9611gzr1nz69qzsudp6pfyiki X-HE-Tag: 1669590674-147532 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: On 11/21/22 18:11, Vlastimil Babka wrote: > SLAB_RECLAIM_ACCOUNT caches allocate their slab pages with > __GFP_RECLAIMABLE and can help against fragmentation by grouping pages > by mobility, but on tiny systems mobility grouping is likely disabled > anyway and ignoring SLAB_RECLAIM_ACCOUNT might instead lead to merging > of caches that are made incompatible just by the flag. > > Thus with CONFIG_SLUB_TINY, make SLAB_RECLAIM_ACCOUNT ineffective. > > Signed-off-by: Vlastimil Babka > --- > include/linux/slab.h | 4 ++++ > 1 file changed, 4 insertions(+) > > diff --git a/include/linux/slab.h b/include/linux/slab.h > index 3ce9474c90ab..1cbbda03ad06 100644 > --- a/include/linux/slab.h > +++ b/include/linux/slab.h > @@ -129,7 +129,11 @@ > > /* The following flags affect the page allocator grouping pages by mobility */ > /* Objects are reclaimable */ > +#ifndef CONFIG_SLUB_TINY > #define SLAB_RECLAIM_ACCOUNT ((slab_flags_t __force)0x00020000U) > +#else > +#define SLAB_RECLAIM_ACCOUNT 0 Updating the last line above to: #define SLAB_RECLAIM_ACCOUNT ((slab_flags_t __force)0) In response to: https://lore.kernel.org/all/202211280441.yCEecX9z-lkp@intel.com/ Yeah it probably means that the other pre-existing flag variants that #define to 0 should be also adjusted to avoid these issues, but not as part of this series. > +#endif > #define SLAB_TEMPORARY SLAB_RECLAIM_ACCOUNT /* Objects are short-lived */ > > /*