Received: by 10.192.165.148 with SMTP id m20csp2556564imm; Thu, 26 Apr 2018 13:05:12 -0700 (PDT) X-Google-Smtp-Source: AIpwx4+CREbSyXixDfmVMZ74eaaF+gk+9ELiHyKiXjHahkwkkQ8rRE4l5m0NMHeJw825GYYaRZXY X-Received: by 10.98.80.145 with SMTP id g17mr33208185pfj.71.1524773112807; Thu, 26 Apr 2018 13:05:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1524773112; cv=none; d=google.com; s=arc-20160816; b=gAthncogLGHAQmepWwX9iDb0qNOweFyF15ZbyY+j6dVFlKgh9ztyyHpnMnCMjNG+fI 0G5jVwT9vkad7Ld2bdvEXHWk3qiYMfkXRoxv2KD1hkuzzkoZFqyLvBqMS6s5jJhnDDCo x2JPABe4f5uXQKKDsa0v6S/vG4LOx3oPrMhIu93wdTaDK0K5C5Nt3ZBTMYPfzjJcC7BI G+2oVX1HzUgYs9GaXYs+/dWEk8nPNEl6mtFhLTMk1lEOXJL74mQrex1sV5cC+ifJTQju bD7Ji/llVLE4S6qfV/g/0qlC+VMvBaODWdA8GLQU5tIfd5jpvSFNxQ7RKq1kwWspiy3R GmPA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:arc-authentication-results; bh=Ozm39BqjL4sdzHJXyluKBFBCA9VVLWz/ez84F8vTb3Q=; b=mvb/faNDyekP2rTJ/TpcyX+NeCVd7vfl95bIsD9ovKmbV7wXZXDZhNJk9e6wvCZAaD CV16xV1/vKnOtArTryLerMFVdfjWO/ttcCXS8Jyee8Bsvd9trfyu2QU8QMRNyVv6f88o 1znYAloFUVuPBnTx8peytMYTTLvh6UZL5+/Utec2nTsdDvJQBUTSmSm2BPfU+kMX1NR1 tr6HPPF29Vr1TARDXIo1fVgAoGDsOyb7gRnmonPkYBnhRu0Hyhd0SHPDCs9Hu7YNaRqh xY/tHsgxFUNjqy9ODycUViDI+IjgheZKgEp78kYcOnyaACBfw4aGa84jEt3Mdv0eVZtZ c6LQ== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b9si5210654pgq.210.2018.04.26.13.04.53; Thu, 26 Apr 2018 13:05:12 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1757112AbeDZUDg (ORCPT + 99 others); Thu, 26 Apr 2018 16:03:36 -0400 Received: from mx2.suse.de ([195.135.220.15]:45728 "EHLO mx2.suse.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756685AbeDZUDd (ORCPT ); Thu, 26 Apr 2018 16:03:33 -0400 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay1.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id 4497EAC71; Thu, 26 Apr 2018 20:03:32 +0000 (UTC) Date: Thu, 26 Apr 2018 22:03:31 +0200 From: Michal Hocko To: Roman Gushchin Cc: linux-mm@kvack.org, linux-kernel@vger.kernel.org, linux-api@vger.kernel.org, kernel-team@fb.com, Vlastimil Babka , Matthew Wilcox , Andrew Morton , Alexander Viro , Johannes Weiner Subject: Re: [PATCH] mm: don't show nr_indirectly_reclaimable in /proc/vmstat Message-ID: <20180426200331.GZ17484@dhcp22.suse.cz> References: <20180425191422.9159-1-guro@fb.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20180425191422.9159-1-guro@fb.com> User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed 25-04-18 20:14:22, Roman Gushchin wrote: > Don't show nr_indirectly_reclaimable in /proc/vmstat, > because there is no need in exporting this vm counter > to the userspace, and some changes are expected > in reclaimable object accounting, which can alter > this counter. > > Signed-off-by: Roman Gushchin > Cc: Vlastimil Babka > Cc: Matthew Wilcox > Cc: Andrew Morton > Cc: Alexander Viro > Cc: Michal Hocko > Cc: Johannes Weiner This is quite a hack. I would much rather revert the counter and fixed it the way Vlastimil has proposed. But if there is a strong opposition to the revert then this is probably the simples thing to do. Therefore Unhappy-Acked-by: Michal Hocko > --- > mm/vmstat.c | 6 +++++- > 1 file changed, 5 insertions(+), 1 deletion(-) > > diff --git a/mm/vmstat.c b/mm/vmstat.c > index 536332e988b8..a2b9518980ce 100644 > --- a/mm/vmstat.c > +++ b/mm/vmstat.c > @@ -1161,7 +1161,7 @@ const char * const vmstat_text[] = { > "nr_vmscan_immediate_reclaim", > "nr_dirtied", > "nr_written", > - "nr_indirectly_reclaimable", > + "", /* nr_indirectly_reclaimable */ > > /* enum writeback_stat_item counters */ > "nr_dirty_threshold", > @@ -1740,6 +1740,10 @@ static int vmstat_show(struct seq_file *m, void *arg) > unsigned long *l = arg; > unsigned long off = l - (unsigned long *)m->private; > > + /* Skip hidden vmstat items. */ > + if (*vmstat_text[off] == '\0') > + return 0; > + > seq_puts(m, vmstat_text[off]); > seq_put_decimal_ull(m, " ", *l); > seq_putc(m, '\n'); > -- > 2.14.3 -- Michal Hocko SUSE Labs