All of lore.kernel.org
 help / color / mirror / Atom feed
* [linux-stable-rc:linux-4.19.y 2158/4038] arch/powerpc/include/asm/book3s/64/kup-radix.h:5:26: error: a parameter list without types is only allowed in a function definition
@ 2021-05-07 19:40 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2021-05-07 19:40 UTC (permalink / raw)
  To: kbuild-all

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

Hi Nicholas,

FYI, the error/warning still remains.

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-4.19.y
head:   3c8c23092588a23bf1856a64f58c37f477a413be
commit: 31ebc2fe02df202566d0e36c1106b4902d6e2f8c [2158/4038] powerpc/64s: flush L1D after user accesses
config: powerpc64-randconfig-r025-20210507 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project a3a8a1a15b524d91b5308db68e9d293b34cd88dd)
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
        # install powerpc64 cross compiling tool for clang build
        # apt-get install binutils-powerpc64-linux-gnu
        # https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git/commit/?id=31ebc2fe02df202566d0e36c1106b4902d6e2f8c
        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 31ebc2fe02df202566d0e36c1106b4902d6e2f8c
        # save the attached .config to linux build tree
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 ARCH=powerpc64 

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

All error/warnings (new ones prefixed by >>):

   In file included from arch/powerpc/kernel/asm-offsets.c:16:
   In file included from include/linux/compat.h:12:
   In file included from include/linux/stat.h:19:
   In file included from include/linux/time.h:6:
   In file included from include/linux/seqlock.h:36:
   In file included from include/linux/spinlock.h:54:
   In file included from include/linux/irqflags.h:16:
   In file included from arch/powerpc/include/asm/irqflags.h:12:
   In file included from arch/powerpc/include/asm/hw_irq.h:64:
   In file included from arch/powerpc/include/asm/paca.h:21:
   In file included from arch/powerpc/include/asm/lppaca.h:36:
   In file included from arch/powerpc/include/asm/mmu.h:313:
   In file included from arch/powerpc/include/asm/book3s/64/mmu.h:30:
   In file included from arch/powerpc/include/asm/book3s/64/mmu-hash.h:24:
   arch/powerpc/include/asm/book3s/64/pgtable.h:1292:15: warning: 'const' type qualifier on return type has no effect [-Wignored-qualifiers]
   static inline const int pud_pfn(pud_t pud)
                 ^~~~~~
   In file included from arch/powerpc/kernel/asm-offsets.c:16:
   In file included from include/linux/compat.h:19:
   In file included from include/linux/uaccess.h:14:
   In file included from arch/powerpc/include/asm/uaccess.h:9:
   In file included from arch/powerpc/include/asm/kup.h:10:
>> arch/powerpc/include/asm/book3s/64/kup-radix.h:5:1: warning: declaration specifier missing, defaulting to 'int'
   DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
   ^
   int
>> arch/powerpc/include/asm/book3s/64/kup-radix.h:5:26: error: a parameter list without types is only allowed in a function definition
   DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
                            ^
>> arch/powerpc/include/asm/book3s/64/kup-radix.h:18:6: error: implicit declaration of function 'static_branch_unlikely' [-Werror,-Wimplicit-function-declaration]
           if (static_branch_unlikely(&uaccess_flush_key))
               ^
>> arch/powerpc/include/asm/book3s/64/kup-radix.h:18:30: error: use of undeclared identifier 'uaccess_flush_key'
           if (static_branch_unlikely(&uaccess_flush_key))
                                       ^
   In file included from arch/powerpc/kernel/asm-offsets.c:23:
   include/linux/mman.h:133:9: warning: division by zero is undefined [-Wdivision-by-zero]
                  _calc_vm_trans(flags, MAP_LOCKED,     VM_LOCKED    ) |
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/mman.h:111:21: note: expanded from macro '_calc_vm_trans'
      : ((x) & (bit1)) / ((bit1) / (bit2))))
                       ^ ~~~~~~~~~~~~~~~~~
   include/linux/mman.h:134:9: warning: division by zero is undefined [-Wdivision-by-zero]
                  _calc_vm_trans(flags, MAP_SYNC,       VM_SYNC      );
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/mman.h:110:48: note: expanded from macro '_calc_vm_trans'
     ((bit1) <= (bit2) ? ((x) & (bit1)) * ((bit2) / (bit1)) \
                                                  ^ ~~~~~~
   include/linux/mman.h:134:9: warning: division by zero is undefined [-Wdivision-by-zero]
                  _calc_vm_trans(flags, MAP_SYNC,       VM_SYNC      );
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/mman.h:111:21: note: expanded from macro '_calc_vm_trans'
      : ((x) & (bit1)) / ((bit1) / (bit2))))
                       ^ ~~~~~~~~~~~~~~~~~
   5 warnings and 3 errors generated.
--
   In file included from arch/powerpc/kernel/asm-offsets.c:16:
   In file included from include/linux/compat.h:12:
   In file included from include/linux/stat.h:19:
   In file included from include/linux/time.h:6:
   In file included from include/linux/seqlock.h:36:
   In file included from include/linux/spinlock.h:54:
   In file included from include/linux/irqflags.h:16:
   In file included from arch/powerpc/include/asm/irqflags.h:12:
   In file included from arch/powerpc/include/asm/hw_irq.h:64:
   In file included from arch/powerpc/include/asm/paca.h:21:
   In file included from arch/powerpc/include/asm/lppaca.h:36:
   In file included from arch/powerpc/include/asm/mmu.h:313:
   In file included from arch/powerpc/include/asm/book3s/64/mmu.h:30:
   In file included from arch/powerpc/include/asm/book3s/64/mmu-hash.h:24:
   arch/powerpc/include/asm/book3s/64/pgtable.h:1292:15: warning: 'const' type qualifier on return type has no effect [-Wignored-qualifiers]
   static inline const int pud_pfn(pud_t pud)
                 ^~~~~~
   In file included from arch/powerpc/kernel/asm-offsets.c:16:
   In file included from include/linux/compat.h:19:
   In file included from include/linux/uaccess.h:14:
   In file included from arch/powerpc/include/asm/uaccess.h:9:
   In file included from arch/powerpc/include/asm/kup.h:10:
>> arch/powerpc/include/asm/book3s/64/kup-radix.h:5:1: warning: declaration specifier missing, defaulting to 'int'
   DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
   ^
   int
>> arch/powerpc/include/asm/book3s/64/kup-radix.h:5:26: error: a parameter list without types is only allowed in a function definition
   DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
                            ^
>> arch/powerpc/include/asm/book3s/64/kup-radix.h:18:6: error: implicit declaration of function 'static_branch_unlikely' [-Werror,-Wimplicit-function-declaration]
           if (static_branch_unlikely(&uaccess_flush_key))
               ^
>> arch/powerpc/include/asm/book3s/64/kup-radix.h:18:30: error: use of undeclared identifier 'uaccess_flush_key'
           if (static_branch_unlikely(&uaccess_flush_key))
                                       ^
   In file included from arch/powerpc/kernel/asm-offsets.c:23:
   include/linux/mman.h:133:9: warning: division by zero is undefined [-Wdivision-by-zero]
                  _calc_vm_trans(flags, MAP_LOCKED,     VM_LOCKED    ) |
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/mman.h:111:21: note: expanded from macro '_calc_vm_trans'
      : ((x) & (bit1)) / ((bit1) / (bit2))))
                       ^ ~~~~~~~~~~~~~~~~~
   include/linux/mman.h:134:9: warning: division by zero is undefined [-Wdivision-by-zero]
                  _calc_vm_trans(flags, MAP_SYNC,       VM_SYNC      );
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/mman.h:110:48: note: expanded from macro '_calc_vm_trans'
     ((bit1) <= (bit2) ? ((x) & (bit1)) * ((bit2) / (bit1)) \
                                                  ^ ~~~~~~
   include/linux/mman.h:134:9: warning: division by zero is undefined [-Wdivision-by-zero]
                  _calc_vm_trans(flags, MAP_SYNC,       VM_SYNC      );
                  ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
   include/linux/mman.h:111:21: note: expanded from macro '_calc_vm_trans'
      : ((x) & (bit1)) / ((bit1) / (bit2))))
                       ^ ~~~~~~~~~~~~~~~~~
   5 warnings and 3 errors generated.
   make[2]: *** [./Kbuild:56: arch/powerpc/kernel/asm-offsets.s] Error 1
   make[2]: Target '__build' not remade because of errors.
   make[1]: *** [Makefile:1123: prepare0] Error 2
   make[1]: Target 'prepare' not remade because of errors.
   make: *** [Makefile:146: sub-make] Error 2
   make: Target 'prepare' not remade because of errors.


vim +5 arch/powerpc/include/asm/book3s/64/kup-radix.h

     4	
   > 5	DECLARE_STATIC_KEY_FALSE(uaccess_flush_key);
     6	
     7	/* Prototype for function defined in exceptions-64s.S */
     8	void do_uaccess_flush(void);
     9	
    10	static __always_inline void allow_user_access(void __user *to, const void __user *from,
    11						      unsigned long size)
    12	{
    13	}
    14	
    15	static inline void prevent_user_access(void __user *to, const void __user *from,
    16					       unsigned long size)
    17	{
  > 18		if (static_branch_unlikely(&uaccess_flush_key))
    19			do_uaccess_flush();
    20	}
    21	

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

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

only message in thread, other threads:[~2021-05-07 19:40 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-05-07 19:40 [linux-stable-rc:linux-4.19.y 2158/4038] arch/powerpc/include/asm/book3s/64/kup-radix.h:5:26: error: a parameter list without types is only allowed in a function definition 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.