Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp3719612pxt; Tue, 10 Aug 2021 09:45:51 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyi7zXL4CLG7GlL8mTLAfQITdZusRZMu3nx1Fa49prKgXF1SnQIx/e/YMWuwk+u/shznRNi X-Received: by 2002:a02:3b11:: with SMTP id c17mr10356198jaa.63.1628613951046; Tue, 10 Aug 2021 09:45:51 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628613951; cv=none; d=google.com; s=arc-20160816; b=uAojt63yqjJMWWSzd5gmhLgrMxXNdgf2F8iBytOr8uxEE6glnoABymgXDH35No3lkc CB8twijFHQyqQNFKoceO0Sz/Oz0DsdqXAE7lJXuQKsCj8mgrq0qB2iXA+I1sfTpUEByk xlL86ykA3n3P7sjPO5ZIEWrRwaKPEce43XuprrfVEimi+vXT9ojzV5zlJLdTH6ZZP5Bg lXT7keKhfmJmHVNf7TuRVwph3SNrTwBvmA3vsdOg/aXL2aER/YAmTUqqt7cRFbmrCfer ylCEOQ3jjKQE5giuTV460mF616Eq3PZiDRPWRtgjqiyIiGB94+k2WO2sOG4bC20erdoQ quvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature:dkim-signature; bh=oCRKUveE33VvcZMJL2XnwneZOV742TksTwb3FEBahsM=; b=kZeEV+KmgY58b2m5h5VI90D8oU2Bxmw4f9xYxWC9CGJ20XRohZXK91PLmBZBWNrjKX HB+OvVYY2CTw5L52f+IbUDMwG+jLz8IdszOt6+za/8w+4BR25Xz6m65nOC/OqTjGtiam 34NzkYgo+D49FViiSWTIXxMLqNhoXSYoZg+TllzK0iF48e0jYEtyQrTeQzFGwjfQLvUq 9pMw5K3Q+BWiyjOXLyWCscih/VgnJP7zc9bVNL3Xxk8mLm/dNnkxmAcphcytIcC4tI1T xHTaKJIhkjoUtSDFln9N5A83rhqBmqIi3l/o/mLNGRjHFFFDVczeUai5utCKUqIylRHQ P0zg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=T+BoxSbg; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519 header.b=D0JRzRyO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id u15si24849031iot.89.2021.08.10.09.45.37; Tue, 10 Aug 2021 09:45:51 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@suse.cz header.s=susede2_rsa header.b=T+BoxSbg; dkim=neutral (no key) header.i=@suse.cz header.s=susede2_ed25519 header.b=D0JRzRyO; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S242306AbhHJQBm (ORCPT + 99 others); Tue, 10 Aug 2021 12:01:42 -0400 Received: from smtp-out1.suse.de ([195.135.220.28]:48992 "EHLO smtp-out1.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S239168AbhHJQBl (ORCPT ); Tue, 10 Aug 2021 12:01:41 -0400 Received: from imap1.suse-dmz.suse.de (imap1.suse-dmz.suse.de [192.168.254.73]) (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 14F9322069; Tue, 10 Aug 2021 16:01:18 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_rsa; t=1628611278; 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=oCRKUveE33VvcZMJL2XnwneZOV742TksTwb3FEBahsM=; b=T+BoxSbgtruUXzJbuimf79cKwQ8YblfGeaVl6NlwHHvNVCX1ET1707rrLhseItDqI5QKKv 49yogIW1pIrkWiXBr5tjZ/mTHGp8bL/AbDGnK3fBxL4i/m8zx2ro888PClvHo67EW6hqdt qp/S2tnKignm0KJSkYP+RA+szTkooMs= DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=suse.cz; s=susede2_ed25519; t=1628611278; 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=oCRKUveE33VvcZMJL2XnwneZOV742TksTwb3FEBahsM=; b=D0JRzRyOU3Hm1PxLBc+KyqIa2waelCCd+hvILDxPW+CQIuVV3uwseBnATR7ldEjY7+jpj9 Mt9ZjvdRuTOCKrBg== Received: from imap1.suse-dmz.suse.de (imap1.suse-dmz.suse.de [192.168.254.73]) (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 imap1.suse-dmz.suse.de (Postfix) with ESMTPS id E8896137DA; Tue, 10 Aug 2021 16:01:17 +0000 (UTC) Received: from dovecot-director2.suse.de ([192.168.254.65]) by imap1.suse-dmz.suse.de with ESMTPSA id D70YOM2iEmF2SwAAGKfGzw (envelope-from ); Tue, 10 Aug 2021 16:01:17 +0000 Subject: Re: [PATCH v14 011/138] mm/lru: Add folio LRU functions To: "Matthew Wilcox (Oracle)" , linux-kernel@vger.kernel.org Cc: linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Yu Zhao , Christoph Hellwig , David Howells , "Kirill A . Shutemov" References: <20210715033704.692967-1-willy@infradead.org> <20210715033704.692967-12-willy@infradead.org> From: Vlastimil Babka Message-ID: <91fb7d5b-9f5f-855e-2c87-dab105d5c977@suse.cz> Date: Tue, 10 Aug 2021 18:01:16 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:78.0) Gecko/20100101 Thunderbird/78.12.0 MIME-Version: 1.0 In-Reply-To: <20210715033704.692967-12-willy@infradead.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 7/15/21 5:34 AM, Matthew Wilcox (Oracle) wrote: > Handle arbitrary-order folios being added to the LRU. By definition, > all pages being added to the LRU were already head or base pages, but > call page_folio() on them anyway to get the type right and avoid the > buried calls to compound_head(). > > Saves 783 bytes of kernel text; no functions grow. > > Signed-off-by: Matthew Wilcox (Oracle) > Reviewed-by: Yu Zhao > Reviewed-by: Christoph Hellwig > Reviewed-by: David Howells > Acked-by: Kirill A. Shutemov Acked-by: Vlastimil Babka Actually looking at the git version, which has also this: static __always_inline void update_lru_size(struct lruvec *lruvec, enum lru_list lru, enum zone_type zid, - int nr_pages) + long nr_pages) { Why now and here? Some of the functions called from update_lru_size() still take int so this looks arbitrary?