Skip to content

Commit c3565a3

Browse files
andy-shevrafaeljw
authored andcommitted
PM: hibernate: Remove unused stub for saveable_highmem_page()
When saveable_highmem_page() is unused, it prevents kernel builds with clang, `make W=1` and CONFIG_WERROR=y: kernel/power/snapshot.c:1369:21: error: unused function 'saveable_highmem_page' [-Werror,-Wunused-function] 1369 | static inline void *saveable_highmem_page(struct zone *z, unsigned long p) | ^~~~~~~~~~~~~~~~~~~~~ Fix this by removing unused stub. See also commit 6863f56 ("kbuild: allow Clang to find unused static inline functions for W=1 build"). Signed-off-by: Andy Shevchenko <[email protected]> Link: https://patch.msgid.link/[email protected] Signed-off-by: Rafael J. Wysocki <[email protected]>
1 parent c62362e commit c3565a3

File tree

1 file changed

+0
-5
lines changed

1 file changed

+0
-5
lines changed

kernel/power/snapshot.c

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1365,11 +1365,6 @@ static unsigned int count_highmem_pages(void)
13651365
}
13661366
return n;
13671367
}
1368-
#else
1369-
static inline void *saveable_highmem_page(struct zone *z, unsigned long p)
1370-
{
1371-
return NULL;
1372-
}
13731368
#endif /* CONFIG_HIGHMEM */
13741369

13751370
/**

0 commit comments

Comments
 (0)