Building the Linux kernel with Clang and LLVM
 help / color / mirror / Atom feed
* [avpatel:riscv_misc_fixes_v1 64/68] include/linux/riscv_sse.h:40:9: error: call to undeclared function 'ERR_PTR'; ISO C99 and later do not support implicit function declarations
@ 2025-02-07 10:06 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-02-07 10:06 UTC (permalink / raw)
  To: Himanshu Chauhan; +Cc: llvm, oe-kbuild-all, Anup Patel

tree:   https://github.com/avpatel/linux.git riscv_misc_fixes_v1
head:   f0b453b30038af57df379934d55e6b73af29f50f
commit: cd9c923a931cd68bb0ca73ccfca94d88d51b35e6 [64/68] riscv: Introduce HEST SSE notification handlers
config: x86_64-kexec (https://download.01.org/0day-ci/archive/20250207/202502071805.TxL0wcDb-lkp@intel.com/config)
compiler: clang version 19.1.3 (https://github.com/llvm/llvm-project ab51eccf88f5321e7c60591c5546b254b6afab99)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250207/202502071805.TxL0wcDb-lkp@intel.com/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202502071805.TxL0wcDb-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from drivers/acpi/apei/ghes.c:20:
>> include/linux/riscv_sse.h:40:9: error: call to undeclared function 'ERR_PTR'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
      40 |         return ERR_PTR(-EOPNOTSUPP);
         |                ^
>> include/linux/riscv_sse.h:40:18: error: use of undeclared identifier 'EOPNOTSUPP'
      40 |         return ERR_PTR(-EOPNOTSUPP);
         |                         ^
   include/linux/riscv_sse.h:48:10: error: use of undeclared identifier 'EOPNOTSUPP'
      48 |         return -EOPNOTSUPP;
         |                 ^
   include/linux/riscv_sse.h:53:10: error: use of undeclared identifier 'EOPNOTSUPP'
      53 |         return -EOPNOTSUPP;
         |                 ^
   include/linux/riscv_sse.h:61:10: error: use of undeclared identifier 'EOPNOTSUPP'
      61 |         return -EOPNOTSUPP;
         |                 ^
   include/linux/riscv_sse.h:66:10: error: use of undeclared identifier 'EOPNOTSUPP'
      66 |         return -EOPNOTSUPP;
         |                 ^
   In file included from drivers/acpi/apei/ghes.c:21:
   In file included from include/linux/arm_sdei.h:8:
   In file included from include/acpi/ghes.h:5:
   In file included from include/acpi/apei.h:9:
   In file included from include/linux/acpi.h:13:
   In file included from include/linux/resource_ext.h:11:
   In file included from include/linux/slab.h:16:
   In file included from include/linux/gfp.h:7:
   In file included from include/linux/mmzone.h:8:
   In file included from include/linux/spinlock.h:60:
   In file included from include/linux/thread_info.h:60:
   In file included from arch/x86/include/asm/thread_info.h:59:
   In file included from arch/x86/include/asm/cpufeature.h:5:
   In file included from arch/x86/include/asm/processor.h:36:
>> include/linux/err.h:39:35: error: static declaration of 'ERR_PTR' follows non-static declaration
      39 | static inline void * __must_check ERR_PTR(long error)
         |                                   ^
   include/linux/riscv_sse.h:40:9: note: previous implicit declaration is here
      40 |         return ERR_PTR(-EOPNOTSUPP);
         |                ^
   In file included from drivers/acpi/apei/ghes.c:21:
   In file included from include/linux/arm_sdei.h:8:
   In file included from include/acpi/ghes.h:5:
   In file included from include/acpi/apei.h:9:
   In file included from include/linux/acpi.h:14:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:
   In file included from include/linux/module.h:19:
   In file included from include/linux/elf.h:6:
   In file included from arch/x86/include/asm/elf.h:10:
   In file included from arch/x86/include/asm/ia32.h:7:
   In file included from include/linux/compat.h:17:
   In file included from include/linux/fs.h:33:
   In file included from include/linux/percpu-rwsem.h:7:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:98:11: warning: array index 3 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      98 |                 return (set->sig[3] | set->sig[2] |
         |                         ^        ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from drivers/acpi/apei/ghes.c:21:
   In file included from include/linux/arm_sdei.h:8:
   In file included from include/acpi/ghes.h:5:
   In file included from include/acpi/apei.h:9:
   In file included from include/linux/acpi.h:14:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:
   In file included from include/linux/module.h:19:
   In file included from include/linux/elf.h:6:
   In file included from arch/x86/include/asm/elf.h:10:
   In file included from arch/x86/include/asm/ia32.h:7:
   In file included from include/linux/compat.h:17:
   In file included from include/linux/fs.h:33:
   In file included from include/linux/percpu-rwsem.h:7:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:98:25: warning: array index 2 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      98 |                 return (set->sig[3] | set->sig[2] |
         |                                       ^        ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from drivers/acpi/apei/ghes.c:21:
   In file included from include/linux/arm_sdei.h:8:
   In file included from include/acpi/ghes.h:5:
   In file included from include/acpi/apei.h:9:
   In file included from include/linux/acpi.h:14:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:
   In file included from include/linux/module.h:19:
   In file included from include/linux/elf.h:6:
   In file included from arch/x86/include/asm/elf.h:10:
   In file included from arch/x86/include/asm/ia32.h:7:
   In file included from include/linux/compat.h:17:
   In file included from include/linux/fs.h:33:
   In file included from include/linux/percpu-rwsem.h:7:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:99:4: warning: array index 1 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      99 |                         set->sig[1] | set->sig[0]) == 0;
         |                         ^        ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from drivers/acpi/apei/ghes.c:21:
   In file included from include/linux/arm_sdei.h:8:
   In file included from include/acpi/ghes.h:5:
   In file included from include/acpi/apei.h:9:
   In file included from include/linux/acpi.h:14:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:
   In file included from include/linux/module.h:19:
   In file included from include/linux/elf.h:6:
   In file included from arch/x86/include/asm/elf.h:10:
   In file included from arch/x86/include/asm/ia32.h:7:
   In file included from include/linux/compat.h:17:
   In file included from include/linux/fs.h:33:
   In file included from include/linux/percpu-rwsem.h:7:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:101:11: warning: array index 1 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
     101 |                 return (set->sig[1] | set->sig[0]) == 0;
         |                         ^        ~
   arch/x86/include/asm/signal.h:24:2: note: array 'sig' declared here
      24 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from drivers/acpi/apei/ghes.c:21:
   In file included from include/linux/arm_sdei.h:8:
   In file included from include/acpi/ghes.h:5:
   In file included from include/acpi/apei.h:9:
   In file included from include/linux/acpi.h:14:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:


vim +/ERR_PTR +40 include/linux/riscv_sse.h

d32a860341afc8 Clément Léger    2024-12-06  31  
27dc1f134b3612 Himanshu Chauhan 2023-10-26  32  int sse_register_ghes(struct ghes *ghes, sse_event_handler *lo_cb,
27dc1f134b3612 Himanshu Chauhan 2023-10-26  33  		      sse_event_handler *hi_cb);
27dc1f134b3612 Himanshu Chauhan 2023-10-26  34  int sse_unregister_ghes(struct ghes *ghes);
d32a860341afc8 Clément Léger    2024-12-06  35  #else
d32a860341afc8 Clément Léger    2024-12-06  36  static inline struct sse_event *sse_event_register(u32 event_num, u32 priority,
d32a860341afc8 Clément Léger    2024-12-06  37  						   sse_event_handler *handler,
d32a860341afc8 Clément Léger    2024-12-06  38  						   void *arg)
d32a860341afc8 Clément Léger    2024-12-06  39  {
d32a860341afc8 Clément Léger    2024-12-06 @40  	return ERR_PTR(-EOPNOTSUPP);
d32a860341afc8 Clément Léger    2024-12-06  41  }
d32a860341afc8 Clément Léger    2024-12-06  42  

:::::: The code at line 40 was first introduced by commit
:::::: d32a860341afc8f2002e3df3c3135d6a337b28b8 drivers: firmware: add riscv SSE support

:::::: TO: Clément Léger <cleger@rivosinc.com>
:::::: CC: Anup Patel <anup@brainfault.org>

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki

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

only message in thread, other threads:[~2025-02-07 10:07 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-02-07 10:06 [avpatel:riscv_misc_fixes_v1 64/68] include/linux/riscv_sse.h:40:9: error: call to undeclared function 'ERR_PTR'; ISO C99 and later do not support implicit function declarations kernel test robot

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox