tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master head: 7999516e20bd9bb5d1f7351cbd05ca529a3a8d60 commit: 73b831d4a3c725ed2b4ee15ef9f789b97f5679eb [5973/6030] mm/idle_page_tracking: Make PG_idle reusable config: nds32-randconfig-p001-20210809 (attached as .config) compiler: nds32le-linux-gcc (GCC) 10.3.0 reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/?id=73b831d4a3c725ed2b4ee15ef9f789b97f5679eb git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git git fetch --no-tags linux-next master git checkout 73b831d4a3c725ed2b4ee15ef9f789b97f5679eb # save the attached .config to linux build tree mkdir build_dir COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross O=build_dir ARCH=nds32 SHELL=/bin/bash If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@xxxxxxxxx> All errors (new ones prefixed by >>): In file included from mm/migrate.c:47: include/linux/page_idle.h: In function 'page_is_young': >> include/linux/page_idle.h:55:18: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 55 | return test_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:55:18: note: each undeclared identifier is reported only once for each function it appears in >> include/linux/page_idle.h:55:43: error: invalid use of undefined type 'struct page_ext' 55 | return test_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'set_page_young': include/linux/page_idle.h:65:10: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 65 | set_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:65:35: error: invalid use of undefined type 'struct page_ext' 65 | set_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'test_and_clear_page_young': include/linux/page_idle.h:75:28: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 75 | return test_and_clear_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:75:53: error: invalid use of undefined type 'struct page_ext' 75 | return test_and_clear_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'page_is_idle': >> include/linux/page_idle.h:85:18: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 85 | return test_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:85:42: error: invalid use of undefined type 'struct page_ext' 85 | return test_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'set_page_idle': include/linux/page_idle.h:95:10: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 95 | set_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:95:34: error: invalid use of undefined type 'struct page_ext' 95 | set_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'clear_page_idle': include/linux/page_idle.h:105:12: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 105 | clear_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:105:36: error: invalid use of undefined type 'struct page_ext' 105 | clear_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'page_is_young': include/linux/page_idle.h:56:1: error: control reaches end of non-void function [-Werror=return-type] 56 | } | ^ include/linux/page_idle.h: In function 'page_is_idle': include/linux/page_idle.h:86:1: error: control reaches end of non-void function [-Werror=return-type] 86 | } | ^ cc1: some warnings being treated as errors -- In file included from mm/filemap.c:44: include/linux/page_idle.h: In function 'page_is_young': >> include/linux/page_idle.h:55:18: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 55 | return test_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:55:18: note: each undeclared identifier is reported only once for each function it appears in >> include/linux/page_idle.h:55:43: error: invalid use of undefined type 'struct page_ext' 55 | return test_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'set_page_young': include/linux/page_idle.h:65:10: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 65 | set_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:65:35: error: invalid use of undefined type 'struct page_ext' 65 | set_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'test_and_clear_page_young': include/linux/page_idle.h:75:28: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 75 | return test_and_clear_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:75:53: error: invalid use of undefined type 'struct page_ext' 75 | return test_and_clear_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'page_is_idle': >> include/linux/page_idle.h:85:18: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 85 | return test_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:85:42: error: invalid use of undefined type 'struct page_ext' 85 | return test_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'set_page_idle': include/linux/page_idle.h:95:10: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 95 | set_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:95:34: error: invalid use of undefined type 'struct page_ext' 95 | set_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'clear_page_idle': include/linux/page_idle.h:105:12: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 105 | clear_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:105:36: error: invalid use of undefined type 'struct page_ext' 105 | clear_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'page_is_idle': include/linux/page_idle.h:86:1: error: control reaches end of non-void function [-Werror=return-type] 86 | } | ^ cc1: some warnings being treated as errors -- In file included from mm/rmap.c:72: include/linux/page_idle.h: In function 'page_is_young': >> include/linux/page_idle.h:55:18: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 55 | return test_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:55:18: note: each undeclared identifier is reported only once for each function it appears in >> include/linux/page_idle.h:55:43: error: invalid use of undefined type 'struct page_ext' 55 | return test_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'set_page_young': include/linux/page_idle.h:65:10: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 65 | set_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:65:35: error: invalid use of undefined type 'struct page_ext' 65 | set_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'test_and_clear_page_young': include/linux/page_idle.h:75:28: error: 'PAGE_EXT_YOUNG' undeclared (first use in this function) 75 | return test_and_clear_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~~~~~~~~~~~~~ include/linux/page_idle.h:75:53: error: invalid use of undefined type 'struct page_ext' 75 | return test_and_clear_bit(PAGE_EXT_YOUNG, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'page_is_idle': >> include/linux/page_idle.h:85:18: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 85 | return test_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:85:42: error: invalid use of undefined type 'struct page_ext' 85 | return test_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'set_page_idle': include/linux/page_idle.h:95:10: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 95 | set_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:95:34: error: invalid use of undefined type 'struct page_ext' 95 | set_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'clear_page_idle': include/linux/page_idle.h:105:12: error: 'PAGE_EXT_IDLE' undeclared (first use in this function) 105 | clear_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~~~~~~~~~~~~ include/linux/page_idle.h:105:36: error: invalid use of undefined type 'struct page_ext' 105 | clear_bit(PAGE_EXT_IDLE, &page_ext->flags); | ^~ include/linux/page_idle.h: In function 'test_and_clear_page_young': include/linux/page_idle.h:76:1: error: control reaches end of non-void function [-Werror=return-type] 76 | } | ^ cc1: some warnings being treated as errors vim +/PAGE_EXT_YOUNG +55 include/linux/page_idle.h 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 47 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 48 static inline bool page_is_young(struct page *page) 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 49 { f86e4271978bd9 Yang Shi 2016-06-03 50 struct page_ext *page_ext = lookup_page_ext(page); f86e4271978bd9 Yang Shi 2016-06-03 51 f86e4271978bd9 Yang Shi 2016-06-03 52 if (unlikely(!page_ext)) f86e4271978bd9 Yang Shi 2016-06-03 53 return false; f86e4271978bd9 Yang Shi 2016-06-03 54 f86e4271978bd9 Yang Shi 2016-06-03 @55 return test_bit(PAGE_EXT_YOUNG, &page_ext->flags); 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 56 } 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 57 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 58 static inline void set_page_young(struct page *page) 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 59 { f86e4271978bd9 Yang Shi 2016-06-03 60 struct page_ext *page_ext = lookup_page_ext(page); f86e4271978bd9 Yang Shi 2016-06-03 61 f86e4271978bd9 Yang Shi 2016-06-03 62 if (unlikely(!page_ext)) f86e4271978bd9 Yang Shi 2016-06-03 63 return; f86e4271978bd9 Yang Shi 2016-06-03 64 f86e4271978bd9 Yang Shi 2016-06-03 65 set_bit(PAGE_EXT_YOUNG, &page_ext->flags); 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 66 } 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 67 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 68 static inline bool test_and_clear_page_young(struct page *page) 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 69 { f86e4271978bd9 Yang Shi 2016-06-03 70 struct page_ext *page_ext = lookup_page_ext(page); f86e4271978bd9 Yang Shi 2016-06-03 71 f86e4271978bd9 Yang Shi 2016-06-03 72 if (unlikely(!page_ext)) f86e4271978bd9 Yang Shi 2016-06-03 73 return false; f86e4271978bd9 Yang Shi 2016-06-03 74 f86e4271978bd9 Yang Shi 2016-06-03 @75 return test_and_clear_bit(PAGE_EXT_YOUNG, &page_ext->flags); 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 76 } 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 77 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 78 static inline bool page_is_idle(struct page *page) 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 79 { f86e4271978bd9 Yang Shi 2016-06-03 80 struct page_ext *page_ext = lookup_page_ext(page); f86e4271978bd9 Yang Shi 2016-06-03 81 f86e4271978bd9 Yang Shi 2016-06-03 82 if (unlikely(!page_ext)) f86e4271978bd9 Yang Shi 2016-06-03 83 return false; f86e4271978bd9 Yang Shi 2016-06-03 84 f86e4271978bd9 Yang Shi 2016-06-03 @85 return test_bit(PAGE_EXT_IDLE, &page_ext->flags); 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 86 } 33c3fc71c8cfa3 Vladimir Davydov 2015-09-09 87 :::::: The code at line 55 was first introduced by commit :::::: f86e4271978bd93db466d6a95dad4b0fdcdb04f6 mm: check the return value of lookup_page_ext for all call sites :::::: TO: Yang Shi <yang.shi@xxxxxxxxxx> :::::: CC: Linus Torvalds <torvalds@xxxxxxxxxxxxxxxxxxxx> --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@xxxxxxxxxxxx
Attachment:
.config.gz
Description: application/gzip