Received: by 2002:a05:6a10:c604:0:0:0:0 with SMTP id y4csp3861185pxt; Tue, 10 Aug 2021 13:09:18 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwJrgZOcBaGtVpOutF95bpEQiR/Q3IQh4wjJ6b2SELP5VutwxMC7F+zw7NNqVZ0wIquUeGA X-Received: by 2002:a05:6e02:10a:: with SMTP id t10mr313488ilm.52.1628626158435; Tue, 10 Aug 2021 13:09:18 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1628626158; cv=none; d=google.com; s=arc-20160816; b=drfTR/hjfGkXomzxgtdojfloyOoOZpWbIV0gLelK0fxKlmexvkY+21RmxC683efXQu SQladiHPCLb2lyF4lfFdIMujDdMxeJWd52RzHaOC3XK18MyRQMsI1r8H23Nh9bDsEgsR lXxnvuBur6aF/okTMsuw2L/gNsc5t4tgCo+qIFrnyzKqXP7ec/3nrKE+TzQhb4n0YQk6 W5BISxWiPnwMO35ymLNfvIp92/jrJWEwPJdRwiuWROMqtemuxmfuWoiyBuG70D6fwTgx GxjmPiC//62FQr4b7dNuBWA8Hwkn2cfbR7q69TSl19orbQSH/QUUbBuUmbGz87bQrPiW 71wA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:content-id:mime-version:subject :cc:to:references:in-reply-to:from:organization:dkim-signature; bh=Mb5VBTkb8S88umgyEx90HwHXvZnu9/1GybLMu7zbg4A=; b=IGWblvTkTs+W4F1ZlBF/OtaY8Tq75LuYMArsOMaenPRw+e27jglYkHeNAPMgavCRcB /Qs89KG0sG87jGiZLGR2YiFEhgIC2CJLPVtWzTCc9vhKXbz21oEzohHK9tgjD79VG6ne 7Xri3awuLsJfwdLF0CtSe/F1Ix39wVINhAgVBdjL23GHgqblopqW9vxipVNwnm7L3txI Jpkvy+Y/BayBJlAej1msZl51wuVLW45m8amNNI7BUVoBtmi/HJron+/YAIb9YKgxXsNP 9467NZw96QHmxBH8he3rlEoB0JTfBwR07vayomA4MQYSdd+rhub8Jg40G7SYD/ZqCDrj lj/A== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@redhat.com header.s=mimecast20190719 header.b=MudRFDEU; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id i1si20703067iow.3.2021.08.10.13.09.07; Tue, 10 Aug 2021 13:09:18 -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=@redhat.com header.s=mimecast20190719 header.b=MudRFDEU; 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; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232876AbhHJUHY (ORCPT + 99 others); Tue, 10 Aug 2021 16:07:24 -0400 Received: from us-smtp-delivery-124.mimecast.com ([170.10.133.124]:27862 "EHLO us-smtp-delivery-124.mimecast.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232836AbhHJUHV (ORCPT ); Tue, 10 Aug 2021 16:07:21 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1628626019; 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=Mb5VBTkb8S88umgyEx90HwHXvZnu9/1GybLMu7zbg4A=; b=MudRFDEUCauBggYS05NPau25zgxR3EAksGcx3k3rbt8Vojc8TMriuBYJ9NWP9JGyPYfATM ZWPWSAQN7xNzg92F8v2wVAJMWTs1rACzKh/Mk6LPixvGQIpURNMiUL1yBgY2hDQoKtsoxD U/1LYs5gZK/sXlPv86CNLNhebItvBP0= Received: from mimecast-mx01.redhat.com (mimecast-mx01.redhat.com [209.132.183.4]) (Using TLS) by relay.mimecast.com with ESMTP id us-mta-456-kHx-yYzKO2meQHTDf3jW6w-1; Tue, 10 Aug 2021 16:06:55 -0400 X-MC-Unique: kHx-yYzKO2meQHTDf3jW6w-1 Received: from smtp.corp.redhat.com (int-mx07.intmail.prod.int.phx2.redhat.com [10.5.11.22]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx01.redhat.com (Postfix) with ESMTPS id 6D0B53639F; Tue, 10 Aug 2021 20:06:54 +0000 (UTC) Received: from warthog.procyon.org.uk (unknown [10.22.32.7]) by smtp.corp.redhat.com (Postfix) with ESMTP id EEFE5100EBB0; Tue, 10 Aug 2021 20:06:52 +0000 (UTC) Organization: Red Hat UK Ltd. Registered Address: Red Hat UK Ltd, Amberley Place, 107-111 Peascod Street, Windsor, Berkshire, SI4 1TE, United Kingdom. Registered in England and Wales under Company Registration No. 3798903 From: David Howells In-Reply-To: <20210715033704.692967-36-willy@infradead.org> References: <20210715033704.692967-36-willy@infradead.org> <20210715033704.692967-1-willy@infradead.org> To: "Matthew Wilcox (Oracle)" Cc: dhowells@redhat.com, linux-kernel@vger.kernel.org, linux-mm@kvack.org, linux-fsdevel@vger.kernel.org, Michal Hocko , Johannes Weiner , Christoph Hellwig Subject: Re: [PATCH v14 035/138] mm/memcg: Use the node id in mem_cgroup_update_tree() MIME-Version: 1.0 Content-Type: text/plain; charset="us-ascii" Content-ID: <1809567.1628626012.1@warthog.procyon.org.uk> Date: Tue, 10 Aug 2021 21:06:52 +0100 Message-ID: <1809568.1628626012@warthog.procyon.org.uk> X-Scanned-By: MIMEDefang 2.84 on 10.5.11.22 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Matthew Wilcox (Oracle) wrote: > By using the node id in mem_cgroup_update_tree(), we can delete > soft_limit_tree_from_page() and mem_cgroup_page_nodeinfo(). Saves 42 > bytes of kernel text on my config. > > Signed-off-by: Matthew Wilcox (Oracle) > Acked-by: Michal Hocko > Acked-by: Johannes Weiner > Reviewed-by: Christoph Hellwig Reviewed-by: David Howells Though I wonder if: > - mz = mem_cgroup_page_nodeinfo(memcg, page); > + mz = memcg->nodeinfo[nid]; should still have some sort of wrapper function.