All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-stable-rc:linux-4.19.y 9415/9999] include/linux/compat.h:497:51: warning: this statement may fall through
@ 2021-06-23 13:14 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-06-23 13:14 UTC (permalink / raw)
  To: kbuild-all

[-- Attachment #1: Type: text/plain, Size: 14956 bytes --]

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.19.y
head:   d183c8e2647a7d45202c14a33631f6c09020f8ac
commit: 17d6ece980ea1b044c8631defc9686267def2edd [9415/9999] mips: fix build when "48 bits virtual memory" is enabled
config: mips-randconfig-r035-20210622 (attached as .config)
compiler: mips64-linux-gcc (GCC) 9.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/stable/linux-stable-rc.git/commit/?id=17d6ece980ea1b044c8631defc9686267def2edd
        git remote add linux-stable-rc https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git
        git fetch --no-tags linux-stable-rc linux-4.19.y
        git checkout 17d6ece980ea1b044c8631defc9686267def2edd
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=mips 

If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp@intel.com>

All warnings (new ones prefixed by >>):

         | ^~~~~~~~~~~~~~
   include/linux/signal.h:130:13: warning: this statement may fall through [-Wimplicit-fallthrough=]
     130 |   r->sig[1] = op(a1, b1);     \
         |             ^
   include/linux/signal.h:141:1: note: in expansion of macro '_SIG_SET_BINOP'
     141 | _SIG_SET_BINOP(sigorsets, _sig_or)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h:131:2: note: here
     131 |  case 1:        \
         |  ^~~~
   include/linux/signal.h:141:1: note: in expansion of macro '_SIG_SET_BINOP'
     141 | _SIG_SET_BINOP(sigorsets, _sig_or)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h: In function 'sigandsets':
   include/linux/signal.h:127:13: warning: this statement may fall through [-Wimplicit-fallthrough=]
     127 |   r->sig[2] = op(a2, b2);     \
         |             ^
   include/linux/signal.h:144:1: note: in expansion of macro '_SIG_SET_BINOP'
     144 | _SIG_SET_BINOP(sigandsets, _sig_and)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h:128:2: note: here
     128 |  case 2:        \
         |  ^~~~
   include/linux/signal.h:144:1: note: in expansion of macro '_SIG_SET_BINOP'
     144 | _SIG_SET_BINOP(sigandsets, _sig_and)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h:130:13: warning: this statement may fall through [-Wimplicit-fallthrough=]
     130 |   r->sig[1] = op(a1, b1);     \
         |             ^
   include/linux/signal.h:144:1: note: in expansion of macro '_SIG_SET_BINOP'
     144 | _SIG_SET_BINOP(sigandsets, _sig_and)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h:131:2: note: here
     131 |  case 1:        \
         |  ^~~~
   include/linux/signal.h:144:1: note: in expansion of macro '_SIG_SET_BINOP'
     144 | _SIG_SET_BINOP(sigandsets, _sig_and)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h: In function 'sigandnsets':
   include/linux/signal.h:127:13: warning: this statement may fall through [-Wimplicit-fallthrough=]
     127 |   r->sig[2] = op(a2, b2);     \
         |             ^
   include/linux/signal.h:147:1: note: in expansion of macro '_SIG_SET_BINOP'
     147 | _SIG_SET_BINOP(sigandnsets, _sig_andn)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h:128:2: note: here
     128 |  case 2:        \
         |  ^~~~
   include/linux/signal.h:147:1: note: in expansion of macro '_SIG_SET_BINOP'
     147 | _SIG_SET_BINOP(sigandnsets, _sig_andn)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h:130:13: warning: this statement may fall through [-Wimplicit-fallthrough=]
     130 |   r->sig[1] = op(a1, b1);     \
         |             ^
   include/linux/signal.h:147:1: note: in expansion of macro '_SIG_SET_BINOP'
     147 | _SIG_SET_BINOP(sigandnsets, _sig_andn)
         | ^~~~~~~~~~~~~~
   include/linux/signal.h:131:2: note: here
     131 |  case 1:        \
         |  ^~~~
   include/linux/signal.h:147:1: note: in expansion of macro '_SIG_SET_BINOP'
     147 | _SIG_SET_BINOP(sigandnsets, _sig_andn)
         | ^~~~~~~~~~~~~~
   kernel/signal.c: In function 'check_kill_permission':
   kernel/signal.c:834:13: warning: this statement may fall through [-Wimplicit-fallthrough=]
     834 |    if (!sid || sid == task_session(current))
         |        ~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   kernel/signal.c:836:3: note: here
     836 |   default:
         |   ^~~~~~~
   In file included from include/linux/sched/signal.h:6,
                    from include/linux/sched/cputime.h:5,
                    from kernel/signal.c:21:
   include/linux/signal.h: In function 'signotset':
   include/linux/signal.h:159:15: warning: this statement may fall through [-Wimplicit-fallthrough=]
     159 |   set->sig[2] = op(set->sig[2]);    \
         |               ^
   include/linux/signal.h:169:1: note: in expansion of macro '_SIG_SET_OP'
     169 | _SIG_SET_OP(signotset, _sig_not)
         | ^~~~~~~~~~~
   include/linux/signal.h:160:2: note: here
     160 |  case 2: set->sig[1] = op(set->sig[1]);    \
         |  ^~~~
   include/linux/signal.h:169:1: note: in expansion of macro '_SIG_SET_OP'
     169 | _SIG_SET_OP(signotset, _sig_not)
         | ^~~~~~~~~~~
   include/linux/signal.h:160:22: warning: this statement may fall through [-Wimplicit-fallthrough=]
     160 |  case 2: set->sig[1] = op(set->sig[1]);    \
         |                      ^
   include/linux/signal.h:169:1: note: in expansion of macro '_SIG_SET_OP'
     169 | _SIG_SET_OP(signotset, _sig_not)
         | ^~~~~~~~~~~
   include/linux/signal.h:161:2: note: here
     161 |  case 1: set->sig[0] = op(set->sig[0]);    \
         |  ^~~~
   include/linux/signal.h:169:1: note: in expansion of macro '_SIG_SET_OP'
     169 | _SIG_SET_OP(signotset, _sig_not)
         | ^~~~~~~~~~~
   In file included from kernel/signal.c:39:
   include/linux/compat.h: In function 'put_compat_sigset':
>> include/linux/compat.h:497:51: warning: this statement may fall through [-Wimplicit-fallthrough=]
     497 |  case 4: v.sig[7] = (set->sig[3] >> 32); v.sig[6] = set->sig[3];
         |                                          ~~~~~~~~~^~~~~~~~~~~~~
   include/linux/compat.h:498:2: note: here
     498 |  case 3: v.sig[5] = (set->sig[2] >> 32); v.sig[4] = set->sig[2];
         |  ^~~~
   include/linux/compat.h:498:51: warning: this statement may fall through [-Wimplicit-fallthrough=]
     498 |  case 3: v.sig[5] = (set->sig[2] >> 32); v.sig[4] = set->sig[2];
         |                                          ~~~~~~~~~^~~~~~~~~~~~~
   include/linux/compat.h:499:2: note: here
     499 |  case 2: v.sig[3] = (set->sig[1] >> 32); v.sig[2] = set->sig[1];
         |  ^~~~
   include/linux/compat.h:499:51: warning: this statement may fall through [-Wimplicit-fallthrough=]
     499 |  case 2: v.sig[3] = (set->sig[1] >> 32); v.sig[2] = set->sig[1];
         |                                          ~~~~~~~~~^~~~~~~~~~~~~
   include/linux/compat.h:500:2: note: here
     500 |  case 1: v.sig[1] = (set->sig[0] >> 32); v.sig[0] = set->sig[0];
         |  ^~~~
--
   arch/mips/kernel/signal_o32.c:154:17: warning: no previous prototype for 'sys32_rt_sigreturn' [-Wmissing-prototypes]
     154 | asmlinkage void sys32_rt_sigreturn(void)
         |                 ^~~~~~~~~~~~~~~~~~
   arch/mips/kernel/signal_o32.c:256:17: warning: no previous prototype for 'sys32_sigreturn' [-Wmissing-prototypes]
     256 | asmlinkage void sys32_sigreturn(void)
         |                 ^~~~~~~~~~~~~~~
   In file included from arch/mips/include/asm/compat-signal.h:6,
                    from arch/mips/kernel/signal_o32.c:18:
   include/linux/compat.h: In function 'put_compat_sigset':
>> include/linux/compat.h:497:51: warning: this statement may fall through [-Wimplicit-fallthrough=]
     497 |  case 4: v.sig[7] = (set->sig[3] >> 32); v.sig[6] = set->sig[3];
         |                                          ~~~~~~~~~^~~~~~~~~~~~~
   include/linux/compat.h:498:2: note: here
     498 |  case 3: v.sig[5] = (set->sig[2] >> 32); v.sig[4] = set->sig[2];
         |  ^~~~
   include/linux/compat.h:498:51: warning: this statement may fall through [-Wimplicit-fallthrough=]
     498 |  case 3: v.sig[5] = (set->sig[2] >> 32); v.sig[4] = set->sig[2];
         |                                          ~~~~~~~~~^~~~~~~~~~~~~
   include/linux/compat.h:499:2: note: here
     499 |  case 2: v.sig[3] = (set->sig[1] >> 32); v.sig[2] = set->sig[1];
         |  ^~~~
   include/linux/compat.h:499:51: warning: this statement may fall through [-Wimplicit-fallthrough=]
     499 |  case 2: v.sig[3] = (set->sig[1] >> 32); v.sig[2] = set->sig[1];
         |                                          ~~~~~~~~~^~~~~~~~~~~~~
   include/linux/compat.h:500:2: note: here
     500 |  case 1: v.sig[1] = (set->sig[0] >> 32); v.sig[0] = set->sig[0];
         |  ^~~~
--
   drivers/net/wireless/marvell/mwifiex/ie.c: In function 'mwifiex_uap_parse_tail_ies':
>> drivers/net/wireless/marvell/mwifiex/ie.c:372:7: warning: this statement may fall through [-Wimplicit-fallthrough=]
     372 |    if (cfg80211_find_vendor_ie(WLAN_OUI_MICROSOFT,
         |       ^
   drivers/net/wireless/marvell/mwifiex/ie.c:377:3: note: here
     377 |   default:
         |   ^~~~~~~
   In file included from drivers/net/wireless/marvell/mwifiex/main.h:59,
                    from drivers/net/wireless/marvell/mwifiex/ie.c:21:
   At top level:
   drivers/net/wireless/marvell/mwifiex/sdio.h:566:41: warning: 'mwifiex_sdio_sd8801' defined but not used [-Wunused-const-variable=]
     566 | static const struct mwifiex_sdio_device mwifiex_sdio_sd8801 = {
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/marvell/mwifiex/sdio.h:551:41: warning: 'mwifiex_sdio_sd8887' defined but not used [-Wunused-const-variable=]
     551 | static const struct mwifiex_sdio_device mwifiex_sdio_sd8887 = {
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/marvell/mwifiex/sdio.h:535:41: warning: 'mwifiex_sdio_sd8997' defined but not used [-Wunused-const-variable=]
     535 | static const struct mwifiex_sdio_device mwifiex_sdio_sd8997 = {
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/marvell/mwifiex/sdio.h:520:41: warning: 'mwifiex_sdio_sd8897' defined but not used [-Wunused-const-variable=]
     520 | static const struct mwifiex_sdio_device mwifiex_sdio_sd8897 = {
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/marvell/mwifiex/sdio.h:505:41: warning: 'mwifiex_sdio_sd8797' defined but not used [-Wunused-const-variable=]
     505 | static const struct mwifiex_sdio_device mwifiex_sdio_sd8797 = {
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/marvell/mwifiex/sdio.h:490:41: warning: 'mwifiex_sdio_sd8787' defined but not used [-Wunused-const-variable=]
     490 | static const struct mwifiex_sdio_device mwifiex_sdio_sd8787 = {
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/net/wireless/marvell/mwifiex/sdio.h:475:41: warning: 'mwifiex_sdio_sd8786' defined but not used [-Wunused-const-variable=]
     475 | static const struct mwifiex_sdio_device mwifiex_sdio_sd8786 = {
         |                                         ^~~~~~~~~~~~~~~~~~~
   In file included from drivers/net/wireless/marvell/mwifiex/main.h:57,
                    from drivers/net/wireless/marvell/mwifiex/ie.c:21:
   drivers/net/wireless/marvell/mwifiex/pcie.h:310:41: warning: 'mwifiex_pcie8997' defined but not used [-Wunused-const-variable=]
     310 | static const struct mwifiex_pcie_device mwifiex_pcie8997 = {
         |                                         ^~~~~~~~~~~~~~~~
   drivers/net/wireless/marvell/mwifiex/pcie.h:300:41: warning: 'mwifiex_pcie8897' defined but not used [-Wunused-const-variable=]
     300 | static const struct mwifiex_pcie_device mwifiex_pcie8897 = {
         |                                         ^~~~~~~~~~~~~~~~
   drivers/net/wireless/marvell/mwifiex/pcie.h:292:41: warning: 'mwifiex_pcie8766' defined but not used [-Wunused-const-variable=]
     292 | static const struct mwifiex_pcie_device mwifiex_pcie8766 = {
         |                                         ^~~~~~~~~~~~~~~~


vim +497 include/linux/compat.h

fde9fc766e96c4 Matt Redfearn 2018-02-19  484  
fde9fc766e96c4 Matt Redfearn 2018-02-19  485  /*
fde9fc766e96c4 Matt Redfearn 2018-02-19  486   * Defined inline such that size can be compile time constant, which avoids
fde9fc766e96c4 Matt Redfearn 2018-02-19  487   * CONFIG_HARDENED_USERCOPY complaining about copies from task_struct
fde9fc766e96c4 Matt Redfearn 2018-02-19  488   */
fde9fc766e96c4 Matt Redfearn 2018-02-19  489  static inline int
fde9fc766e96c4 Matt Redfearn 2018-02-19  490  put_compat_sigset(compat_sigset_t __user *compat, const sigset_t *set,
fde9fc766e96c4 Matt Redfearn 2018-02-19  491  		  unsigned int size)
fde9fc766e96c4 Matt Redfearn 2018-02-19  492  {
fde9fc766e96c4 Matt Redfearn 2018-02-19  493  	/* size <= sizeof(compat_sigset_t) <= sizeof(sigset_t) */
fde9fc766e96c4 Matt Redfearn 2018-02-19  494  #ifdef __BIG_ENDIAN
fde9fc766e96c4 Matt Redfearn 2018-02-19  495  	compat_sigset_t v;
fde9fc766e96c4 Matt Redfearn 2018-02-19  496  	switch (_NSIG_WORDS) {
fde9fc766e96c4 Matt Redfearn 2018-02-19 @497  	case 4: v.sig[7] = (set->sig[3] >> 32); v.sig[6] = set->sig[3];
fde9fc766e96c4 Matt Redfearn 2018-02-19  498  	case 3: v.sig[5] = (set->sig[2] >> 32); v.sig[4] = set->sig[2];
fde9fc766e96c4 Matt Redfearn 2018-02-19  499  	case 2: v.sig[3] = (set->sig[1] >> 32); v.sig[2] = set->sig[1];
fde9fc766e96c4 Matt Redfearn 2018-02-19  500  	case 1: v.sig[1] = (set->sig[0] >> 32); v.sig[0] = set->sig[0];
fde9fc766e96c4 Matt Redfearn 2018-02-19  501  	}
fde9fc766e96c4 Matt Redfearn 2018-02-19  502  	return copy_to_user(compat, &v, size) ? -EFAULT : 0;
fde9fc766e96c4 Matt Redfearn 2018-02-19  503  #else
fde9fc766e96c4 Matt Redfearn 2018-02-19  504  	return copy_to_user(compat, set, size) ? -EFAULT : 0;
fde9fc766e96c4 Matt Redfearn 2018-02-19  505  #endif
fde9fc766e96c4 Matt Redfearn 2018-02-19  506  }
bebfa1013eee1d Andi Kleen    2006-06-26  507  

:::::: The code at line 497 was first introduced by commit
:::::: fde9fc766e96c494b82931b1d270a9a751be07c0 signals: Move put_compat_sigset to compat.h to silence hardened usercopy

:::::: TO: Matt Redfearn <matt.redfearn@mips.com>
:::::: CC: James Hogan <jhogan@kernel.org>

---
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: 21971 bytes --]

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2021-06-23 13:14 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2021-06-23 13:14 [linux-stable-rc:linux-4.19.y 9415/9999] include/linux/compat.h:497:51: warning: this statement may fall through kernel test robot

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.