mm: try_to_unmap() is now void
PATCH 1/1 mm: try_to_unmap() is now void
Fix the "CONFIG_MMU is not set" case of converting try_to_unmap() from bool to void.
In file included from ../mm/vmscan.c:33:../mm/vmscan.c: In function 'shrink_page_list':../include/linux/rmap.h:294:34: warning: statement with no effect [-Wunused-value]
294 | #define try_to_unmap(page, refs) false
| ^~~~~../mm/vmscan.c:1508:4: note: in expansion of macro 'try_to_unmap'
1508 | try_to_unmap(page, flags);
| ^~~~~~~~~~~~Fixes 1fb08ac63bee ("mm: rmap: make try_to_unmap() void function")
Signed-off-by Randy Dunlap <[email protected]>
Cc Yang Shi <[email protected]>
Cc Hugh Dickins <[email protected]>
Cc Andrew Morton <[email protected]>
--- include/linux/rmap.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
include/linux/rmap.h +1 -1
@@ -291,7 +291,7 @@ static inline int page_referenced(structreturn 0 ; } -#define try_to_unmap (page, refs) false +#define try_to_unmap (page, refs) do {} while (0)static inline int page_mkclean (struct page *page) {