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] [day] [month] [year] [list]
Message-ID: <2023072144-item-cosmic-5c73@gregkh>
Date:   Fri, 21 Jul 2023 07:18:52 +0200
From:   Greg KH <gregkh@...uxfoundation.org>
To:     SeongJae Park <sj@...nel.org>
Cc:     ryan.roberts@....com, akpm@...ux-foundation.org, hch@....de,
        kirill.shutemov@...ux.intel.com, lstoakes@...il.com,
        rppt@...nel.org, stable@...r.kernel.org, urezki@...il.com,
        willy@...radead.org, yuzhao@...gle.com, ziy@...dia.com,
        damon@...ts.linux.dev, linux-mm@...ck.org,
        linux-kernel@...r.kernel.org
Subject: Re: [PATCH 5.15.y] mm/damon/ops-common: atomically test and clear
 young on ptes and pmds

On Mon, Jul 17, 2023 at 07:30:08PM +0000, SeongJae Park wrote:
> From: Ryan Roberts <ryan.roberts@....com>
> 
> commit c11d34fa139e4b0fb4249a30f37b178353533fa1 upstream.
> 
> It is racy to non-atomically read a pte, then clear the young bit, then
> write it back as this could discard dirty information.  Further, it is bad
> practice to directly set a pte entry within a table.  Instead clearing
> young must go through the arch-provided helper,
> ptep_test_and_clear_young() to ensure it is modified atomically and to
> give the arch code visibility and allow it to check (and potentially
> modify) the operation.
> 
> Link: https://lkml.kernel.org/r/20230602092949.545577-3-ryan.roberts@arm.com
> Fixes: 3f49584b262c ("mm/damon: implement primitives for the virtual memory address spaces").
> Signed-off-by: Ryan Roberts <ryan.roberts@....com>
> Reviewed-by: Zi Yan <ziy@...dia.com>
> Reviewed-by: SeongJae Park <sj@...nel.org>
> Reviewed-by: Mike Rapoport (IBM) <rppt@...nel.org>
> Cc: Christoph Hellwig <hch@....de>
> Cc: Kirill A. Shutemov <kirill.shutemov@...ux.intel.com>
> Cc: Lorenzo Stoakes <lstoakes@...il.com>
> Cc: Matthew Wilcox (Oracle) <willy@...radead.org>
> Cc: Uladzislau Rezki (Sony) <urezki@...il.com>
> Cc: Yu Zhao <yuzhao@...gle.com>
> Cc: <stable@...r.kernel.org>
> Signed-off-by: Andrew Morton <akpm@...ux-foundation.org>
> Signed-off-by: SeongJae Park <sj@...nel.org>
> ---
> This is a manual backport of the commit, which cannot cleanly
> cherry-picked on 5.15.y[1], on 5.15.y, specifically 5.15.120.
> 
> [1] https://lore.kernel.org/stable/2023071613-reminder-relapse-b922@gregkh/

Now queued up, thanks.

greg k-h

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ