From: kbuild test robot <lkp@intel.com> To: Andy Shevchenko <andriy.shevchenko@linux.intel.com>, Andrew Morton <akpm@linux-foundation.org>, linux-kernel@vger.kernel.org, Steven Rostedt <rostedt@goodmis.org>, Rasmus Villemoes <linux@rasmusvillemoes.dk>, Joe Perches <joe@perches.com> Cc: kbuild-all@lists.01.org, Linux Memory Management List <linux-mm@kvack.org>, Andy Shevchenko <andriy.shevchenko@linux.intel.com> Subject: Re: [PATCH v4 7/7] kernel.h: Split out might_sleep() and friends Date: Sat, 25 Apr 2020 01:45:59 +0800 [thread overview] Message-ID: <202004250159.fzdnZfm6%lkp@intel.com> (raw) In-Reply-To: <20200422125201.37618-7-andriy.shevchenko@linux.intel.com> [-- Attachment #1: Type: text/plain, Size: 4519 bytes --] Hi Andy, I love your patch! Yet something to improve: [auto build test ERROR on next-20200423] [cannot apply to tip/locking/core rcu/dev linus/master tip/x86/core v5.7-rc2 v5.7-rc1 v5.6 v5.7-rc2] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Andy-Shevchenko/drm-shmobile-Reduce-include-dependencies/20200424-044529 base: aefe184e814492e36b2ca350c1522bd71b09b520 config: parisc-allnoconfig (attached as .config) compiler: hppa-linux-gcc (GCC) 9.3.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=parisc If you fix the issue, kindly add following tag as appropriate Reported-by: kbuild test robot <lkp@intel.com> All errors (new ones prefixed by >>): In file included from include/asm-generic/current.h:5, from ./arch/parisc/include/generated/asm/current.h:1, from include/linux/might_sleep.h:6, from include/linux/kernel.h:14, from arch/parisc/include/asm/bug.h:5, from include/linux/bug.h:5, from include/linux/page-flags.h:10, from kernel/bounds.c:10: include/linux/thread_info.h: In function 'copy_overflow': >> include/linux/thread_info.h:135:2: error: implicit declaration of function 'WARN' [-Werror=implicit-function-declaration] 135 | WARN(1, "Buffer overflow detected (%d < %lu)!\n", size, count); | ^~~~ include/linux/thread_info.h: In function 'check_copy_size': >> include/linux/thread_info.h:151:6: error: implicit declaration of function 'WARN_ON_ONCE' [-Werror=implicit-function-declaration] 151 | if (WARN_ON_ONCE(bytes > INT_MAX)) | ^~~~~~~~~~~~ cc1: some warnings being treated as errors make[2]: *** [scripts/Makefile.build:100: kernel/bounds.s] Error 1 make[2]: Target '__build' not remade because of errors. make[1]: *** [Makefile:1142: prepare0] Error 2 make[1]: Target 'prepare' not remade because of errors. make: *** [Makefile:180: sub-make] Error 2 vim +/WARN +135 include/linux/thread_info.h b0377fedb65280 Al Viro 2017-06-29 132 b0377fedb65280 Al Viro 2017-06-29 133 static inline void copy_overflow(int size, unsigned long count) b0377fedb65280 Al Viro 2017-06-29 134 { b0377fedb65280 Al Viro 2017-06-29 @135 WARN(1, "Buffer overflow detected (%d < %lu)!\n", size, count); b0377fedb65280 Al Viro 2017-06-29 136 } b0377fedb65280 Al Viro 2017-06-29 137 9dd819a15162f8 Kees Cook 2019-09-25 138 static __always_inline __must_check bool b0377fedb65280 Al Viro 2017-06-29 139 check_copy_size(const void *addr, size_t bytes, bool is_source) b0377fedb65280 Al Viro 2017-06-29 140 { b0377fedb65280 Al Viro 2017-06-29 141 int sz = __compiletime_object_size(addr); b0377fedb65280 Al Viro 2017-06-29 142 if (unlikely(sz >= 0 && sz < bytes)) { b0377fedb65280 Al Viro 2017-06-29 143 if (!__builtin_constant_p(bytes)) b0377fedb65280 Al Viro 2017-06-29 144 copy_overflow(sz, bytes); b0377fedb65280 Al Viro 2017-06-29 145 else if (is_source) b0377fedb65280 Al Viro 2017-06-29 146 __bad_copy_from(); b0377fedb65280 Al Viro 2017-06-29 147 else b0377fedb65280 Al Viro 2017-06-29 148 __bad_copy_to(); b0377fedb65280 Al Viro 2017-06-29 149 return false; b0377fedb65280 Al Viro 2017-06-29 150 } 6d13de1489b6bf Kees Cook 2019-12-04 @151 if (WARN_ON_ONCE(bytes > INT_MAX)) 6d13de1489b6bf Kees Cook 2019-12-04 152 return false; b0377fedb65280 Al Viro 2017-06-29 153 check_object_size(addr, bytes, is_source); b0377fedb65280 Al Viro 2017-06-29 154 return true; b0377fedb65280 Al Viro 2017-06-29 155 } b0377fedb65280 Al Viro 2017-06-29 156 :::::: The code at line 135 was first introduced by commit :::::: b0377fedb6528087ed319b0d054d6ed82240372c copy_{to,from}_user(): consolidate object size checks :::::: TO: Al Viro <viro@zeniv.linux.org.uk> :::::: CC: Al Viro <viro@zeniv.linux.org.uk> --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org [-- Attachment #2: .config.gz --] [-- Type: application/gzip, Size: 5611 bytes --]
WARNING: multiple messages have this Message-ID (diff)
From: kbuild test robot <lkp@intel.com> To: kbuild-all@lists.01.org Subject: Re: [PATCH v4 7/7] kernel.h: Split out might_sleep() and friends Date: Sat, 25 Apr 2020 01:45:59 +0800 [thread overview] Message-ID: <202004250159.fzdnZfm6%lkp@intel.com> (raw) In-Reply-To: <20200422125201.37618-7-andriy.shevchenko@linux.intel.com> [-- Attachment #1: Type: text/plain, Size: 4606 bytes --] Hi Andy, I love your patch! Yet something to improve: [auto build test ERROR on next-20200423] [cannot apply to tip/locking/core rcu/dev linus/master tip/x86/core v5.7-rc2 v5.7-rc1 v5.6 v5.7-rc2] [if your patch is applied to the wrong git tree, please drop us a note to help improve the system. BTW, we also suggest to use '--base' option to specify the base tree in git format-patch, please see https://stackoverflow.com/a/37406982] url: https://github.com/0day-ci/linux/commits/Andy-Shevchenko/drm-shmobile-Reduce-include-dependencies/20200424-044529 base: aefe184e814492e36b2ca350c1522bd71b09b520 config: parisc-allnoconfig (attached as .config) compiler: hppa-linux-gcc (GCC) 9.3.0 reproduce: wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # save the attached .config to linux build tree COMPILER_INSTALL_PATH=$HOME/0day GCC_VERSION=9.3.0 make.cross ARCH=parisc If you fix the issue, kindly add following tag as appropriate Reported-by: kbuild test robot <lkp@intel.com> All errors (new ones prefixed by >>): In file included from include/asm-generic/current.h:5, from ./arch/parisc/include/generated/asm/current.h:1, from include/linux/might_sleep.h:6, from include/linux/kernel.h:14, from arch/parisc/include/asm/bug.h:5, from include/linux/bug.h:5, from include/linux/page-flags.h:10, from kernel/bounds.c:10: include/linux/thread_info.h: In function 'copy_overflow': >> include/linux/thread_info.h:135:2: error: implicit declaration of function 'WARN' [-Werror=implicit-function-declaration] 135 | WARN(1, "Buffer overflow detected (%d < %lu)!\n", size, count); | ^~~~ include/linux/thread_info.h: In function 'check_copy_size': >> include/linux/thread_info.h:151:6: error: implicit declaration of function 'WARN_ON_ONCE' [-Werror=implicit-function-declaration] 151 | if (WARN_ON_ONCE(bytes > INT_MAX)) | ^~~~~~~~~~~~ cc1: some warnings being treated as errors make[2]: *** [scripts/Makefile.build:100: kernel/bounds.s] Error 1 make[2]: Target '__build' not remade because of errors. make[1]: *** [Makefile:1142: prepare0] Error 2 make[1]: Target 'prepare' not remade because of errors. make: *** [Makefile:180: sub-make] Error 2 vim +/WARN +135 include/linux/thread_info.h b0377fedb65280 Al Viro 2017-06-29 132 b0377fedb65280 Al Viro 2017-06-29 133 static inline void copy_overflow(int size, unsigned long count) b0377fedb65280 Al Viro 2017-06-29 134 { b0377fedb65280 Al Viro 2017-06-29 @135 WARN(1, "Buffer overflow detected (%d < %lu)!\n", size, count); b0377fedb65280 Al Viro 2017-06-29 136 } b0377fedb65280 Al Viro 2017-06-29 137 9dd819a15162f8 Kees Cook 2019-09-25 138 static __always_inline __must_check bool b0377fedb65280 Al Viro 2017-06-29 139 check_copy_size(const void *addr, size_t bytes, bool is_source) b0377fedb65280 Al Viro 2017-06-29 140 { b0377fedb65280 Al Viro 2017-06-29 141 int sz = __compiletime_object_size(addr); b0377fedb65280 Al Viro 2017-06-29 142 if (unlikely(sz >= 0 && sz < bytes)) { b0377fedb65280 Al Viro 2017-06-29 143 if (!__builtin_constant_p(bytes)) b0377fedb65280 Al Viro 2017-06-29 144 copy_overflow(sz, bytes); b0377fedb65280 Al Viro 2017-06-29 145 else if (is_source) b0377fedb65280 Al Viro 2017-06-29 146 __bad_copy_from(); b0377fedb65280 Al Viro 2017-06-29 147 else b0377fedb65280 Al Viro 2017-06-29 148 __bad_copy_to(); b0377fedb65280 Al Viro 2017-06-29 149 return false; b0377fedb65280 Al Viro 2017-06-29 150 } 6d13de1489b6bf Kees Cook 2019-12-04 @151 if (WARN_ON_ONCE(bytes > INT_MAX)) 6d13de1489b6bf Kees Cook 2019-12-04 152 return false; b0377fedb65280 Al Viro 2017-06-29 153 check_object_size(addr, bytes, is_source); b0377fedb65280 Al Viro 2017-06-29 154 return true; b0377fedb65280 Al Viro 2017-06-29 155 } b0377fedb65280 Al Viro 2017-06-29 156 :::::: The code at line 135 was first introduced by commit :::::: b0377fedb6528087ed319b0d054d6ed82240372c copy_{to,from}_user(): consolidate object size checks :::::: TO: Al Viro <viro@zeniv.linux.org.uk> :::::: CC: Al Viro <viro@zeniv.linux.org.uk> --- 0-DAY CI Kernel Test Service, Intel Corporation https://lists.01.org/hyperkitty/list/kbuild-all(a)lists.01.org [-- Attachment #2: config.gz --] [-- Type: application/gzip, Size: 5611 bytes --]
next prev parent reply other threads:[~2020-04-24 17:46 UTC|newest] Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top 2020-04-22 12:51 [PATCH v4 1/7] drm: shmobile: Reduce include dependencies Andy Shevchenko 2020-04-22 12:51 ` [PATCH v4 2/7] kernel.h: Drop unneeded <linux/kernel.h> inclusion from other headers Andy Shevchenko 2020-04-22 12:51 ` [PATCH v4 3/7] kernel.h: Move oops_in_progress to printk.h Andy Shevchenko 2020-04-22 12:51 ` [PATCH v4 4/7] kernel.h: Split out min()/max() et al helpers Andy Shevchenko 2020-04-22 14:52 ` Joe Perches 2020-04-22 15:44 ` Andy Shevchenko 2020-04-22 15:51 ` Joe Perches 2020-04-23 9:33 ` Rasmus Villemoes 2020-04-22 12:51 ` [PATCH v4 5/7] kernel.h: Split out mathematical helpers Andy Shevchenko 2020-04-22 12:52 ` [PATCH v4 6/7] kernel.h: Split out panic and oops helpers Andy Shevchenko 2020-04-24 17:04 ` kbuild test robot 2020-04-24 17:04 ` kbuild test robot 2020-04-24 17:27 ` kbuild test robot 2020-04-24 17:27 ` kbuild test robot 2020-04-22 12:52 ` [PATCH v4 7/7] kernel.h: Split out might_sleep() and friends Andy Shevchenko 2020-04-24 15:49 ` kbuild test robot 2020-04-24 15:49 ` kbuild test robot 2020-04-24 17:45 ` kbuild test robot [this message] 2020-04-24 17:45 ` kbuild test robot
Reply instructions: You may reply publicly to this message via plain-text email using any one of the following methods: * Save the following mbox file, import it into your mail client, and reply-to-all from there: mbox Avoid top-posting and favor interleaved quoting: https://en.wikipedia.org/wiki/Posting_style#Interleaved_style * Reply using the --to, --cc, and --in-reply-to switches of git-send-email(1): git send-email \ --in-reply-to=202004250159.fzdnZfm6%lkp@intel.com \ --to=lkp@intel.com \ --cc=akpm@linux-foundation.org \ --cc=andriy.shevchenko@linux.intel.com \ --cc=joe@perches.com \ --cc=kbuild-all@lists.01.org \ --cc=linux-kernel@vger.kernel.org \ --cc=linux-mm@kvack.org \ --cc=linux@rasmusvillemoes.dk \ --cc=rostedt@goodmis.org \ /path/to/YOUR_REPLY https://kernel.org/pub/software/scm/git/docs/git-send-email.html * If your mail client supports setting the In-Reply-To header via mailto: links, try the mailto: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes, see mirroring instructions on how to clone and mirror all data and code used by this external index.