Re: [PATCH] khugepaged: Raplace barrier() with READ_ONCE() for a selective variable

2021-03-23 Thread Kirill A. Shutemov
On Tue, Mar 23, 2021 at 05:27:30PM +0800, yanfei...@windriver.com wrote: > From: Yanfei Xu > > READ_ONCE() is more selective and lightweight. It is more appropriate that > using a READ_ONCE() for the certain variable to prevent the compiler from > reordering. > > Signed-off-by: Yanfei Xu Acked

[PATCH] khugepaged: Raplace barrier() with READ_ONCE() for a selective variable

2021-03-23 Thread yanfei . xu
From: Yanfei Xu READ_ONCE() is more selective and lightweight. It is more appropriate that using a READ_ONCE() for the certain variable to prevent the compiler from reordering. Signed-off-by: Yanfei Xu --- mm/khugepaged.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/m