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]
Message-ID: <YbilqnwnuTiQ2FEB@cmpxchg.org>
Date:   Tue, 14 Dec 2021 15:09:46 +0100
From:   Johannes Weiner <hannes@...xchg.org>
To:     Muchun Song <songmuchun@...edance.com>
Cc:     willy@...radead.org, akpm@...ux-foundation.org, mhocko@...nel.org,
        vdavydov.dev@...il.com, shakeelb@...gle.com, guro@...com,
        shy828301@...il.com, alexs@...nel.org, richard.weiyang@...il.com,
        david@...morbit.com, trond.myklebust@...merspace.com,
        anna.schumaker@...app.com, jaegeuk@...nel.org, chao@...nel.org,
        kari.argillander@...il.com, linux-fsdevel@...r.kernel.org,
        linux-kernel@...r.kernel.org, linux-mm@...ck.org,
        linux-nfs@...r.kernel.org, zhengqi.arch@...edance.com,
        duanxiongchun@...edance.com, fam.zheng@...edance.com,
        smuchun@...il.com
Subject: Re: [PATCH v4 09/17] mm: workingset: use xas_set_lru() to pass
 shadow_nodes

On Tue, Dec 14, 2021 at 12:53:34AM +0800, Muchun Song wrote:
> The workingset will add the xa_node to shadow_nodes, so we should use
> xas_set_lru() to pass the list_lru which we want to insert xa_node
> into to set up the xa_node reclaim context correctly.
> 
> Signed-off-by: Muchun Song <songmuchun@...edance.com>

Ah, you can't instantiate the list on-demand in list_lru_add() because
that's happening in an atomic context. So you need the lru available
in the broader xa update context and group the lru setup in with the
other pre-atomic node allocation bits. Fair enough. I think it would
be a bit easier to read if this patch and the previous one were
squashed (workingset is the only user of xa_lru anyway) and you added
that explanation. But other than that, the changes make sense to me;
to a combined patch, please add:

Acked-by: Johannes Weiner <hannes@...xchg.org>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ