lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Date:   Sat, 22 Oct 2022 12:06:31 +0800
From:   kernel test robot <lkp@...el.com>
To:     Mark Rutland <mark.rutland@....com>
Cc:     llvm@...ts.linux.dev, kbuild-all@...ts.01.org,
        linux-kernel@...r.kernel.org
Subject: [mark:arm64/ftrace/per-callsite-ops 5/12]
 include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not
 defined, evaluates to 0

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/mark/linux.git arm64/ftrace/per-callsite-ops
head:   d0ae0c8983e2bf602a151b421652005bc5477727
commit: ca7f736e799f9a547cf1642c719e9842460ab586 [5/12] WIP: Compiler attributes: disable __cold with function alignment
config: powerpc-randconfig-r011-20221019
compiler: clang version 16.0.0 (https://github.com/llvm/llvm-project 791a7ae1ba3efd6bca96338e10ffde557ba83920)
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 powerpc cross compiling tool for clang build
        # apt-get install binutils-powerpc-linux-gnu
        # https://git.kernel.org/pub/scm/linux/kernel/git/mark/linux.git/commit/?id=ca7f736e799f9a547cf1642c719e9842460ab586
        git remote add mark https://git.kernel.org/pub/scm/linux/kernel/git/mark/linux.git
        git fetch --no-tags mark arm64/ftrace/per-callsite-ops
        git checkout ca7f736e799f9a547cf1642c719e9842460ab586
        # save the config file
        mkdir build_dir && cp config build_dir/.config
        COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=powerpc SHELL=/bin/bash

If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@...el.com>

All errors (new ones prefixed by >>):

   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   1 error generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/lib/sstep.c:1351:31: error: variable 'rc' set but not used [-Werror,-Wunused-but-set-variable]
           unsigned int opcode, ra, rb, rc, rd, spr, u;
                                        ^
   arch/powerpc/lib/sstep.c:1355:21: error: variable 'suffix' set but not used [-Werror,-Wunused-but-set-variable]
           unsigned int word, suffix;
                              ^
   3 errors generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/math-emu/fcmpu.c:15:2: error: variable '_fex' set but not used [-Werror,-Wunused-but-set-variable]
           FP_DECL_EX;
           ^
   include/math-emu/soft-fp.h:94:24: note: expanded from macro 'FP_DECL_EX'
   #define FP_DECL_EX int _fex = 0
                          ^
   arch/powerpc/math-emu/fcmpu.c:13:2: error: variable 'A_c' set but not used [-Werror,-Wunused-but-set-variable]
           FP_DECL_D(A);
           ^
   include/math-emu/double.h:73:23: note: expanded from macro 'FP_DECL_D'
   #define FP_DECL_D(X)            _FP_DECL(2,X)
                                   ^
   include/math-emu/op-common.h:28:14: note: expanded from macro '_FP_DECL'
     _FP_I_TYPE X##_c=0, X##_s=0, X##_e=0; \
                ^
   <scratch space>:75:1: note: expanded from here
   A_c
   ^
   arch/powerpc/math-emu/fcmpu.c:14:2: error: variable 'B_c' set but not used [-Werror,-Wunused-but-set-variable]
           FP_DECL_D(B);
           ^
   include/math-emu/double.h:73:23: note: expanded from macro 'FP_DECL_D'
   #define FP_DECL_D(X)            _FP_DECL(2,X)
                                   ^
   include/math-emu/op-common.h:28:14: note: expanded from macro '_FP_DECL'
     _FP_I_TYPE X##_c=0, X##_s=0, X##_e=0; \
                ^
   <scratch space>:81:1: note: expanded from here
   B_c
   ^
   4 errors generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/math-emu/fctiw.c:14:2: error: variable '_fex' set but not used [-Werror,-Wunused-but-set-variable]
           FP_DECL_EX;
           ^
   include/math-emu/soft-fp.h:94:24: note: expanded from macro 'FP_DECL_EX'
   #define FP_DECL_EX int _fex = 0
                          ^
   2 errors generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/math-emu/fctiwz.c:14:2: error: variable '_fex' set but not used [-Werror,-Wunused-but-set-variable]
           FP_DECL_EX;
           ^
   include/math-emu/soft-fp.h:94:24: note: expanded from macro 'FP_DECL_EX'
   #define FP_DECL_EX int _fex = 0
                          ^
   2 errors generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/math-emu/fsel.c:14:2: error: variable '_fex' set but not used [-Werror,-Wunused-but-set-variable]
           FP_DECL_EX;
           ^
   include/math-emu/soft-fp.h:94:24: note: expanded from macro 'FP_DECL_EX'
   #define FP_DECL_EX int _fex = 0
                          ^
   2 errors generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/mm/nohash/tlb.c:314:13: error: no previous prototype for function 'early_init_mmu_47x' [-Werror,-Wmissing-prototypes]
   void __init early_init_mmu_47x(void)
               ^
   arch/powerpc/mm/nohash/tlb.c:314:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   void __init early_init_mmu_47x(void)
   ^
   static 
   2 errors generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/platforms/4xx/uic.c:274:13: error: no previous prototype for function 'uic_init_tree' [-Werror,-Wmissing-prototypes]
   void __init uic_init_tree(void)
               ^
   arch/powerpc/platforms/4xx/uic.c:274:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   void __init uic_init_tree(void)
   ^
   static 
   arch/powerpc/platforms/4xx/uic.c:319:14: error: no previous prototype for function 'uic_get_irq' [-Werror,-Wmissing-prototypes]
   unsigned int uic_get_irq(void)
                ^
   arch/powerpc/platforms/4xx/uic.c:319:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   unsigned int uic_get_irq(void)
   ^
   static 
   3 errors generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/platforms/4xx/soc.c:193:6: error: no previous prototype for function 'ppc4xx_reset_system' [-Werror,-Wmissing-prototypes]
   void ppc4xx_reset_system(char *cmd)
        ^
   arch/powerpc/platforms/4xx/soc.c:193:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   void ppc4xx_reset_system(char *cmd)
   ^
   static 
   2 errors generated.
--
   In file included from <built-in>:3:
   In file included from include/linux/compiler_types.h:79:
>> include/linux/compiler_attributes.h:84:5: error: 'CONFIG_CC_IS_GCC' is not defined, evaluates to 0 [-Werror,-Wundef]
   #if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
       ^
   arch/powerpc/platforms/44x/idle.c:30:12: error: no previous prototype for function 'ppc44x_idle_init' [-Werror,-Wmissing-prototypes]
   int __init ppc44x_idle_init(void)
              ^
   arch/powerpc/platforms/44x/idle.c:30:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
   int __init ppc44x_idle_init(void)
   ^
   static 
   2 errors generated.


vim +/CONFIG_CC_IS_GCC +84 include/linux/compiler_attributes.h

    77	
    78	/*
    79	 *   gcc: https://gcc.gnu.org/onlinedocs/gcc/Common-Function-Attributes.html#index-cold-function-attribute
    80	 *   gcc: https://gcc.gnu.org/onlinedocs/gcc/Label-Attributes.html#index-cold-label-attribute
    81	 *
    82	 * With GCC, the cold attribute overrides function alignment
    83	 */
  > 84	#if CONFIG_CC_IS_GCC && (CONFIG_FUNCTION_ALIGNMENT == 0)
    85	#define __cold                          __attribute__((__cold__))
    86	#else
    87	#define __cold
    88	#endif
    89	

-- 
0-DAY CI Kernel Test Service
https://01.org/lkp

View attachment "config" of type "text/plain" (233547 bytes)

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ