lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Wed, 6 Apr 2016 10:52:15 +0100
From:	Mel Gorman <mgorman@...hsingularity.net>
To:	Hugh Dickins <hughd@...gle.com>
Cc:	Andrew Morton <akpm@...ux-foundation.org>,
	"Kirill A. Shutemov" <kirill.shutemov@...ux.intel.com>,
	Andrea Arcangeli <aarcange@...hat.com>,
	Andres Lagar-Cavilla <andreslc@...gle.com>,
	Yang Shi <yang.shi@...aro.org>, Ning Qu <quning@...il.com>,
	linux-kernel@...r.kernel.org, linux-mm@...ck.org
Subject: Re: [PATCH 03/10] mm: use __SetPageSwapBacked and dont
 ClearPageSwapBacked

On Tue, Apr 05, 2016 at 01:44:16PM -0700, Hugh Dickins wrote:
> v3.16 commit 07a427884348 ("mm: shmem: avoid atomic operation during
> shmem_getpage_gfp") rightly replaced one instance of SetPageSwapBacked
> by __SetPageSwapBacked, pointing out that the newly allocated page is
> not yet visible to other users (except speculative get_page_unless_zero-
> ers, who may not update page flags before their further checks).
> 
> That was part of a series in which Mel was focused on tmpfs profiles:
> but almost all SetPageSwapBacked uses can be so optimized, with the same
> justification.  Remove ClearPageSwapBacked from __read_swap_cache_async()
> error path: it's not an error to free a page with PG_swapbacked set.
> 
> Follow a convention of __SetPageLocked, __SetPageSwapBacked instead of
> doing it differently in different places; but that's for tidiness - if
> the ordering actually mattered, we should not be using the __variants.
> 
> There's probably scope for further __SetPageFlags in other places,
> but SwapBacked is the one I'm interested in at the moment.
> 
> Signed-off-by: Hugh Dickins <hughd@...gle.com>
> ---
> Sorry, Mel did give
> a year ago, but the kernel has moved on since then,

Still looks good to me so

Reviewed-by: Mel Gorman <mgorman@...hsingularity.net>

-- 
Mel Gorman
SUSE Labs

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ