From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755314AbaELQHR (ORCPT ); Mon, 12 May 2014 12:07:17 -0400 Received: from qmta11.emeryville.ca.mail.comcast.net ([76.96.27.211]:52828 "EHLO qmta11.emeryville.ca.mail.comcast.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752204AbaELQHP (ORCPT ); Mon, 12 May 2014 12:07:15 -0400 Date: Mon, 12 May 2014 11:07:12 -0500 (CDT) From: Christoph Lameter X-X-Sender: cl@gentwo.org To: Jianyu Zhan cc: Andrew Morton , Hugh Dickins , Rik van Riel , Mel Gorman , Zhang Yanfei , Andrea Arcangeli , fabf@skynet.be, sasha.levin@oracle.com, oleg@redhat.com, Naoya Horiguchi , iamjoonsoo.kim@lge.com, kirill.shutemov@linux.intel.com, Cyrill Gorcunov , dave.hansen@linux.intel.com, toshi.kani@hp.com, paul.gortmaker@windriver.com, srivatsa.bhat@linux.vnet.ibm.com, "linux-mm@kvack.org" , LKML Subject: Re: [PATCH 1/3] mm: add comment for __mod_zone_page_stat In-Reply-To: Message-ID: References: <1399811500-14472-1-git-send-email-nasa4836@gmail.com> Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, 12 May 2014, Jianyu Zhan wrote: > This means they guarantee that even they are preemted the vm > counter won't be modified incorrectly. Because the counter is page-related > (e.g., a new anon page added), and they are exclusively hold the pte lock. Ok. if these locations hold the pte lock then preemption is disabled and you are ok to use __mod_zone_page_state. Has nothing to do with the page.