tree:
https://git.kernel.org/pub/scm/linux/kernel/git/arnd/playground.git
arm-kill-set_fs-5
head: 1086c1cb895540fdf215aecf3ed4a96843d6633e
commit: 175180f99fef4558bae0c2fb337150706c4297ea [6/40] ARM: traps: use get_kernel_nofault
instead of set_fs()
config: arm-randconfig-r022-20200917 (attached as .config)
compiler: clang version 12.0.0 (
https://github.com/llvm/llvm-project
0ff28fa6a75617d61b1aeea77463d6a1684c3c89)
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 arm cross compiling tool for clang build
# apt-get install binutils-arm-linux-gnueabi
git checkout 175180f99fef4558bae0c2fb337150706c4297ea
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=arm
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All errors (new ones prefixed by >>):
arch/arm/kernel/traps.c:82:6: warning: no previous prototype for function
'dump_backtrace_stm' [-Wmissing-prototypes]
void dump_backtrace_stm(u32 *stack, u32 instruction, const char *loglvl)
^
arch/arm/kernel/traps.c:82:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void dump_backtrace_stm(u32 *stack, u32 instruction, const char *loglvl)
^
static
> arch/arm/kernel/traps.c:139:9: error: incompatible pointer types
initializing 'const typeof (val) *' (aka 'const unsigned long *') with an
expression of type 'u32 *' (aka 'unsigned int *')
[-Werror,-Wincompatible-pointer-types]
if
(get_kernel_nofault(val, (u32 *)p))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/uaccess.h:366:21: note: expanded from macro 'get_kernel_nofault'
const typeof(val) *__gk_ptr = (ptr); \
^ ~~~~~
arch/arm/kernel/traps.c:430:17: warning: no previous prototype for function
'do_undefinstr' [-Wmissing-prototypes]
asmlinkage void do_undefinstr(struct pt_regs *regs)
^
arch/arm/kernel/traps.c:430:12: note: declare 'static' if the function is not
intended to be used outside of this translation unit
asmlinkage void do_undefinstr(struct pt_regs *regs)
^
static
arch/arm/kernel/traps.c:495:39: warning: no previous prototype for function
'handle_fiq_as_nmi' [-Wmissing-prototypes]
asmlinkage void __exception_irq_entry handle_fiq_as_nmi(struct pt_regs *regs)
^
arch/arm/kernel/traps.c:495:12: note: declare 'static' if the function is not
intended to be used outside of this translation unit
asmlinkage void __exception_irq_entry handle_fiq_as_nmi(struct pt_regs *regs)
^
static
arch/arm/kernel/traps.c:514:17: warning: no previous prototype for function
'bad_mode' [-Wmissing-prototypes]
asmlinkage void bad_mode(struct pt_regs *regs, int reason)
^
arch/arm/kernel/traps.c:514:12: note: declare 'static' if the function is not
intended to be used outside of this translation unit
asmlinkage void bad_mode(struct pt_regs *regs, int reason)
^
static
arch/arm/kernel/traps.c:587:16: warning: no previous prototype for function
'arm_syscall' [-Wmissing-prototypes]
asmlinkage int arm_syscall(int no, struct pt_regs *regs)
^
arch/arm/kernel/traps.c:587:12: note: declare 'static' if the function is not
intended to be used outside of this translation unit
asmlinkage int arm_syscall(int no, struct pt_regs *regs)
^
static
arch/arm/kernel/traps.c:713:1: warning: no previous prototype for function
'baddataabort' [-Wmissing-prototypes]
baddataabort(int code, unsigned long instr, struct pt_regs *regs)
^
arch/arm/kernel/traps.c:712:12: note: declare 'static' if the function is not
intended to be used outside of this translation unit
asmlinkage void
^
static
arch/arm/kernel/traps.c:738:6: warning: no previous prototype for function
'__pte_error' [-Wmissing-prototypes]
void __pte_error(const char *file, int line, pte_t pte)
^
arch/arm/kernel/traps.c:738:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void __pte_error(const char *file, int line, pte_t pte)
^
static
arch/arm/kernel/traps.c:743:6: warning: no previous prototype for function
'__pmd_error' [-Wmissing-prototypes]
void __pmd_error(const char *file, int line, pmd_t pmd)
^
arch/arm/kernel/traps.c:743:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void __pmd_error(const char *file, int line, pmd_t pmd)
^
static
arch/arm/kernel/traps.c:748:6: warning: no previous prototype for function
'__pgd_error' [-Wmissing-prototypes]
void __pgd_error(const char *file, int line, pgd_t pgd)
^
arch/arm/kernel/traps.c:748:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void __pgd_error(const char *file, int line, pgd_t pgd)
^
static
arch/arm/kernel/traps.c:753:17: warning: no previous prototype for function
'__div0' [-Wmissing-prototypes]
asmlinkage void __div0(void)
^
arch/arm/kernel/traps.c:753:12: note: declare 'static' if the function is not
intended to be used outside of this translation unit
asmlinkage void __div0(void)
^
static
arch/arm/kernel/traps.c:768:13: warning: no previous prototype for function
'trap_init' [-Wmissing-prototypes]
void __init trap_init(void)
^
arch/arm/kernel/traps.c:768:1: note: declare 'static' if the function is not
intended to be used outside of this translation unit
void __init trap_init(void)
^
static
11 warnings and 1 error generated.
#
https://git.kernel.org/pub/scm/linux/kernel/git/arnd/playground.git/commi...
git remote add arnd-playground
https://git.kernel.org/pub/scm/linux/kernel/git/arnd/playground.git
git fetch --no-tags arnd-playground arm-kill-set_fs-5
git checkout 175180f99fef4558bae0c2fb337150706c4297ea
vim +139 arch/arm/kernel/traps.c
117
118 /*
119 * Dump out the contents of some memory nicely...
120 */
121 static void dump_mem(const char *lvl, const char *str, unsigned long bottom,
122 unsigned long top)
123 {
124 unsigned long first;
125 int i;
126
127 printk("%s%s(0x%08lx to 0x%08lx)\n", lvl, str, bottom, top);
128
129 for (first = bottom & ~31; first < top; first += 32) {
130 unsigned long p;
131 char str[sizeof(" 12345678") * 8 + 1];
132
133 memset(str, ' ', sizeof(str));
134 str[sizeof(str) - 1] = '\0';
135
136 for (p = first, i = 0; i < 8 && p < top; i++, p += 4) {
137 if (p >= bottom && p < top) {
138 unsigned long val;
139 if (get_kernel_nofault(val, (u32 *)p))
140 sprintf(str + i * 9, " %08lx", val);
141 else
142 sprintf(str + i * 9, " ????????");
143 }
144 }
145 printk("%s%04lx:%s\n", lvl, first & 0xffff, str);
146 }
147 }
148
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org