Re: [PATCH v4] mm: fix is_pinnable_page against on cma page

From: John Hubbard
Date: Thu May 12 2022 - 00:47:54 EST


On 5/11/22 20:44, Minchan Kim wrote:
Thanks for checking, John.

I don't want to have the READ_ONCE in __get_pfnblock_flags_mask
atm even though it's an extra memory dereference for specific
architecutre and specific compiler unless other callsites *do*
need it.

We choose the choice(i.e., having __READ_ONCE in is_pinanble_
page) for *potential* cases(e.g., aggressive LTO for future)
and if it's an extra memory dereference atm, it would be multiple
instructions *potentailly* as having more change or different
compiler and/or arches now or later. It's out of scope in
this patch.

Agreed!


thanks,
--
John Hubbard
NVIDIA