From patchwork Tue Nov 16 00:16:27 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Vlastimil Babka X-Patchwork-Id: 12620733 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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id F0042C433F5 for ; Tue, 16 Nov 2021 00:17:40 +0000 (UTC) Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by mail.kernel.org (Postfix) with ESMTP id A8EF7614C8 for ; Tue, 16 Nov 2021 00:17:40 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org A8EF7614C8 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=suse.cz Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=kvack.org Received: by kanga.kvack.org (Postfix) id 87FC56B00A3; Mon, 15 Nov 2021 19:16:46 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id DA9A96B00A8; Mon, 15 Nov 2021 19:16:45 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 8B9DF6B00A9; Mon, 15 Nov 2021 19:16:45 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from forelay.hostedemail.com (smtprelay0212.hostedemail.com [216.40.44.212]) by kanga.kvack.org (Postfix) with ESMTP id D89D16B00A8 for ; Mon, 15 Nov 2021 19:16:43 -0500 (EST) Received: from smtpin06.hostedemail.com (10.5.19.251.rfc1918.com [10.5.19.251]) by forelay01.hostedemail.com (Postfix) with ESMTP id 873581815BBE5 for ; Tue, 16 Nov 2021 00:16:43 +0000 (UTC) X-FDA: 78812877486.06.B16D55F Received: from smtp-out2.suse.de (smtp-out2.suse.de [195.135.220.29]) by imf31.hostedemail.com (Postfix) with ESMTP id 7D2B21055384 for ; Tue, 16 Nov 2021 00:16:25 +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-out2.suse.de (Postfix) with ESMTPS id 2FD9A1FD74; Tue, 16 Nov 2021 00:16:42 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1637021802; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ccS3ZeIJZ6bQyqvNIs1xdFQVrwoODwqrOjrLQSSERJo=; b=r6RZ2O06SrlTwOEo/jKstyw5NtQV8A3XdQi1g5OaqCELvj4j4e1VpNyfZwJ6TR+hVs9UpC la7p8ATqqcCAH9HZFKloPAq3vaUWhW9WwZu8/4gFfBM/dXA8cDxLsn7ejsvKiX6R6m0zb6 tQ465XSWPBFrmPr7R6Q5BEBmtdkxGpw= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1637021802; h=from:from:reply-to:date:date:message-id:message-id:to:to:cc:cc: mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=ccS3ZeIJZ6bQyqvNIs1xdFQVrwoODwqrOjrLQSSERJo=; b=x/qCegLOrTjeNfZq3FrxbW3A56p5pesvxAkmvPas+SVmkJOXou5jIaSHcQ4rGGUvwZ5vai RRg6uHBv2PE3FLDQ== 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 13329139DB; Tue, 16 Nov 2021 00:16:42 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap2.suse-dmz.suse.de with ESMTPSA id +GkcBGr4kmFjXAAAMHmgww (envelope-from ); Tue, 16 Nov 2021 00:16:42 +0000 From: Vlastimil Babka To: Matthew Wilcox , linux-mm@kvack.org, Christoph Lameter , David Rientjes , Joonsoo Kim , Pekka Enberg Cc: Vlastimil Babka Subject: [RFC PATCH 31/32] mm/slub: Simplify struct slab slabs field definition Date: Tue, 16 Nov 2021 01:16:27 +0100 Message-Id: <20211116001628.24216-32-vbabka@suse.cz> X-Mailer: git-send-email 2.33.1 In-Reply-To: <20211116001628.24216-1-vbabka@suse.cz> References: <20211116001628.24216-1-vbabka@suse.cz> MIME-Version: 1.0 X-Developer-Signature: v=1; a=openpgp-sha256; l=800; h=from:subject; bh=jgaqBohnYDwSYlWxll8S3eia5KfhC1Tki4yZ3+6G2h8=; b=owEBbQGS/pANAwAIAeAhynPxiakQAcsmYgBhkvhZd1i2PiTA3nvKmIPuG2n5GPVlubzkKBZKQOqj q7xVY5iJATMEAAEIAB0WIQSNS5MBqTXjGL5IXszgIcpz8YmpEAUCYZL4WQAKCRDgIcpz8YmpEGauCA CXRcS8O/5zmrK2Y7wgyuAwXkHiJxCa7Hune4cMqEGq8tLriOv++i40lb9M51Z/4AM8UJnLOMISe175 5ptKSsnOTOL+nmYmHzlGzjfx7H2nEHFZK2bdkoYF+7ju1G5QETPuQvKQXeU6Cer6XCUyNRO6uoRl/i GKitFX1k9cq7uUElFBv+sRbLZfHN+v3lfTbQQYuTuAnNM0DXHr8j6nzXCUoP4o0G3nnEpZGc7sYBeB ferSnFn8Lc2H/0mWvGnJkxhez4xamye9qOJyupmElLNrU17qQvePvUhmBha56DcDizQD7h76wwOkbd 306/8CqLa3kKUO0gnuGZoVP+8ILrr0 X-Developer-Key: i=vbabka@suse.cz; a=openpgp; fpr=A940D434992C2E8E99103D50224FA7E7CC82A664 X-Stat-Signature: bejusoni1ze65tzrn64csb78xfadcrxh Authentication-Results: imf31.hostedemail.com; dkim=pass header.d=suse.cz header.s=susede2_rsa header.b=r6RZ2O06; dkim=pass header.d=suse.cz header.s=susede2_ed25519 header.b="x/qCegLO"; spf=pass (imf31.hostedemail.com: domain of vbabka@suse.cz designates 195.135.220.29 as permitted sender) smtp.mailfrom=vbabka@suse.cz; dmarc=none X-Rspamd-Server: rspam01 X-Rspamd-Queue-Id: 7D2B21055384 X-HE-Tag: 1637021785-479457 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: Before commit b47291ef02b0 ("mm, slub: change percpu partial accounting from objects to pages") we had to fit two integer fields into a native word size, so we used short int on 32-bit and int on 64-bit via #ifdef. After that commit there is only one integer field, so we can simply define it as int everywhere. Signed-off-by: Vlastimil Babka --- mm/slab.h | 4 ---- 1 file changed, 4 deletions(-) diff --git a/mm/slab.h b/mm/slab.h index 10a9ee195249..31490e1f7c91 100644 --- a/mm/slab.h +++ b/mm/slab.h @@ -27,11 +27,7 @@ struct slab { struct rcu_head rcu_head; struct { struct slab *next; -#ifdef CONFIG_64BIT int slabs; /* Nr of slabs left */ -#else - short int slabs; -#endif }; }; struct kmem_cache *slab_cache;