From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752465AbcGGL0Z (ORCPT ); Thu, 7 Jul 2016 07:26:25 -0400 Received: from outbound-smtp09.blacknight.com ([46.22.139.14]:35480 "EHLO outbound-smtp09.blacknight.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751092AbcGGL0Y (ORCPT ); Thu, 7 Jul 2016 07:26:24 -0400 Date: Thu, 7 Jul 2016 12:26:20 +0100 From: Mel Gorman To: Dave Hansen Cc: Andrew Morton , Linux-MM , Rik van Riel , Vlastimil Babka , Johannes Weiner , LKML Subject: Re: [PATCH 31/31] mm, vmstat: Remove zone and node double accounting by approximating retries Message-ID: <20160707112620.GV11498@techsingularity.net> References: <1467403299-25786-1-git-send-email-mgorman@techsingularity.net> <1467403299-25786-32-git-send-email-mgorman@techsingularity.net> <577D4A24.1090800@intel.com> MIME-Version: 1.0 Content-Type: text/plain; charset=iso-8859-15 Content-Disposition: inline In-Reply-To: <577D4A24.1090800@intel.com> User-Agent: Mutt/1.5.23 (2014-03-12) Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Jul 06, 2016 at 11:12:52AM -0700, Dave Hansen wrote: > On 07/01/2016 01:01 PM, Mel Gorman wrote: > > +#ifdef CONFIG_HIGHMEM > > +extern unsigned long highmem_file_pages; > > + > > +static inline void acct_highmem_file_pages(int zid, enum lru_list lru, > > + int nr_pages) > > +{ > > + if (is_highmem_idx(zid) && is_file_lru(lru)) > > + highmem_file_pages += nr_pages; > > +} > > +#else > > Shouldn't highmem_file_pages technically be an atomic_t (or atomic64_t)? > We could have highmem on two nodes which take two different LRU locks. It would require a NUMA machine with highmem or very weird configurations but sure, atomic is safer. -- Mel Gorman SUSE Labs