Re: [PATCH v2 08/19] ARC: mm: switch pgtable_t back to struct page *
by kernel test robot
Hi Vineet,
I love your patch! Yet something to improve:
[auto build test ERROR on arc/for-next]
[also build test ERROR on linux/master linus/master v5.14-rc5 next-20210812]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Vineet-Gupta/ARC-mm-updates-supp...
base: https://git.kernel.org/pub/scm/linux/kernel/git/vgupta/arc.git for-next
config: arc-randconfig-s032-20210812 (attached as .config)
compiler: arceb-elf-gcc (GCC) 10.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-348-gf0e6938b-dirty
# https://github.com/0day-ci/linux/commit/36e618e081c5a49b2aff51823c5f01204...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Vineet-Gupta/ARC-mm-updates-support-3-4-levels-and-asm-generic-pgalloc/20210813-074023
git checkout 36e618e081c5a49b2aff51823c5f012045e902ef
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=arc
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/arc/mm/init.c:35:13: warning: no previous prototype for 'arc_get_mem_sz' [-Wmissing-prototypes]
35 | long __init arc_get_mem_sz(void)
| ^~~~~~~~~~~~~~
arch/arc/mm/init.c:88:13: warning: no previous prototype for 'setup_arch_memory' [-Wmissing-prototypes]
88 | void __init setup_arch_memory(void)
| ^~~~~~~~~~~~~~~~~
In file included from <command-line>:
arch/arc/mm/init.c: In function 'mem_init':
>> include/linux/compiler_types.h:328:38: error: call to '__compiletime_assert_328' declared with attribute error: BUILD_BUG_ON failed: (PTRS_PER_PGD * sizeof(pgd_t)) > PAGE_SIZE
328 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^
include/linux/compiler_types.h:309:4: note: in definition of macro '__compiletime_assert'
309 | prefix ## suffix(); \
| ^~~~~~
include/linux/compiler_types.h:328:2: note: in expansion of macro '_compiletime_assert'
328 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:39:37: note: in expansion of macro 'compiletime_assert'
39 | #define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
| ^~~~~~~~~~~~~~~~~~
include/linux/build_bug.h:50:2: note: in expansion of macro 'BUILD_BUG_ON_MSG'
50 | BUILD_BUG_ON_MSG(condition, "BUILD_BUG_ON failed: " #condition)
| ^~~~~~~~~~~~~~~~
arch/arc/mm/init.c:193:2: note: in expansion of macro 'BUILD_BUG_ON'
193 | BUILD_BUG_ON((PTRS_PER_PGD * sizeof(pgd_t)) > PAGE_SIZE);
| ^~~~~~~~~~~~
vim +/__compiletime_assert_328 +328 include/linux/compiler_types.h
eb5c2d4b45e3d2 Will Deacon 2020-07-21 314
eb5c2d4b45e3d2 Will Deacon 2020-07-21 315 #define _compiletime_assert(condition, msg, prefix, suffix) \
eb5c2d4b45e3d2 Will Deacon 2020-07-21 316 __compiletime_assert(condition, msg, prefix, suffix)
eb5c2d4b45e3d2 Will Deacon 2020-07-21 317
eb5c2d4b45e3d2 Will Deacon 2020-07-21 318 /**
eb5c2d4b45e3d2 Will Deacon 2020-07-21 319 * compiletime_assert - break build and emit msg if condition is false
eb5c2d4b45e3d2 Will Deacon 2020-07-21 320 * @condition: a compile-time constant condition to check
eb5c2d4b45e3d2 Will Deacon 2020-07-21 321 * @msg: a message to emit if condition is false
eb5c2d4b45e3d2 Will Deacon 2020-07-21 322 *
eb5c2d4b45e3d2 Will Deacon 2020-07-21 323 * In tradition of POSIX assert, this macro will break the build if the
eb5c2d4b45e3d2 Will Deacon 2020-07-21 324 * supplied condition is *false*, emitting the supplied error message if the
eb5c2d4b45e3d2 Will Deacon 2020-07-21 325 * compiler has support to do so.
eb5c2d4b45e3d2 Will Deacon 2020-07-21 326 */
eb5c2d4b45e3d2 Will Deacon 2020-07-21 327 #define compiletime_assert(condition, msg) \
eb5c2d4b45e3d2 Will Deacon 2020-07-21 @328 _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
eb5c2d4b45e3d2 Will Deacon 2020-07-21 329
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month
[linux-next:master 5325/7963] fs/file.c:401:54: sparse: sparse: incorrect type in initializer (different address spaces)
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: 4b358aabb93a2c654cd1dcab1a25a589f6e2b153
commit: 9cf1d7d830f4a586dfa4ddcaf9eae3959e0708ef [5325/7963] ARC: cmpxchg/xchg: rewrite as macros to make type safe
config: arc-randconfig-s031-20210813 (attached as .config)
compiler: arc-elf-gcc (GCC) 10.3.0
reproduce:
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# apt-get install sparse
# sparse version: v0.6.3-348-gf0e6938b-dirty
# https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commi...
git remote add linux-next https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git
git fetch --no-tags linux-next master
git checkout 9cf1d7d830f4a586dfa4ddcaf9eae3959e0708ef
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=arc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
sparse warnings: (new ones prefixed by >>)
fs/file.c:350:17: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct file **old_fds @@ got struct file [noderef] __rcu **fd @@
fs/file.c:350:17: sparse: expected struct file **old_fds
fs/file.c:350:17: sparse: got struct file [noderef] __rcu **fd
fs/file.c:351:17: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct file **new_fds @@ got struct file [noderef] __rcu **fd @@
fs/file.c:351:17: sparse: expected struct file **new_fds
fs/file.c:351:17: sparse: got struct file [noderef] __rcu **fd
fs/file.c:366:17: sparse: sparse: incompatible types in comparison expression (different address spaces):
fs/file.c:366:17: sparse: struct file [noderef] __rcu *
fs/file.c:366:17: sparse: struct file *
>> fs/file.c:401:54: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct file *file @@ got struct file [noderef] __rcu *[assigned] _val_ @@
fs/file.c:441:28: sparse: sparse: incorrect type in initializer (different address spaces) @@ expected struct fdtable [noderef] __rcu *fdt @@ got struct fdtable * @@
fs/file.c:608:14: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct file *file @@ got struct file [noderef] __rcu * @@
fs/file.c:762:14: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct file *file @@ got struct file [noderef] __rcu * @@
fs/file.c:813:30: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct file *file @@ got struct file [noderef] __rcu * @@
fs/file.c:1038:16: sparse: sparse: incorrect type in assignment (different address spaces) @@ expected struct file *tofree @@ got struct file [noderef] __rcu * @@
vim +401 fs/file.c
02afc6267f6d55 Al Viro 2008-05-08 382
ce08b62d18b3f9 Oleg Nesterov 2014-01-11 383 static struct fdtable *close_files(struct files_struct * files)
7cf4dc3c8dbfdf Al Viro 2012-08-15 384 {
7cf4dc3c8dbfdf Al Viro 2012-08-15 385 /*
7cf4dc3c8dbfdf Al Viro 2012-08-15 386 * It is safe to dereference the fd table without RCU or
7cf4dc3c8dbfdf Al Viro 2012-08-15 387 * ->file_lock because this is the last reference to the
ce08b62d18b3f9 Oleg Nesterov 2014-01-11 388 * files structure.
7cf4dc3c8dbfdf Al Viro 2012-08-15 389 */
ce08b62d18b3f9 Oleg Nesterov 2014-01-11 390 struct fdtable *fdt = rcu_dereference_raw(files->fdt);
9b80a184eaadc1 Alexey Dobriyan 2016-09-02 391 unsigned int i, j = 0;
ce08b62d18b3f9 Oleg Nesterov 2014-01-11 392
7cf4dc3c8dbfdf Al Viro 2012-08-15 393 for (;;) {
7cf4dc3c8dbfdf Al Viro 2012-08-15 394 unsigned long set;
7cf4dc3c8dbfdf Al Viro 2012-08-15 395 i = j * BITS_PER_LONG;
7cf4dc3c8dbfdf Al Viro 2012-08-15 396 if (i >= fdt->max_fds)
7cf4dc3c8dbfdf Al Viro 2012-08-15 397 break;
7cf4dc3c8dbfdf Al Viro 2012-08-15 398 set = fdt->open_fds[j++];
7cf4dc3c8dbfdf Al Viro 2012-08-15 399 while (set) {
7cf4dc3c8dbfdf Al Viro 2012-08-15 400 if (set & 1) {
7cf4dc3c8dbfdf Al Viro 2012-08-15 @401 struct file * file = xchg(&fdt->fd[i], NULL);
7cf4dc3c8dbfdf Al Viro 2012-08-15 402 if (file) {
7cf4dc3c8dbfdf Al Viro 2012-08-15 403 filp_close(file, files);
388a4c88064e7e Paul E. McKenney 2017-10-24 404 cond_resched();
7cf4dc3c8dbfdf Al Viro 2012-08-15 405 }
7cf4dc3c8dbfdf Al Viro 2012-08-15 406 }
7cf4dc3c8dbfdf Al Viro 2012-08-15 407 i++;
7cf4dc3c8dbfdf Al Viro 2012-08-15 408 set >>= 1;
7cf4dc3c8dbfdf Al Viro 2012-08-15 409 }
7cf4dc3c8dbfdf Al Viro 2012-08-15 410 }
ce08b62d18b3f9 Oleg Nesterov 2014-01-11 411
ce08b62d18b3f9 Oleg Nesterov 2014-01-11 412 return fdt;
7cf4dc3c8dbfdf Al Viro 2012-08-15 413 }
7cf4dc3c8dbfdf Al Viro 2012-08-15 414
:::::: The code at line 401 was first introduced by commit
:::::: 7cf4dc3c8dbfdfde163d4636f621cf99a1f63bfb move files_struct-related bits from kernel/exit.c to fs/file.c
:::::: TO: Al Viro <viro(a)zeniv.linux.org.uk>
:::::: CC: Al Viro <viro(a)zeniv.linux.org.uk>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month
[linux-stable-rc:linux-5.10.y 749/1625] arch/powerpc/kernel/sys_ppc32.c:94:16: error: no previous prototype for function 'compat_sys_ftruncate64'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.10.y
head: 81212a8abbf61ea75f691938b24d57cc1633e11c
commit: a024e88f8ab79a7b7e15337096d4f5f77edc6a49 [749/1625] powerpc/barrier: Avoid collision with clang's __lwsync macro
config: powerpc-randconfig-r035-20210813 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 62df4df41c939205b2dc0a2a3bfb75b8c1ed74fa)
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/stable/linux-stable-rc.gi...
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-5.10.y
git checkout a024e88f8ab79a7b7e15337096d4f5f77edc6a49
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Note: the linux-stable-rc/linux-5.10.y HEAD 81212a8abbf61ea75f691938b24d57cc1633e11c builds fine.
It only hurts bisectibility.
All errors (new ones prefixed by >>):
In file included from arch/powerpc/include/asm/hardirq.h:6:
In file included from include/linux/irq.h:20:
In file included from include/linux/io.h:13:
In file included from arch/powerpc/include/asm/io.h:604:
arch/powerpc/include/asm/io-defs.h:49:1: error: performing pointer arithmetic on a null pointer has undefined behavior [-Werror,-Wnull-pointer-arithmetic]
DEF_PCI_AC_NORET(outsb, (unsigned long p, const void *b, unsigned long c),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/powerpc/include/asm/io.h:601:3: note: expanded from macro 'DEF_PCI_AC_NORET'
__do_##name al; \
^~~~~~~~~~~~~~
<scratch space>:181:1: note: expanded from here
__do_outsb
^
arch/powerpc/include/asm/io.h:544:58: note: expanded from macro '__do_outsb'
#define __do_outsb(p, b, n) writesb((PCI_IO_ADDR)_IO_BASE+(p),(b),(n))
~~~~~~~~~~~~~~~~~~~~~^
In file included from arch/powerpc/kernel/sys_ppc32.c:30:
In file included from include/linux/syscalls.h:84:
In file included from include/trace/syscall.h:7:
In file included from include/linux/trace_events.h:9:
In file included from include/linux/hardirq.h:10:
In file included from arch/powerpc/include/asm/hardirq.h:6:
In file included from include/linux/irq.h:20:
In file included from include/linux/io.h:13:
In file included from arch/powerpc/include/asm/io.h:604:
arch/powerpc/include/asm/io-defs.h:51:1: error: performing pointer arithmetic on a null pointer has undefined behavior [-Werror,-Wnull-pointer-arithmetic]
DEF_PCI_AC_NORET(outsw, (unsigned long p, const void *b, unsigned long c),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/powerpc/include/asm/io.h:601:3: note: expanded from macro 'DEF_PCI_AC_NORET'
__do_##name al; \
^~~~~~~~~~~~~~
<scratch space>:183:1: note: expanded from here
__do_outsw
^
arch/powerpc/include/asm/io.h:545:58: note: expanded from macro '__do_outsw'
#define __do_outsw(p, b, n) writesw((PCI_IO_ADDR)_IO_BASE+(p),(b),(n))
~~~~~~~~~~~~~~~~~~~~~^
In file included from arch/powerpc/kernel/sys_ppc32.c:30:
In file included from include/linux/syscalls.h:84:
In file included from include/trace/syscall.h:7:
In file included from include/linux/trace_events.h:9:
In file included from include/linux/hardirq.h:10:
In file included from arch/powerpc/include/asm/hardirq.h:6:
In file included from include/linux/irq.h:20:
In file included from include/linux/io.h:13:
In file included from arch/powerpc/include/asm/io.h:604:
arch/powerpc/include/asm/io-defs.h:53:1: error: performing pointer arithmetic on a null pointer has undefined behavior [-Werror,-Wnull-pointer-arithmetic]
DEF_PCI_AC_NORET(outsl, (unsigned long p, const void *b, unsigned long c),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
arch/powerpc/include/asm/io.h:601:3: note: expanded from macro 'DEF_PCI_AC_NORET'
__do_##name al; \
^~~~~~~~~~~~~~
<scratch space>:185:1: note: expanded from here
__do_outsl
^
arch/powerpc/include/asm/io.h:546:58: note: expanded from macro '__do_outsl'
#define __do_outsl(p, b, n) writesl((PCI_IO_ADDR)_IO_BASE+(p),(b),(n))
~~~~~~~~~~~~~~~~~~~~~^
arch/powerpc/kernel/sys_ppc32.c:51:15: error: no previous prototype for function 'compat_sys_mmap2' [-Werror,-Wmissing-prototypes]
unsigned long compat_sys_mmap2(unsigned long addr, size_t len,
^
arch/powerpc/kernel/sys_ppc32.c:51:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
unsigned long compat_sys_mmap2(unsigned long addr, size_t len,
^
static
arch/powerpc/kernel/sys_ppc32.c:64:16: error: no previous prototype for function 'compat_sys_pread64' [-Werror,-Wmissing-prototypes]
compat_ssize_t compat_sys_pread64(unsigned int fd, char __user *ubuf, compat_size_t count,
^
arch/powerpc/kernel/sys_ppc32.c:64:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
compat_ssize_t compat_sys_pread64(unsigned int fd, char __user *ubuf, compat_size_t count,
^
static
arch/powerpc/kernel/sys_ppc32.c:70:16: error: no previous prototype for function 'compat_sys_pwrite64' [-Werror,-Wmissing-prototypes]
compat_ssize_t compat_sys_pwrite64(unsigned int fd, const char __user *ubuf, compat_size_t count,
^
arch/powerpc/kernel/sys_ppc32.c:70:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
compat_ssize_t compat_sys_pwrite64(unsigned int fd, const char __user *ubuf, compat_size_t count,
^
static
arch/powerpc/kernel/sys_ppc32.c:76:16: error: no previous prototype for function 'compat_sys_readahead' [-Werror,-Wmissing-prototypes]
compat_ssize_t compat_sys_readahead(int fd, u32 r4, u32 offhi, u32 offlo, u32 count)
^
arch/powerpc/kernel/sys_ppc32.c:76:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
compat_ssize_t compat_sys_readahead(int fd, u32 r4, u32 offhi, u32 offlo, u32 count)
^
static
arch/powerpc/kernel/sys_ppc32.c:81:16: error: no previous prototype for function 'compat_sys_truncate64' [-Werror,-Wmissing-prototypes]
asmlinkage int compat_sys_truncate64(const char __user * path, u32 reg4,
^
arch/powerpc/kernel/sys_ppc32.c:81:12: note: declare 'static' if the function is not intended to be used outside of this translation unit
asmlinkage int compat_sys_truncate64(const char __user * path, u32 reg4,
^
static
arch/powerpc/kernel/sys_ppc32.c:87:17: error: no previous prototype for function 'compat_sys_fallocate' [-Werror,-Wmissing-prototypes]
asmlinkage long compat_sys_fallocate(int fd, int mode, u32 offhi, u32 offlo,
^
arch/powerpc/kernel/sys_ppc32.c:87:12: note: declare 'static' if the function is not intended to be used outside of this translation unit
asmlinkage long compat_sys_fallocate(int fd, int mode, u32 offhi, u32 offlo,
^
static
>> arch/powerpc/kernel/sys_ppc32.c:94:16: error: no previous prototype for function 'compat_sys_ftruncate64' [-Werror,-Wmissing-prototypes]
asmlinkage int compat_sys_ftruncate64(unsigned int fd, u32 reg4, unsigned long high,
^
arch/powerpc/kernel/sys_ppc32.c:94:12: note: declare 'static' if the function is not intended to be used outside of this translation unit
asmlinkage int compat_sys_ftruncate64(unsigned int fd, u32 reg4, unsigned long high,
^
static
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
vim +/compat_sys_ftruncate64 +94 arch/powerpc/kernel/sys_ppc32.c
^1da177e4c3f41 arch/ppc64/kernel/sys_ppc32.c Linus Torvalds 2005-04-16 86
97ac73506c0ba9 arch/powerpc/kernel/sys_ppc32.c Amit Arora 2007-07-17 @87 asmlinkage long compat_sys_fallocate(int fd, int mode, u32 offhi, u32 offlo,
97ac73506c0ba9 arch/powerpc/kernel/sys_ppc32.c Amit Arora 2007-07-17 88 u32 lenhi, u32 lenlo)
97ac73506c0ba9 arch/powerpc/kernel/sys_ppc32.c Amit Arora 2007-07-17 89 {
edf292c76b884a arch/powerpc/kernel/sys_ppc32.c Dominik Brodowski 2018-03-19 90 return ksys_fallocate(fd, mode, ((loff_t)offhi << 32) | offlo,
97ac73506c0ba9 arch/powerpc/kernel/sys_ppc32.c Amit Arora 2007-07-17 91 ((loff_t)lenhi << 32) | lenlo);
97ac73506c0ba9 arch/powerpc/kernel/sys_ppc32.c Amit Arora 2007-07-17 92 }
97ac73506c0ba9 arch/powerpc/kernel/sys_ppc32.c Amit Arora 2007-07-17 93
b09a4913b15d25 arch/powerpc/kernel/sys_ppc32.c Stephen Rothwell 2005-10-18 @94 asmlinkage int compat_sys_ftruncate64(unsigned int fd, u32 reg4, unsigned long high,
^1da177e4c3f41 arch/ppc64/kernel/sys_ppc32.c Linus Torvalds 2005-04-16 95 unsigned long low)
^1da177e4c3f41 arch/ppc64/kernel/sys_ppc32.c Linus Torvalds 2005-04-16 96 {
411d9475cf901b arch/powerpc/kernel/sys_ppc32.c Dominik Brodowski 2018-03-11 97 return ksys_ftruncate(fd, (high << 32) | low);
^1da177e4c3f41 arch/ppc64/kernel/sys_ppc32.c Linus Torvalds 2005-04-16 98 }
^1da177e4c3f41 arch/ppc64/kernel/sys_ppc32.c Linus Torvalds 2005-04-16 99
:::::: The code at line 94 was first introduced by commit
:::::: b09a4913b15d2544f8918f05b9937cb4e99a2319 powerpc: change sys32_ to compat_sys_
:::::: TO: Stephen Rothwell <sfr(a)canb.auug.org.au>
:::::: CC: Stephen Rothwell <sfr(a)canb.auug.org.au>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month
[linux-stable-rc:linux-5.10.y 749/1625] arch/powerpc/kernel/eeh.c:1568:12: error: unused function 'proc_eeh_show'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux-stable-rc.git linux-5.10.y
head: 81212a8abbf61ea75f691938b24d57cc1633e11c
commit: a024e88f8ab79a7b7e15337096d4f5f77edc6a49 [749/1625] powerpc/barrier: Avoid collision with clang's __lwsync macro
config: powerpc-randconfig-r005-20210813 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 62df4df41c939205b2dc0a2a3bfb75b8c1ed74fa)
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/stable/linux-stable-rc.gi...
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-5.10.y
git checkout a024e88f8ab79a7b7e15337096d4f5f77edc6a49
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=powerpc
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/powerpc/kernel/eeh.c:1568:12: error: unused function 'proc_eeh_show' [-Werror,-Wunused-function]
static int proc_eeh_show(struct seq_file *m, void *v)
^
1 error generated.
--
>> arch/powerpc/platforms/powernv/pci-cxl.c:173:19: error: unused function 'get_cxl_module' [-Werror,-Wunused-function]
static inline int get_cxl_module(void) { return 0; }
^
1 error generated.
vim +/proc_eeh_show +1568 arch/powerpc/kernel/eeh.c
ec33d36e5ab5d5 arch/powerpc/kernel/eeh.c Gavin Shan 2015-03-26 1567
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 @1568 static int proc_eeh_show(struct seq_file *m, void *v)
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1569 {
2ec5a0adf60c23 arch/powerpc/kernel/eeh.c Gavin Shan 2014-02-12 1570 if (!eeh_enabled()) {
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1571 seq_printf(m, "EEH Subsystem is globally disabled\n");
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1572 seq_printf(m, "eeh_total_mmio_ffs=%llu\n", eeh_stats.total_mmio_ffs);
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1573 } else {
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1574 seq_printf(m, "EEH Subsystem is enabled\n");
177bc9367efe89 arch/ppc64/kernel/eeh.c Linas Vepstas 2005-11-03 1575 seq_printf(m,
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1576 "no device=%llu\n"
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1577 "no device node=%llu\n"
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1578 "no config address=%llu\n"
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1579 "check not wanted=%llu\n"
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1580 "eeh_total_mmio_ffs=%llu\n"
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1581 "eeh_false_positives=%llu\n"
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1582 "eeh_slot_resets=%llu\n",
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1583 eeh_stats.no_device,
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1584 eeh_stats.no_dn,
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1585 eeh_stats.no_cfg_addr,
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1586 eeh_stats.ignored_check,
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1587 eeh_stats.total_mmio_ffs,
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1588 eeh_stats.false_positives,
e575f8db1ed8e7 arch/powerpc/platforms/pseries/eeh.c Gavin Shan 2012-02-29 1589 eeh_stats.slot_resets);
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1590 }
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1591
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1592 return 0;
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1593 }
^1da177e4c3f41 arch/ppc64/kernel/eeh.c Linus Torvalds 2005-04-16 1594
:::::: The code at line 1568 was first introduced by commit
:::::: 1da177e4c3f41524e886b7f1b8a0c1fc7321cac2 Linux-2.6.12-rc2
:::::: TO: Linus Torvalds <torvalds(a)ppc970.osdl.org>
:::::: CC: Linus Torvalds <torvalds(a)ppc970.osdl.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month
[intel-linux-intel-lts:5.4/yocto 63/1142] drivers/gpu/drm/kmb/kmb_crtc.c:101:6: warning: variable 'vsync_end_offset' set but not used
by kernel test robot
tree: https://github.com/intel/linux-intel-lts.git 5.4/yocto
head: eeb611e5394c56d45c5cc8f7dc484c9f19e93143
commit: 5b522e237ca8396c9f947adca5090316dbec5e4c [63/1142] drm/kmb: Set hardcoded values to LCD_VSYNC_START
config: arm64-allyesconfig (attached as .config)
compiler: aarch64-linux-gcc (GCC) 10.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://github.com/intel/linux-intel-lts/commit/5b522e237ca8396c9f947adca...
git remote add intel-linux-intel-lts https://github.com/intel/linux-intel-lts.git
git fetch --no-tags intel-linux-intel-lts 5.4/yocto
git checkout 5b522e237ca8396c9f947adca5090316dbec5e4c
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross ARCH=arm64
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
drivers/gpu/drm/kmb/kmb_crtc.c: In function 'kmb_crtc_mode_set_nofb':
>> drivers/gpu/drm/kmb/kmb_crtc.c:101:6: warning: variable 'vsync_end_offset' set but not used [-Wunused-but-set-variable]
101 | int vsync_end_offset;
| ^~~~~~~~~~~~~~~~
>> drivers/gpu/drm/kmb/kmb_crtc.c:100:6: warning: variable 'vsync_start_offset' set but not used [-Wunused-but-set-variable]
100 | int vsync_start_offset;
| ^~~~~~~~~~~~~~~~~~
vim +/vsync_end_offset +101 drivers/gpu/drm/kmb/kmb_crtc.c
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 94
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 95 static void kmb_crtc_mode_set_nofb(struct drm_crtc *crtc)
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 96 {
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 97 struct drm_display_mode *m = &crtc->state->adjusted_mode;
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 98 struct drm_device *dev = crtc->dev;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 99 struct videomode vm;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 @100 int vsync_start_offset;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 @101 int vsync_end_offset;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 102 unsigned int ctrl = 0;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 103
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 104 vm.vfront_porch = m->crtc_vsync_start - m->crtc_vdisplay;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 105 vm.vback_porch = m->crtc_vtotal - m->crtc_vsync_end;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 106 vm.vsync_len = m->crtc_vsync_end - m->crtc_vsync_start;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 107 vm.hfront_porch = m->crtc_hsync_start - m->crtc_hdisplay;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 108 vm.hback_porch = m->crtc_htotal - m->crtc_hsync_end;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 109 vm.hsync_len = m->crtc_hsync_end - m->crtc_hsync_start;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 110
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 111 vsync_start_offset = m->crtc_vsync_start - m->crtc_hsync_start;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 112 vsync_end_offset = m->crtc_vsync_end - m->crtc_hsync_end;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 113
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 114 kmb_write_lcd(dev->dev_private, LCD_V_ACTIVEHEIGHT,
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 115 m->crtc_vdisplay - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 116 kmb_write_lcd(dev->dev_private, LCD_V_BACKPORCH, vm.vback_porch - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 117 kmb_write_lcd(dev->dev_private, LCD_V_FRONTPORCH, vm.vfront_porch - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 118 kmb_write_lcd(dev->dev_private, LCD_VSYNC_WIDTH, vm.vsync_len - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 119 kmb_write_lcd(dev->dev_private, LCD_H_ACTIVEWIDTH,
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 120 m->crtc_hdisplay - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 121 kmb_write_lcd(dev->dev_private, LCD_H_BACKPORCH, vm.hback_porch - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 122 kmb_write_lcd(dev->dev_private, LCD_H_FRONTPORCH, vm.hfront_porch - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 123 kmb_write_lcd(dev->dev_private, LCD_HSYNC_WIDTH, vm.hsync_len - 1);
5b522e237ca839 Anitha Chrisanthus 2019-07-12 124 /*this is hardcoded as 0 in the Myriadx code */
5b522e237ca839 Anitha Chrisanthus 2019-07-12 125 kmb_write_lcd(dev->dev_private, LCD_VSYNC_START, 0);
5b522e237ca839 Anitha Chrisanthus 2019-07-12 126 kmb_write_lcd(dev->dev_private, LCD_VSYNC_END, 0);
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 127
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 128 if (m->flags == DRM_MODE_FLAG_INTERLACE) {
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 129 kmb_write_lcd(dev->dev_private,
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 130 LCD_VSYNC_WIDTH_EVEN, vm.vsync_len - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 131 kmb_write_lcd(dev->dev_private,
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 132 LCD_V_BACKPORCH_EVEN, vm.vback_porch - 1);
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 133 kmb_write_lcd(dev->dev_private,
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 134 LCD_V_FRONTPORCH_EVEN, vm.vfront_porch - 1);
5b522e237ca839 Anitha Chrisanthus 2019-07-12 135 kmb_write_lcd(dev->dev_private, LCD_V_ACTIVEHEIGHT_EVEN,
5b522e237ca839 Anitha Chrisanthus 2019-07-12 136 m->crtc_vdisplay - 1);
5b522e237ca839 Anitha Chrisanthus 2019-07-12 137 /*this is hardcoded as 10 in the Myriadx code*/
5b522e237ca839 Anitha Chrisanthus 2019-07-12 138 kmb_write_lcd(dev->dev_private, LCD_VSYNC_START_EVEN, 10);
5b522e237ca839 Anitha Chrisanthus 2019-07-12 139 kmb_write_lcd(dev->dev_private, LCD_VSYNC_END_EVEN, 10);
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 140 }
be391352d5d5a3 Anitha Chrisanthus 2019-01-30 141 /* enable VL1 layer as default */
be391352d5d5a3 Anitha Chrisanthus 2019-01-30 142 ctrl = LCD_CTRL_ENABLE | LCD_CTRL_VL1_ENABLE;
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 143 ctrl |= LCD_CTRL_PROGRESSIVE | LCD_CTRL_TIM_GEN_ENABLE
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 144 | LCD_CTRL_OUTPUT_ENABLED;
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 145 kmb_write_lcd(dev->dev_private, LCD_CONTROL, ctrl);
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 146
c3b85e057bb630 Anitha Chrisanthus 2019-06-20 147 kmb_write_lcd(dev->dev_private, LCD_TIMING_GEN_TRIG, ENABLE);
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 148
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 149 /* TBD */
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 150 /* set clocks here */
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 151 }
767c8610f6fcd7 Anitha Chrisanthus 2018-11-29 152
:::::: The code at line 101 was first introduced by commit
:::::: 767c8610f6fcd7b765189fc01eff0131aa6c19d5 drm/kmb: Add support for KeemBay Display
:::::: TO: Anitha Chrisanthus <anitha.chrisanthus(a)intel.com>
:::::: CC: Li, Yifan <yifan2.li(a)intel.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month
Re: [PATCH v4 1/2] f2fs: introduce proc/fs/f2fs/<dev>/fsck_stack node
by kernel test robot
Hi Yangtao,
I love your patch! Yet something to improve:
[auto build test ERROR on v5.14-rc5]
[cannot apply to f2fs/dev-test next-20210813]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch]
url: https://github.com/0day-ci/linux/commits/Yangtao-Li/f2fs-introduce-proc-f...
base: 36a21d51725af2ce0700c6ebcb6b9594aac658a6
config: m68k-allmodconfig (attached as .config)
compiler: m68k-linux-gcc (GCC) 10.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://github.com/0day-ci/linux/commit/9170231cb55b00262ee1f9240b22b6f1b...
git remote add linux-review https://github.com/0day-ci/linux
git fetch --no-tags linux-review Yangtao-Li/f2fs-introduce-proc-fs-f2fs-dev-fsck_stack-node/20210813-181512
git checkout 9170231cb55b00262ee1f9240b22b6f1b15bb1e1
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-10.3.0 make.cross ARCH=m68k
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 >>):
In file included from fs/f2fs/dir.c:13:
fs/f2fs/f2fs.h: In function 'set_sbi_flag':
>> fs/f2fs/f2fs.h:1977:16: error: implicit declaration of function 'stack_trace_save'; did you mean 'stack_depot_save'? [-Werror=implicit-function-declaration]
1977 | nr_entries = stack_trace_save(entries, ARRAY_SIZE(entries), 0);
| ^~~~~~~~~~~~~~~~
| stack_depot_save
cc1: some warnings being treated as errors
vim +1977 fs/f2fs/f2fs.h
1966
1967 static void set_sbi_flag(struct f2fs_sb_info *sbi, unsigned int type)
1968 {
1969 set_bit(type, &sbi->s_flag);
1970
1971 if (unlikely(type == SBI_NEED_FSCK)) {
1972 unsigned long entries[FSCK_STACK_DEPTH];
1973 depot_stack_handle_t stack, *new;
1974 unsigned int nr_entries;
1975 int i;
1976
> 1977 nr_entries = stack_trace_save(entries, ARRAY_SIZE(entries), 0);
1978 nr_entries = filter_irq_stacks(entries, nr_entries);
1979 stack = stack_depot_save(entries, nr_entries, GFP_KERNEL);
1980 if (!stack)
1981 return;
1982
1983 /* Try to find an existing entry for this backtrace */
1984 for (i = 0; i < sbi->fsck_count; i++)
1985 if (sbi->fsck_stack[i] == stack)
1986 return;
1987
1988 new = krealloc(sbi->fsck_stack, (sbi->fsck_count + 1) *
1989 sizeof(*sbi->fsck_stack), GFP_KERNEL);
1990 if (!new)
1991 return;
1992
1993 sbi->fsck_stack = new;
1994 sbi->fsck_stack[sbi->fsck_count++] = stack;
1995 }
1996 }
1997
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month
[xlnx:master 11563/12376] drivers/net/ethernet/xilinx/xilinx_axienet_main.c:3003:47-48: WARNING this kind of initialization is deprecated (https://www.kernel.org/doc/html/latest/process/deprecated.html#uninitialized-var) (fwd)
by Julia Lawall
Please check the initialization of a variable to itself on line 3001.
thanks,
julia
---------- Forwarded message ----------
Date: Fri, 13 Aug 2021 18:44:39 +0800
From: kernel test robot <lkp(a)intel.com>
To: kbuild(a)lists.01.org
Cc: lkp(a)intel.com, Julia Lawall <julia.lawall(a)lip6.fr>
Subject: [xlnx:master 11563/12376]
drivers/net/ethernet/xilinx/xilinx_axienet_main.c:3003:47-48: WARNING this
kind of initialization is deprecated
(https://www.kernel.org/doc/html/latest/process/deprecated.html#uninitialize
d-var)
CC: kbuild-all(a)lists.01.org
CC: linux-arm-kernel(a)lists.infradead.org
TO: Vishal Sagar <vishal.sagar(a)xilinx.com>
CC: Michal Simek <monstr(a)monstr.eu>
CC: Hyun Kwon <hyun.kwon(a)xilinx.com>
tree: https://github.com/Xilinx/linux-xlnx master
head: af88f405134da108f814cfdf5eac9f2b60f2b800
commit: be1a315c549bd2d6be07219a14335d2e156db988 [11563/12376] staging: xlnxsync: Fix the uapi header license
:::::: branch date: 2 days ago
:::::: commit date: 5 months ago
config: x86_64-randconfig-c022-20210812 (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
Reported-by: Julia Lawall <julia.lawall(a)lip6.fr>
cocci warnings: (new ones prefixed by >>)
>> drivers/net/ethernet/xilinx/xilinx_axienet_main.c:3003:47-48: WARNING this kind of initialization is deprecated (https://www.kernel.org/doc/html/latest/process/deprecated.html#uninitiali...)
vim +3003 drivers/net/ethernet/xilinx/xilinx_axienet_main.c
7033a0f491129a Appana Durga Kedareswara Rao 2020-01-24 2986
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2987 /**
2be586205ca2b8 Srikanth Thokala 2015-05-05 2988 * axienet_probe - Axi Ethernet probe function.
95219aa538e11d Srikanth Thokala 2015-05-05 2989 * @pdev: Pointer to platform device structure.
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2990 *
b0d081c524b46c Michal Simek 2015-05-05 2991 * Return: 0, on success
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2992 * Non-zero error value on failure.
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2993 *
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2994 * This is the probe routine for Axi Ethernet driver. This is called before
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2995 * any other driver routines are invoked. It allocates and sets up the Ethernet
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2996 * device. Parses through device tree and populates fields of
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2997 * axienet_local. It registers the Ethernet device.
8a3b7a252dca9f Daniel Borkmann 2012-01-19 2998 */
2be586205ca2b8 Srikanth Thokala 2015-05-05 2999 static int axienet_probe(struct platform_device *pdev)
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3000 {
4c3b5b0773df3a Appana Durga Kedareswara Rao 2021-01-22 3001 int (*axienet_clk_init)(struct platform_device *pdev,
4c3b5b0773df3a Appana Durga Kedareswara Rao 2021-01-22 3002 struct clk **axi_aclk, struct clk **axis_clk,
4c3b5b0773df3a Appana Durga Kedareswara Rao 2021-01-22 @3003 struct clk **ref_clk, struct clk **tmpclk) =
4c3b5b0773df3a Appana Durga Kedareswara Rao 2021-01-22 3004 axienet_clk_init;
3135d19569c063 Appana Durga Kedareswara Rao 2021-01-22 3005 int ret = 0;
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3006 struct device_node *np;
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3007 struct axienet_local *lp;
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3008 struct net_device *ndev;
da90e38003e2f0 Tobias Klauser 2016-12-07 3009 const void *mac_addr;
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3010 struct resource *ethres;
8495659bf93c8e Srikanth Thokala 2015-05-05 3011 u32 value;
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3012 u16 num_queues = XAE_MAX_QUEUES;
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3013 bool is_tsn = false;
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3014
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3015 is_tsn = of_property_read_bool(pdev->dev.of_node, "xlnx,tsn");
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3016 ret = of_property_read_u16(pdev->dev.of_node, "xlnx,num-queues",
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3017 &num_queues);
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3018 if (ret) {
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3019 if (!is_tsn) {
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3020 #ifndef CONFIG_AXIENET_HAS_MCDMA
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3021 num_queues = 1;
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3022 #endif
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3023 }
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3024 }
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3025 #ifdef CONFIG_XILINX_TSN
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3026 if (is_tsn && (num_queues < XAE_TSN_MIN_QUEUES ||
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3027 num_queues > XAE_MAX_QUEUES))
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3028 num_queues = XAE_MAX_QUEUES;
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3029 #endif
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3030
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3031 ndev = alloc_etherdev_mq(sizeof(*lp), num_queues);
41de8d4cff21a2 Joe Perches 2012-01-29 3032 if (!ndev)
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3033 return -ENOMEM;
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3034
95219aa538e11d Srikanth Thokala 2015-05-05 3035 platform_set_drvdata(pdev, ndev);
e5971b124969cf Pranavi Somisetty 2021-01-22 3036 #ifdef CONFIG_XILINX_TSN
fb5a7597eefba7 Shravya Kumbham 2021-01-22 3037 bool slave = false;
e5971b124969cf Pranavi Somisetty 2021-01-22 3038 if (is_tsn) {
e5971b124969cf Pranavi Somisetty 2021-01-22 3039 slave = of_property_read_bool(pdev->dev.of_node,
e5971b124969cf Pranavi Somisetty 2021-01-22 3040 "xlnx,tsn-slave");
e5971b124969cf Pranavi Somisetty 2021-01-22 3041 if (slave)
e5971b124969cf Pranavi Somisetty 2021-01-22 3042 snprintf(ndev->name, sizeof(ndev->name), "eth2");
e5971b124969cf Pranavi Somisetty 2021-01-22 3043 else
e5971b124969cf Pranavi Somisetty 2021-01-22 3044 snprintf(ndev->name, sizeof(ndev->name), "eth1");
e5971b124969cf Pranavi Somisetty 2021-01-22 3045 }
e5971b124969cf Pranavi Somisetty 2021-01-22 3046 #endif
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3047
95219aa538e11d Srikanth Thokala 2015-05-05 3048 SET_NETDEV_DEV(ndev, &pdev->dev);
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3049 ndev->flags &= ~IFF_MULTICAST; /* clear multicast */
28e24c62ab3062 Eric Dumazet 2013-12-02 3050 ndev->features = NETIF_F_SG;
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3051 ndev->netdev_ops = &axienet_netdev_ops;
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3052 ndev->ethtool_ops = &axienet_ethtool_ops;
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3053
d894be57ca92c8 Jarod Wilson 2016-10-20 3054 /* MTU range: 64 - 9000 */
d894be57ca92c8 Jarod Wilson 2016-10-20 3055 ndev->min_mtu = 64;
d894be57ca92c8 Jarod Wilson 2016-10-20 3056 ndev->max_mtu = XAE_JUMBO_MTU;
d894be57ca92c8 Jarod Wilson 2016-10-20 3057
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3058 lp = netdev_priv(ndev);
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3059 lp->ndev = ndev;
95219aa538e11d Srikanth Thokala 2015-05-05 3060 lp->dev = &pdev->dev;
8a3b7a252dca9f Daniel Borkmann 2012-01-19 3061 lp->options = XAE_OPTION_DEFAULTS;
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3062 lp->num_tx_queues = num_queues;
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3063 lp->num_rx_queues = num_queues;
c5d8859a13f5f3 Saurabh Sengar 2021-01-22 3064 lp->is_tsn = is_tsn;
8b09ca823ffb4e Robert Hancock 2019-06-06 3065 lp->rx_bd_num = RX_BD_NUM_DEFAULT;
8b09ca823ffb4e Robert Hancock 2019-06-06 3066 lp->tx_bd_num = TX_BD_NUM_DEFAULT;
8d6d4d04f7ed81 Saurabh Sengar 2021-01-22 3067
:::::: The code at line 3003 was first introduced by commit
:::::: 4c3b5b0773df3a73938529634e562784458aeb90 net: axienet: Add clock support
:::::: TO: Appana Durga Kedareswara Rao <appana.durga.rao(a)xilinx.com>
:::::: CC: Michal Simek <michal.simek(a)xilinx.com>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month
[xlnx:xlnx_rebase_v5.10 813/1761] drivers/net/ethernet/xilinx/xilinx_axienet_main.c:1141:3: warning: comparison of distinct pointer types ('unsigned long *' and 'typeof (flags) *' (aka 'unsigned int *'))
by kernel test robot
tree: https://github.com/Xilinx/linux-xlnx xlnx_rebase_v5.10
head: e14d4574ca81a569ee6d07e03271f2ae2dad38e4
commit: 1b5d1c43433b3ec5407db48688e717285e7edafe [813/1761] net: xilinx: axiethernet: Add check for transmit data FIFO vacancy
config: s390-randconfig-r012-20210812 (attached as .config)
compiler: clang version 14.0.0 (https://github.com/llvm/llvm-project 767496d19cb9a1fbba57ff08095faa161998ee36)
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 s390 cross compiling tool for clang build
# apt-get install binutils-s390x-linux-gnu
# https://github.com/Xilinx/linux-xlnx/commit/1b5d1c43433b3ec5407db48688e71...
git remote add xlnx https://github.com/Xilinx/linux-xlnx
git fetch --no-tags xlnx xlnx_rebase_v5.10
git checkout 1b5d1c43433b3ec5407db48688e717285e7edafe
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=s390
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
include/asm-generic/io.h:490:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __le32_to_cpu((__le32 __force)__raw_readl(PCI_IOBASE + addr));
~~~~~~~~~~ ^
include/uapi/linux/byteorder/big_endian.h:34:59: note: expanded from macro '__le32_to_cpu'
#define __le32_to_cpu(x) __swab32((__force __u32)(__le32)(x))
^
include/uapi/linux/swab.h:119:21: note: expanded from macro '__swab32'
___constant_swab32(x) : \
^
include/uapi/linux/swab.h:20:12: note: expanded from macro '___constant_swab32'
(((__u32)(x) & (__u32)0x0000ff00UL) << 8) | \
^
In file included from drivers/net/ethernet/xilinx/xilinx_axienet_main.c:28:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:31:
In file included from include/linux/dma-mapping.h:10:
In file included from include/linux/scatterlist.h:9:
In file included from arch/s390/include/asm/io.h:80:
include/asm-generic/io.h:490:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __le32_to_cpu((__le32 __force)__raw_readl(PCI_IOBASE + addr));
~~~~~~~~~~ ^
include/uapi/linux/byteorder/big_endian.h:34:59: note: expanded from macro '__le32_to_cpu'
#define __le32_to_cpu(x) __swab32((__force __u32)(__le32)(x))
^
include/uapi/linux/swab.h:119:21: note: expanded from macro '__swab32'
___constant_swab32(x) : \
^
include/uapi/linux/swab.h:21:12: note: expanded from macro '___constant_swab32'
(((__u32)(x) & (__u32)0x00ff0000UL) >> 8) | \
^
In file included from drivers/net/ethernet/xilinx/xilinx_axienet_main.c:28:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:31:
In file included from include/linux/dma-mapping.h:10:
In file included from include/linux/scatterlist.h:9:
In file included from arch/s390/include/asm/io.h:80:
include/asm-generic/io.h:490:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __le32_to_cpu((__le32 __force)__raw_readl(PCI_IOBASE + addr));
~~~~~~~~~~ ^
include/uapi/linux/byteorder/big_endian.h:34:59: note: expanded from macro '__le32_to_cpu'
#define __le32_to_cpu(x) __swab32((__force __u32)(__le32)(x))
^
include/uapi/linux/swab.h:119:21: note: expanded from macro '__swab32'
___constant_swab32(x) : \
^
include/uapi/linux/swab.h:22:12: note: expanded from macro '___constant_swab32'
(((__u32)(x) & (__u32)0xff000000UL) >> 24)))
^
In file included from drivers/net/ethernet/xilinx/xilinx_axienet_main.c:28:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:31:
In file included from include/linux/dma-mapping.h:10:
In file included from include/linux/scatterlist.h:9:
In file included from arch/s390/include/asm/io.h:80:
include/asm-generic/io.h:490:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __le32_to_cpu((__le32 __force)__raw_readl(PCI_IOBASE + addr));
~~~~~~~~~~ ^
include/uapi/linux/byteorder/big_endian.h:34:59: note: expanded from macro '__le32_to_cpu'
#define __le32_to_cpu(x) __swab32((__force __u32)(__le32)(x))
^
include/uapi/linux/swab.h:120:12: note: expanded from macro '__swab32'
__fswab32(x))
^
In file included from drivers/net/ethernet/xilinx/xilinx_axienet_main.c:28:
In file included from include/linux/etherdevice.h:20:
In file included from include/linux/if_ether.h:19:
In file included from include/linux/skbuff.h:31:
In file included from include/linux/dma-mapping.h:10:
In file included from include/linux/scatterlist.h:9:
In file included from arch/s390/include/asm/io.h:80:
include/asm-generic/io.h:501:33: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
__raw_writeb(value, PCI_IOBASE + addr);
~~~~~~~~~~ ^
include/asm-generic/io.h:511:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
__raw_writew((u16 __force)cpu_to_le16(value), PCI_IOBASE + addr);
~~~~~~~~~~ ^
include/asm-generic/io.h:521:59: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
__raw_writel((u32 __force)cpu_to_le32(value), PCI_IOBASE + addr);
~~~~~~~~~~ ^
include/asm-generic/io.h:609:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
readsb(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:617:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
readsw(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:625:20: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
readsl(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:634:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
writesb(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:643:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
writesw(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
include/asm-generic/io.h:652:21: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
writesl(PCI_IOBASE + addr, buffer, count);
~~~~~~~~~~ ^
>> drivers/net/ethernet/xilinx/xilinx_axienet_main.c:1141:3: warning: comparison of distinct pointer types ('unsigned long *' and 'typeof (flags) *' (aka 'unsigned int *')) [-Wcompare-distinct-pointer-types]
spin_lock_irqsave(&lp->ptp_tx_lock, flags);
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/spinlock.h:384:2: note: expanded from macro 'spin_lock_irqsave'
raw_spin_lock_irqsave(spinlock_check(lock), flags); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/spinlock.h:251:3: note: expanded from macro 'raw_spin_lock_irqsave'
typecheck(unsigned long, flags); \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/typecheck.h:12:18: note: expanded from macro 'typecheck'
(void)(&__dummy == &__dummy2); \
~~~~~~~~ ^ ~~~~~~~~~
drivers/net/ethernet/xilinx/xilinx_axienet_main.c:702:12: warning: unused function 'axienet_free_tx_chain' [-Wunused-function]
static int axienet_free_tx_chain(struct net_device *ndev, u32 first_bd,
^
In file included from drivers/net/ethernet/xilinx/xilinx_axienet_main.c:25:
In file included from include/linux/clk.h:13:
In file included from include/linux/kernel.h:12:
In file included from include/linux/bitops.h:29:
arch/s390/include/asm/bitops.h:90:4: error: invalid operand in inline asm: 'ni $0,${1:b}'
"ni %0,%b1\n"
^
arch/s390/include/asm/bitops.h:90:4: error: invalid operand in inline asm: 'ni $0,${1:b}'
arch/s390/include/asm/bitops.h:90:4: error: invalid operand in inline asm: 'ni $0,${1:b}'
arch/s390/include/asm/bitops.h:69:4: error: invalid operand in inline asm: 'oi $0,${1:b}'
"oi %0,%b1\n"
^
arch/s390/include/asm/bitops.h:69:4: error: invalid operand in inline asm: 'oi $0,${1:b}'
22 warnings and 5 errors generated.
vim +1141 drivers/net/ethernet/xilinx/xilinx_axienet_main.c
1118
1119 if (msg_type == TX_TS_OP_NOOP) {
1120 buf[0] = TX_TS_OP_NOOP;
1121 } else if (msg_type == TX_TS_OP_ONESTEP) {
1122 buf[0] = TX_TS_OP_ONESTEP;
1123 buf[1] = TX_TS_CSUM_UPDATE;
1124 buf[4] = TX_PTP_TS_OFFSET;
1125 buf[6] = TX_PTP_CSUM_OFFSET;
1126 } else {
1127 buf[0] = TX_TS_OP_TWOSTEP;
1128 buf[2] = cur_p->ptp_tx_ts_tag & 0xFF;
1129 buf[3] = (cur_p->ptp_tx_ts_tag >> 8) & 0xFF;
1130 }
1131
1132 if (lp->axienet_config->mactype == XAXIENET_1G ||
1133 lp->axienet_config->mactype == XAXIENET_2_5G) {
1134 memcpy(&val, buf, AXIENET_TS_HEADER_LEN);
1135 swab64s(&val);
1136 memcpy(buf, &val, AXIENET_TS_HEADER_LEN);
1137 } else if (lp->axienet_config->mactype == XAXIENET_10G_25G ||
1138 lp->axienet_config->mactype == XAXIENET_MRMAC) {
1139 memcpy(&tmp, buf, XXVENET_TS_HEADER_LEN);
1140 /* Check for Transmit Data FIFO Vacancy */
> 1141 spin_lock_irqsave(&lp->ptp_tx_lock, flags);
1142 if (!axienet_txts_ior(lp, XAXIFIFO_TXTS_TDFV)) {
1143 spin_unlock_irqrestore(&lp->ptp_tx_lock, flags);
1144 return NETDEV_TX_BUSY;
1145 }
1146 axienet_txts_iow(lp, XAXIFIFO_TXTS_TXFD, tmp);
1147 axienet_txts_iow(lp, XAXIFIFO_TXTS_TLR,
1148 XXVENET_TS_HEADER_LEN);
1149 spin_unlock_irqrestore(&lp->ptp_tx_lock, flags);
1150 }
1151
1152 return 0;
1153 }
1154 #endif
1155
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 1 month