Skip to content

Commit 790c736

Browse files
groecktorvalds
authored andcommitted
mm/gup.c: mark undo_dev_pagemap as __maybe_unused
Several mips builds generate the following build warning. mm/gup.c:1788:13: warning: 'undo_dev_pagemap' defined but not used The function is declared unconditionally but only called from behind various ifdefs. Mark it __maybe_unused. Link: http://lkml.kernel.org/r/1562072523-22311-1-git-send-email-linux@roeck-us.net Signed-off-by: Guenter Roeck <linux@roeck-us.net> Reviewed-by: Andrew Morton <akpm@linux-foundation.org> Cc: Stephen Rothwell <sfr@canb.auug.org.au> Cc: Robin Murphy <robin.murphy@arm.com> Cc: Kirill A. Shutemov <kirill.shutemov@linux.intel.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent b5d1c39 commit 790c736

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

‎mm/gup.c‎

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1796,7 +1796,8 @@ static inline pte_t gup_get_pte(pte_t *ptep)
17961796
}
17971797
#endif /* CONFIG_GUP_GET_PTE_LOW_HIGH */
17981798

1799-
static void undo_dev_pagemap(int *nr, int nr_start, struct page **pages)
1799+
static void __maybe_unused undo_dev_pagemap(int *nr, int nr_start,
1800+
struct page **pages)
18001801
{
18011802
while ((*nr) - nr_start) {
18021803
struct page *page = pages[--(*nr)];

0 commit comments

Comments
 (0)