From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752708AbbCXOnM (ORCPT ); Tue, 24 Mar 2015 10:43:12 -0400 Received: from e06smtp17.uk.ibm.com ([195.75.94.113]:41358 "EHLO e06smtp17.uk.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752309AbbCXOnJ (ORCPT ); Tue, 24 Mar 2015 10:43:09 -0400 Message-ID: <551177F0.3070006@de.ibm.com> Date: Tue, 24 Mar 2015 15:42:56 +0100 From: Christian Borntraeger User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Thunderbird/31.5.0 MIME-Version: 1.0 To: Jason Low , linux-mm@kvack.org, linux-kernel@vger.kernel.org, cgroups@vger.kernel.org CC: Johannes Weiner , Michal Hocko , Christoph Lameter , Linus Torvalds , David Rientjes , Joonsoo Kim , Andrew Morton , "Kirill A. Shutemov" , Aswin Chandramouleeswaran , Mel Gorman , Hugh Dickins , Minchan Kim , Davidlohr Bueso , Rik van Riel Subject: Re: [PATCH] mm: Remove usages of ACCESS_ONCE References: <1427150680.2515.36.camel@j-VirtualBox> In-Reply-To: <1427150680.2515.36.camel@j-VirtualBox> Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-TM-AS-MML: disable X-Content-Scanned: Fidelis XPS MAILER x-cbid: 15032414-0029-0000-0000-000003EB43B5 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Am 23.03.2015 um 23:44 schrieb Jason Low: > Commit 38c5ce936a08 converted ACCESS_ONCE usage in gup_pmd_range() to > READ_ONCE, since ACCESS_ONCE doesn't work reliably on non-scalar types. > > This patch removes the rest of the usages of ACCESS_ONCE, and use > READ_ONCE for the read accesses. This also makes things cleaner, > instead of using separate/multiple sets of APIs. > > Signed-off-by: Jason Low Reviewed-by: Christian Borntraeger one remark or question: > - anon_mapping = (unsigned long) ACCESS_ONCE(page->mapping); > + anon_mapping = (unsigned long)READ_ONCE(page->mapping); Were the white space changes intentional? IIRC checkpatch does prefer it your way and you have changed several places - so I assume yes. Either way, its probably fine to change that along. Christian