[tglx-devel:rtmutex 8/20] kernel/rcu/../locking/rtmutex_common.h:58:26: error: 'struct task_struct' has no member named 'pi_waiters'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/tglx/devel.git rtmutex
head: 502cfc4cfd2a79c578c3a82fdd4abd920dde4c6f
commit: 65a9a52c002e0b86b9f4f79101d649fa732d8f86 [8/20] locking/rtmutex: Remove pointless CONFIG_RT_MUTEXES=n stubs
config: arm64-allnoconfig (attached as .config)
compiler: aarch64-linux-gcc (GCC) 9.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://git.kernel.org/pub/scm/linux/kernel/git/tglx/devel.git/commit/?id...
git remote add tglx-devel https://git.kernel.org/pub/scm/linux/kernel/git/tglx/devel.git
git fetch --no-tags tglx-devel rtmutex
git checkout 65a9a52c002e0b86b9f4f79101d649fa732d8f86
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.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 errors (new ones prefixed by >>):
In file included from <command-line>:
kernel/rcu/../locking/rtmutex_common.h: In function 'task_has_pi_waiters':
>> kernel/rcu/../locking/rtmutex_common.h:58:26: error: 'struct task_struct' has no member named 'pi_waiters'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~
include/linux/compiler_types.h:300:9: note: in definition of macro '__compiletime_assert'
300 | if (!(condition)) \
| ^~~~~~~~~
include/linux/compiler_types.h:320:2: note: in expansion of macro '_compiletime_assert'
320 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:2: note: in expansion of macro 'compiletime_assert'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:21: note: in expansion of macro '__native_word'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~
include/asm-generic/rwonce.h:49:2: note: in expansion of macro 'compiletime_assert_rwonce_type'
49 | compiletime_assert_rwonce_type(x); \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/rbtree.h:40:31: note: in expansion of macro 'READ_ONCE'
40 | #define RB_EMPTY_ROOT(root) (READ_ONCE((root)->rb_node) == NULL)
| ^~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:58:10: note: in expansion of macro 'RB_EMPTY_ROOT'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~~~~~~~~~~~~
>> kernel/rcu/../locking/rtmutex_common.h:58:26: error: 'struct task_struct' has no member named 'pi_waiters'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~
include/linux/compiler_types.h:300:9: note: in definition of macro '__compiletime_assert'
300 | if (!(condition)) \
| ^~~~~~~~~
include/linux/compiler_types.h:320:2: note: in expansion of macro '_compiletime_assert'
320 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:2: note: in expansion of macro 'compiletime_assert'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:21: note: in expansion of macro '__native_word'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~
include/asm-generic/rwonce.h:49:2: note: in expansion of macro 'compiletime_assert_rwonce_type'
49 | compiletime_assert_rwonce_type(x); \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/rbtree.h:40:31: note: in expansion of macro 'READ_ONCE'
40 | #define RB_EMPTY_ROOT(root) (READ_ONCE((root)->rb_node) == NULL)
| ^~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:58:10: note: in expansion of macro 'RB_EMPTY_ROOT'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~~~~~~~~~~~~
>> kernel/rcu/../locking/rtmutex_common.h:58:26: error: 'struct task_struct' has no member named 'pi_waiters'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~
include/linux/compiler_types.h:300:9: note: in definition of macro '__compiletime_assert'
300 | if (!(condition)) \
| ^~~~~~~~~
include/linux/compiler_types.h:320:2: note: in expansion of macro '_compiletime_assert'
320 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:2: note: in expansion of macro 'compiletime_assert'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:21: note: in expansion of macro '__native_word'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~
include/asm-generic/rwonce.h:49:2: note: in expansion of macro 'compiletime_assert_rwonce_type'
49 | compiletime_assert_rwonce_type(x); \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/rbtree.h:40:31: note: in expansion of macro 'READ_ONCE'
40 | #define RB_EMPTY_ROOT(root) (READ_ONCE((root)->rb_node) == NULL)
| ^~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:58:10: note: in expansion of macro 'RB_EMPTY_ROOT'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~~~~~~~~~~~~
>> kernel/rcu/../locking/rtmutex_common.h:58:26: error: 'struct task_struct' has no member named 'pi_waiters'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~
include/linux/compiler_types.h:300:9: note: in definition of macro '__compiletime_assert'
300 | if (!(condition)) \
| ^~~~~~~~~
include/linux/compiler_types.h:320:2: note: in expansion of macro '_compiletime_assert'
320 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:2: note: in expansion of macro 'compiletime_assert'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:21: note: in expansion of macro '__native_word'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~
include/asm-generic/rwonce.h:49:2: note: in expansion of macro 'compiletime_assert_rwonce_type'
49 | compiletime_assert_rwonce_type(x); \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/rbtree.h:40:31: note: in expansion of macro 'READ_ONCE'
40 | #define RB_EMPTY_ROOT(root) (READ_ONCE((root)->rb_node) == NULL)
| ^~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:58:10: note: in expansion of macro 'RB_EMPTY_ROOT'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~~~~~~~~~~~~
>> kernel/rcu/../locking/rtmutex_common.h:58:26: error: 'struct task_struct' has no member named 'pi_waiters'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~
include/linux/compiler_types.h:300:9: note: in definition of macro '__compiletime_assert'
300 | if (!(condition)) \
| ^~~~~~~~~
include/linux/compiler_types.h:320:2: note: in expansion of macro '_compiletime_assert'
320 | _compiletime_assert(condition, msg, __compiletime_assert_, __COUNTER__)
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:36:2: note: in expansion of macro 'compiletime_assert'
36 | compiletime_assert(__native_word(t) || sizeof(t) == sizeof(long long), \
| ^~~~~~~~~~~~~~~~~~
include/asm-generic/rwonce.h:49:2: note: in expansion of macro 'compiletime_assert_rwonce_type'
49 | compiletime_assert_rwonce_type(x); \
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/rbtree.h:40:31: note: in expansion of macro 'READ_ONCE'
40 | #define RB_EMPTY_ROOT(root) (READ_ONCE((root)->rb_node) == NULL)
| ^~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:58:10: note: in expansion of macro 'RB_EMPTY_ROOT'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~~~~~~~~~~~~
>> kernel/rcu/../locking/rtmutex_common.h:58:26: error: 'struct task_struct' has no member named 'pi_waiters'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~
include/linux/compiler_types.h:271:13: note: in definition of macro '__unqual_scalar_typeof'
271 | _Generic((x), \
| ^
include/asm-generic/rwonce.h:50:2: note: in expansion of macro '__READ_ONCE'
50 | __READ_ONCE(x); \
| ^~~~~~~~~~~
include/linux/rbtree.h:40:31: note: in expansion of macro 'READ_ONCE'
40 | #define RB_EMPTY_ROOT(root) (READ_ONCE((root)->rb_node) == NULL)
| ^~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:58:10: note: in expansion of macro 'RB_EMPTY_ROOT'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~~~~~~~~~~~~
In file included from arch/arm64/include/asm/rwonce.h:71,
from include/linux/compiler.h:248,
from include/linux/export.h:43,
from include/linux/linkage.h:7,
from include/linux/kernel.h:7,
from kernel/rcu/tree.c:21:
>> kernel/rcu/../locking/rtmutex_common.h:58:26: error: 'struct task_struct' has no member named 'pi_waiters'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~
include/asm-generic/rwonce.h:44:72: note: in definition of macro '__READ_ONCE'
44 | #define __READ_ONCE(x) (*(const volatile __unqual_scalar_typeof(x) *)&(x))
| ^
include/linux/rbtree.h:40:31: note: in expansion of macro 'READ_ONCE'
40 | #define RB_EMPTY_ROOT(root) (READ_ONCE((root)->rb_node) == NULL)
| ^~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:58:10: note: in expansion of macro 'RB_EMPTY_ROOT'
58 | return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
| ^~~~~~~~~~~~~
In file included from kernel/rcu/tree.c:21:
kernel/rcu/../locking/rtmutex_common.h: In function 'task_top_pi_waiter':
kernel/rcu/../locking/rtmutex_common.h:63:19: error: 'struct task_struct' has no member named 'pi_waiters'
63 | return rb_entry(p->pi_waiters.rb_leftmost, struct rt_mutex_waiter,
| ^~
include/linux/kernel.h:708:26: note: in definition of macro 'container_of'
708 | void *__mptr = (void *)(ptr); \
| ^~~
kernel/rcu/../locking/rtmutex_common.h:63:9: note: in expansion of macro 'rb_entry'
63 | return rb_entry(p->pi_waiters.rb_leftmost, struct rt_mutex_waiter,
| ^~~~~~~~
In file included from <command-line>:
kernel/rcu/../locking/rtmutex_common.h:63:19: error: 'struct task_struct' has no member named 'pi_waiters'
63 | return rb_entry(p->pi_waiters.rb_leftmost, struct rt_mutex_waiter,
| ^~
include/linux/compiler_types.h:300:9: note: in definition of macro '__compiletime_assert'
300 | if (!(condition)) \
| ^~~~~~~~~
include/linux/compiler_types.h:320:2: note: in expansion of macro '_compiletime_assert'
320 | _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/kernel.h:709:2: note: in expansion of macro 'BUILD_BUG_ON_MSG'
709 | BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \
| ^~~~~~~~~~~~~~~~
include/linux/kernel.h:709:20: note: in expansion of macro '__same_type'
709 | BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \
| ^~~~~~~~~~~
include/linux/rbtree.h:38:37: note: in expansion of macro 'container_of'
38 | #define rb_entry(ptr, type, member) container_of(ptr, type, member)
| ^~~~~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:63:9: note: in expansion of macro 'rb_entry'
63 | return rb_entry(p->pi_waiters.rb_leftmost, struct rt_mutex_waiter,
| ^~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:63:19: error: 'struct task_struct' has no member named 'pi_waiters'
63 | return rb_entry(p->pi_waiters.rb_leftmost, struct rt_mutex_waiter,
| ^~
include/linux/compiler_types.h:300:9: note: in definition of macro '__compiletime_assert'
300 | if (!(condition)) \
| ^~~~~~~~~
include/linux/compiler_types.h:320:2: note: in expansion of macro '_compiletime_assert'
320 | _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/kernel.h:709:2: note: in expansion of macro 'BUILD_BUG_ON_MSG'
709 | BUILD_BUG_ON_MSG(!__same_type(*(ptr), ((type *)0)->member) && \
| ^~~~~~~~~~~~~~~~
include/linux/kernel.h:710:6: note: in expansion of macro '__same_type'
710 | !__same_type(*(ptr), void), \
| ^~~~~~~~~~~
include/linux/rbtree.h:38:37: note: in expansion of macro 'container_of'
38 | #define rb_entry(ptr, type, member) container_of(ptr, type, member)
| ^~~~~~~~~~~~
kernel/rcu/../locking/rtmutex_common.h:63:9: note: in expansion of macro 'rb_entry'
63 | return rb_entry(p->pi_waiters.rb_leftmost, struct rt_mutex_waiter,
| ^~~~~~~~
vim +58 kernel/rcu/../locking/rtmutex_common.h
23f78d4a03c53c kernel/rtmutex_common.h Ingo Molnar 2006-06-27 55
23f78d4a03c53c kernel/rtmutex_common.h Ingo Molnar 2006-06-27 56 static inline int task_has_pi_waiters(struct task_struct *p)
23f78d4a03c53c kernel/rtmutex_common.h Ingo Molnar 2006-06-27 57 {
a23ba907d5e65d kernel/locking/rtmutex_common.h Davidlohr Bueso 2017-09-08 @58 return !RB_EMPTY_ROOT(&p->pi_waiters.rb_root);
23f78d4a03c53c kernel/rtmutex_common.h Ingo Molnar 2006-06-27 59 }
23f78d4a03c53c kernel/rtmutex_common.h Ingo Molnar 2006-06-27 60
:::::: The code at line 58 was first introduced by commit
:::::: a23ba907d5e65d6aeea3e59c82fda9cd206a7aad locking/rtmutex: replace top-waiter and pi_waiters leftmost caching
:::::: TO: Davidlohr Bueso <dave(a)stgolabs.net>
:::::: CC: Linus Torvalds <torvalds(a)linux-foundation.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
arch/mips/kernel/setup.c:47:39: error: redefinition of '__appended_dtb' with a different type: 'const char vs 'char
by kernel test robot
Hi Thomas,
FYI, the error/warning still remains.
tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
head: 84196390620ac0e5070ae36af84c137c6216a7dc
commit: b83ba0b9df56f8404ccc6ebcc7050fb8294f0f20 MIPS: of: Introduce helper function to get DTB
date: 7 weeks ago
config: mips-randconfig-r022-20210322 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 14696baaf4c43fe53f738bc292bbe169eed93d5d)
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 mips cross compiling tool for clang build
# apt-get install binutils-mips-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/commit...
git remote add linus https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
git fetch --no-tags linus master
git checkout b83ba0b9df56f8404ccc6ebcc7050fb8294f0f20
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=mips
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/mips/kernel/setup.c:47:39: error: redefinition of '__appended_dtb' with a different type: 'const char [1048576]' vs 'char []'
const char __section(".appended_dtb") __appended_dtb[0x100000];
^
arch/mips/include/asm/bootinfo.h:118:13: note: previous declaration is here
extern char __appended_dtb[];
^
1 error generated.
vim +47 arch/mips/kernel/setup.c
^1da177e4c3f41 Linus Torvalds 2005-04-16 45
87db537da4cd1b Aaro Koskinen 2015-09-11 46 #ifdef CONFIG_MIPS_ELF_APPENDED_DTB
33def8498fdde1 Joe Perches 2020-10-21 @47 const char __section(".appended_dtb") __appended_dtb[0x100000];
87db537da4cd1b Aaro Koskinen 2015-09-11 48 #endif /* CONFIG_MIPS_ELF_APPENDED_DTB */
87db537da4cd1b Aaro Koskinen 2015-09-11 49
:::::: The code at line 47 was first introduced by commit
:::::: 33def8498fdde180023444b08e12b72a9efed41d treewide: Convert macro and uses of __section(foo) to __section("foo")
:::::: TO: Joe Perches <joe(a)perches.com>
:::::: CC: Linus Torvalds <torvalds(a)linux-foundation.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[norov:remove-find-h 13/15] arch/m68k/include/asm/bitops.h:396:24: error: conflicting types for 'find_first_bit'
by kernel test robot
tree: https://github.com/norov/linux remove-find-h
head: a3a1691cca887a386a029d858a3d69cbb3e3843f
commit: c17320c8f35578470da69fe0a4e5eb9e7a2c7fb6 [13/15] remove GENERIC_FIND_FIRST_BIT
config: m68k-allmodconfig (attached as .config)
compiler: m68k-linux-gcc (GCC) 9.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/norov/linux/commit/c17320c8f35578470da69fe0a4e5eb9e7a2...
git remote add norov https://github.com/norov/linux
git fetch --no-tags norov remove-find-h
git checkout c17320c8f35578470da69fe0a4e5eb9e7a2c7fb6
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.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 include/linux/bitops.h:32,
from include/linux/kernel.h:11,
from include/asm-generic/bug.h:20,
from arch/m68k/include/asm/bug.h:32,
from include/linux/bug.h:5,
from include/linux/page-flags.h:10,
from kernel/bounds.c:10:
>> arch/m68k/include/asm/bitops.h:396:24: error: conflicting types for 'find_first_bit'
396 | #define find_first_bit find_first_bit
| ^~~~~~~~~~~~~~
include/asm-generic/bitops/find.h:107:15: note: in expansion of macro 'find_first_bit'
107 | unsigned long find_first_bit(const unsigned long *addr, unsigned long size)
| ^~~~~~~~~~~~~~
arch/m68k/include/asm/bitops.h:373:19: note: previous definition of 'find_first_bit' was here
373 | static inline int find_first_bit(const unsigned long *vaddr, unsigned size)
| ^~~~~~~~~~~~~~
>> arch/m68k/include/asm/bitops.h:341:29: error: conflicting types for 'find_first_zero_bit'
341 | #define find_first_zero_bit find_first_zero_bit
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/bitops/find.h:127:15: note: in expansion of macro 'find_first_zero_bit'
127 | unsigned long find_first_zero_bit(const unsigned long *addr, unsigned long size)
| ^~~~~~~~~~~~~~~~~~~
arch/m68k/include/asm/bitops.h:317:19: note: previous definition of 'find_first_zero_bit' was here
317 | static inline int find_first_zero_bit(const unsigned long *vaddr,
| ^~~~~~~~~~~~~~~~~~~
--
In file included from include/linux/bitops.h:32,
from include/linux/kernel.h:11,
from include/linux/list.h:9,
from include/linux/module.h:12,
from arch/m68k/emu/nfblock.c:9:
>> arch/m68k/include/asm/bitops.h:396:24: error: conflicting types for 'find_first_bit'
396 | #define find_first_bit find_first_bit
| ^~~~~~~~~~~~~~
include/asm-generic/bitops/find.h:107:15: note: in expansion of macro 'find_first_bit'
107 | unsigned long find_first_bit(const unsigned long *addr, unsigned long size)
| ^~~~~~~~~~~~~~
arch/m68k/include/asm/bitops.h:373:19: note: previous definition of 'find_first_bit' was here
373 | static inline int find_first_bit(const unsigned long *vaddr, unsigned size)
| ^~~~~~~~~~~~~~
>> arch/m68k/include/asm/bitops.h:341:29: error: conflicting types for 'find_first_zero_bit'
341 | #define find_first_zero_bit find_first_zero_bit
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/bitops/find.h:127:15: note: in expansion of macro 'find_first_zero_bit'
127 | unsigned long find_first_zero_bit(const unsigned long *addr, unsigned long size)
| ^~~~~~~~~~~~~~~~~~~
arch/m68k/include/asm/bitops.h:317:19: note: previous definition of 'find_first_zero_bit' was here
317 | static inline int find_first_zero_bit(const unsigned long *vaddr,
| ^~~~~~~~~~~~~~~~~~~
In file included from include/linux/mmzone.h:19,
from include/linux/gfp.h:6,
from include/linux/umh.h:4,
from include/linux/kmod.h:9,
from include/linux/module.h:16,
from arch/m68k/emu/nfblock.c:9:
include/linux/page-flags-layout.h:6:10: fatal error: generated/bounds.h: No such file or directory
6 | #include <generated/bounds.h>
| ^~~~~~~~~~~~~~~~~~~~
compilation terminated.
--
In file included from include/linux/bitops.h:32,
from include/linux/kernel.h:11,
from include/asm-generic/bug.h:20,
from arch/m68k/include/asm/bug.h:32,
from include/linux/bug.h:5,
from include/linux/page-flags.h:10,
from kernel/bounds.c:10:
>> arch/m68k/include/asm/bitops.h:396:24: error: conflicting types for 'find_first_bit'
396 | #define find_first_bit find_first_bit
| ^~~~~~~~~~~~~~
include/asm-generic/bitops/find.h:107:15: note: in expansion of macro 'find_first_bit'
107 | unsigned long find_first_bit(const unsigned long *addr, unsigned long size)
| ^~~~~~~~~~~~~~
arch/m68k/include/asm/bitops.h:373:19: note: previous definition of 'find_first_bit' was here
373 | static inline int find_first_bit(const unsigned long *vaddr, unsigned size)
| ^~~~~~~~~~~~~~
>> arch/m68k/include/asm/bitops.h:341:29: error: conflicting types for 'find_first_zero_bit'
341 | #define find_first_zero_bit find_first_zero_bit
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/bitops/find.h:127:15: note: in expansion of macro 'find_first_zero_bit'
127 | unsigned long find_first_zero_bit(const unsigned long *addr, unsigned long size)
| ^~~~~~~~~~~~~~~~~~~
arch/m68k/include/asm/bitops.h:317:19: note: previous definition of 'find_first_zero_bit' was here
317 | static inline int find_first_zero_bit(const unsigned long *vaddr,
| ^~~~~~~~~~~~~~~~~~~
make[2]: *** [scripts/Makefile.build:118: kernel/bounds.s] Error 1
make[2]: Target '__build' not remade because of errors.
make[1]: *** [Makefile:1329: prepare0] Error 2
make[1]: Target 'modules_prepare' not remade because of errors.
make: *** [Makefile:222: __sub-make] Error 2
make: Target 'modules_prepare' not remade because of errors.
--
error: no override and no default toolchain set
init/Kconfig:67:warning: 'RUSTC_VERSION': number is invalid
In file included from include/linux/bitops.h:32,
from include/linux/kernel.h:11,
from include/asm-generic/bug.h:20,
from arch/m68k/include/asm/bug.h:32,
from include/linux/bug.h:5,
from include/linux/page-flags.h:10,
from kernel/bounds.c:10:
>> arch/m68k/include/asm/bitops.h:396:24: error: conflicting types for 'find_first_bit'
396 | #define find_first_bit find_first_bit
| ^~~~~~~~~~~~~~
include/asm-generic/bitops/find.h:107:15: note: in expansion of macro 'find_first_bit'
107 | unsigned long find_first_bit(const unsigned long *addr, unsigned long size)
| ^~~~~~~~~~~~~~
arch/m68k/include/asm/bitops.h:373:19: note: previous definition of 'find_first_bit' was here
373 | static inline int find_first_bit(const unsigned long *vaddr, unsigned size)
| ^~~~~~~~~~~~~~
>> arch/m68k/include/asm/bitops.h:341:29: error: conflicting types for 'find_first_zero_bit'
341 | #define find_first_zero_bit find_first_zero_bit
| ^~~~~~~~~~~~~~~~~~~
include/asm-generic/bitops/find.h:127:15: note: in expansion of macro 'find_first_zero_bit'
127 | unsigned long find_first_zero_bit(const unsigned long *addr, unsigned long size)
| ^~~~~~~~~~~~~~~~~~~
arch/m68k/include/asm/bitops.h:317:19: note: previous definition of 'find_first_zero_bit' was here
317 | static inline int find_first_zero_bit(const unsigned long *vaddr,
| ^~~~~~~~~~~~~~~~~~~
make[2]: *** [scripts/Makefile.build:118: kernel/bounds.s] Error 1
make[2]: Target '__build' not remade because of errors.
make[1]: *** [Makefile:1329: prepare0] Error 2
make[1]: Target 'prepare' not remade because of errors.
make: *** [Makefile:222: __sub-make] Error 2
make: Target 'prepare' not remade because of errors.
vim +/find_first_bit +396 arch/m68k/include/asm/bitops.h
171d809df1896c Greg Ungerer 2011-05-17 316
171d809df1896c Greg Ungerer 2011-05-17 317 static inline int find_first_zero_bit(const unsigned long *vaddr,
171d809df1896c Greg Ungerer 2011-05-17 318 unsigned size)
171d809df1896c Greg Ungerer 2011-05-17 319 {
171d809df1896c Greg Ungerer 2011-05-17 320 const unsigned long *p = vaddr;
171d809df1896c Greg Ungerer 2011-05-17 321 int res = 32;
171d809df1896c Greg Ungerer 2011-05-17 322 unsigned int words;
171d809df1896c Greg Ungerer 2011-05-17 323 unsigned long num;
171d809df1896c Greg Ungerer 2011-05-17 324
171d809df1896c Greg Ungerer 2011-05-17 325 if (!size)
171d809df1896c Greg Ungerer 2011-05-17 326 return 0;
171d809df1896c Greg Ungerer 2011-05-17 327
171d809df1896c Greg Ungerer 2011-05-17 328 words = (size + 31) >> 5;
171d809df1896c Greg Ungerer 2011-05-17 329 while (!(num = ~*p++)) {
171d809df1896c Greg Ungerer 2011-05-17 330 if (!--words)
171d809df1896c Greg Ungerer 2011-05-17 331 goto out;
171d809df1896c Greg Ungerer 2011-05-17 332 }
171d809df1896c Greg Ungerer 2011-05-17 333
171d809df1896c Greg Ungerer 2011-05-17 334 __asm__ __volatile__ ("bfffo %1{#0,#0},%0"
171d809df1896c Greg Ungerer 2011-05-17 335 : "=d" (res) : "d" (num & -num));
171d809df1896c Greg Ungerer 2011-05-17 336 res ^= 31;
171d809df1896c Greg Ungerer 2011-05-17 337 out:
171d809df1896c Greg Ungerer 2011-05-17 338 res += ((long)p - (long)vaddr - 4) * 8;
171d809df1896c Greg Ungerer 2011-05-17 339 return res < size ? res : size;
171d809df1896c Greg Ungerer 2011-05-17 340 }
171d809df1896c Greg Ungerer 2011-05-17 @341 #define find_first_zero_bit find_first_zero_bit
171d809df1896c Greg Ungerer 2011-05-17 342
171d809df1896c Greg Ungerer 2011-05-17 343 static inline int find_next_zero_bit(const unsigned long *vaddr, int size,
171d809df1896c Greg Ungerer 2011-05-17 344 int offset)
171d809df1896c Greg Ungerer 2011-05-17 345 {
171d809df1896c Greg Ungerer 2011-05-17 346 const unsigned long *p = vaddr + (offset >> 5);
171d809df1896c Greg Ungerer 2011-05-17 347 int bit = offset & 31UL, res;
171d809df1896c Greg Ungerer 2011-05-17 348
171d809df1896c Greg Ungerer 2011-05-17 349 if (offset >= size)
171d809df1896c Greg Ungerer 2011-05-17 350 return size;
171d809df1896c Greg Ungerer 2011-05-17 351
171d809df1896c Greg Ungerer 2011-05-17 352 if (bit) {
171d809df1896c Greg Ungerer 2011-05-17 353 unsigned long num = ~*p++ & (~0UL << bit);
171d809df1896c Greg Ungerer 2011-05-17 354 offset -= bit;
171d809df1896c Greg Ungerer 2011-05-17 355
171d809df1896c Greg Ungerer 2011-05-17 356 /* Look for zero in first longword */
171d809df1896c Greg Ungerer 2011-05-17 357 __asm__ __volatile__ ("bfffo %1{#0,#0},%0"
171d809df1896c Greg Ungerer 2011-05-17 358 : "=d" (res) : "d" (num & -num));
171d809df1896c Greg Ungerer 2011-05-17 359 if (res < 32) {
171d809df1896c Greg Ungerer 2011-05-17 360 offset += res ^ 31;
171d809df1896c Greg Ungerer 2011-05-17 361 return offset < size ? offset : size;
171d809df1896c Greg Ungerer 2011-05-17 362 }
171d809df1896c Greg Ungerer 2011-05-17 363 offset += 32;
171d809df1896c Greg Ungerer 2011-05-17 364
171d809df1896c Greg Ungerer 2011-05-17 365 if (offset >= size)
171d809df1896c Greg Ungerer 2011-05-17 366 return size;
171d809df1896c Greg Ungerer 2011-05-17 367 }
171d809df1896c Greg Ungerer 2011-05-17 368 /* No zero yet, search remaining full bytes for a zero */
171d809df1896c Greg Ungerer 2011-05-17 369 return offset + find_first_zero_bit(p, size - offset);
171d809df1896c Greg Ungerer 2011-05-17 370 }
171d809df1896c Greg Ungerer 2011-05-17 371 #define find_next_zero_bit find_next_zero_bit
171d809df1896c Greg Ungerer 2011-05-17 372
171d809df1896c Greg Ungerer 2011-05-17 373 static inline int find_first_bit(const unsigned long *vaddr, unsigned size)
171d809df1896c Greg Ungerer 2011-05-17 374 {
171d809df1896c Greg Ungerer 2011-05-17 375 const unsigned long *p = vaddr;
171d809df1896c Greg Ungerer 2011-05-17 376 int res = 32;
171d809df1896c Greg Ungerer 2011-05-17 377 unsigned int words;
171d809df1896c Greg Ungerer 2011-05-17 378 unsigned long num;
171d809df1896c Greg Ungerer 2011-05-17 379
171d809df1896c Greg Ungerer 2011-05-17 380 if (!size)
171d809df1896c Greg Ungerer 2011-05-17 381 return 0;
171d809df1896c Greg Ungerer 2011-05-17 382
171d809df1896c Greg Ungerer 2011-05-17 383 words = (size + 31) >> 5;
171d809df1896c Greg Ungerer 2011-05-17 384 while (!(num = *p++)) {
171d809df1896c Greg Ungerer 2011-05-17 385 if (!--words)
171d809df1896c Greg Ungerer 2011-05-17 386 goto out;
171d809df1896c Greg Ungerer 2011-05-17 387 }
171d809df1896c Greg Ungerer 2011-05-17 388
171d809df1896c Greg Ungerer 2011-05-17 389 __asm__ __volatile__ ("bfffo %1{#0,#0},%0"
171d809df1896c Greg Ungerer 2011-05-17 390 : "=d" (res) : "d" (num & -num));
171d809df1896c Greg Ungerer 2011-05-17 391 res ^= 31;
171d809df1896c Greg Ungerer 2011-05-17 392 out:
171d809df1896c Greg Ungerer 2011-05-17 393 res += ((long)p - (long)vaddr - 4) * 8;
171d809df1896c Greg Ungerer 2011-05-17 394 return res < size ? res : size;
171d809df1896c Greg Ungerer 2011-05-17 395 }
171d809df1896c Greg Ungerer 2011-05-17 @396 #define find_first_bit find_first_bit
171d809df1896c Greg Ungerer 2011-05-17 397
:::::: The code at line 396 was first introduced by commit
:::::: 171d809df1896c1022f9778cd2788be6c255a7dc m68k: merge mmu and non-mmu bitops.h
:::::: TO: Greg Ungerer <gerg(a)uclinux.org>
:::::: CC: Greg Ungerer <gerg(a)uclinux.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[android-goldfish:android-3.18 109/182] net/batman-adv/debugfs.c:507:63: sparse: sparse: incorrect type in argument 4 (different modifiers)
by kernel test robot
tree: https://android.googlesource.com/kernel/goldfish android-3.18
head: d03166b0fbc7b4e2f666b01f48aa26b12a5462d8
commit: 9330a80441f617103f18385993619f05fa948b71 [109/182] batman-adv: Fix debugfs path for renamed hardif
config: x86_64-randconfig-s021-20210322 (attached as .config)
compiler: gcc-5 (Ubuntu 5.5.0-12ubuntu1) 5.5.0 20171010
reproduce:
# apt-get install sparse
# sparse version: v0.6.3-277-gc089cd2d-dirty
git remote add android-goldfish https://android.googlesource.com/kernel/goldfish
git fetch --no-tags android-goldfish android-3.18
git checkout 9330a80441f617103f18385993619f05fa948b71
# save the attached .config to linux build tree
make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' ARCH=x86_64
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 >>)
>> net/batman-adv/debugfs.c:507:63: sparse: sparse: incorrect type in argument 4 (different modifiers) @@ expected char *new_name @@ got char const *name @@
net/batman-adv/debugfs.c:507:63: sparse: expected char *new_name
net/batman-adv/debugfs.c:507:63: sparse: got char const *name
net/batman-adv/debugfs.c: In function 'batadv_debugfs_rename_hardif':
net/batman-adv/debugfs.c:507:56: warning: passing argument 4 of 'debugfs_rename' discards 'const' qualifier from pointer target type [-Wdiscarded-qualifiers]
d = debugfs_rename(dir->d_parent, dir, dir->d_parent, name);
^
In file included from net/batman-adv/debugfs.c:21:0:
include/linux/debugfs.h:145:30: note: expected 'char *' but argument is of type 'const char *'
static inline struct dentry *debugfs_rename(struct dentry *old_dir, struct dentry *old_dentry,
^
vim +507 net/batman-adv/debugfs.c
492
493 /**
494 * batadv_debugfs_rename_hardif() - Fix debugfs path for renamed hardif
495 * @hard_iface: hard interface which was renamed
496 */
497 void batadv_debugfs_rename_hardif(struct batadv_hard_iface *hard_iface)
498 {
499 const char *name = hard_iface->net_dev->name;
500 struct dentry *dir;
501 struct dentry *d;
502
503 dir = hard_iface->debug_dir;
504 if (!dir)
505 return;
506
> 507 d = debugfs_rename(dir->d_parent, dir, dir->d_parent, name);
508 if (!d)
509 pr_err("Can't rename debugfs dir to %s\n", name);
510 }
511
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[tnguy-next-queue:100GbE 15/18] drivers/net/ethernet/intel/iavf/iavf_fdir.c:340:5: warning: format specifies type 'unsigned short' but the argument has type 'int'
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue.git 100GbE
head: a6379db818a850d1c1012cffe160cfc14d64cb40
commit: 527691bf0682d7ddcca77fc17dabd2fa090572ff [15/18] iavf: Support IPv4 Flow Director filters
config: x86_64-randconfig-r034-20210322 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 14696baaf4c43fe53f738bc292bbe169eed93d5d)
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 x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
# https://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue.git/comm...
git remote add tnguy-next-queue https://git.kernel.org/pub/scm/linux/kernel/git/tnguy/next-queue.git
git fetch --no-tags tnguy-next-queue 100GbE
git checkout 527691bf0682d7ddcca77fc17dabd2fa090572ff
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
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/net/ethernet/intel/iavf/iavf_fdir.c:340:5: warning: format specifies type 'unsigned short' but the argument has type 'int' [-Wformat]
ntohs(fltr->ip_data.dst_port),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:118:33: note: expanded from macro 'dev_info'
_dev_info(dev, dev_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/byteorder/generic.h:142:18: note: expanded from macro 'ntohs'
#define ntohs(x) ___ntohs(x)
^~~~~~~~~~~
include/linux/byteorder/generic.h:137:21: note: expanded from macro '___ntohs'
#define ___ntohs(x) __be16_to_cpu(x)
^~~~~~~~~~~~~~~~
include/uapi/linux/byteorder/little_endian.h:42:26: note: expanded from macro '__be16_to_cpu'
#define __be16_to_cpu(x) __swab16((__force __u16)(__be16)(x))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/uapi/linux/swab.h:105:2: note: expanded from macro '__swab16'
(__builtin_constant_p((__u16)(x)) ? \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/net/ethernet/intel/iavf/iavf_fdir.c:341:5: warning: format specifies type 'unsigned short' but the argument has type 'int' [-Wformat]
ntohs(fltr->ip_data.src_port));
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/dev_printk.h:118:33: note: expanded from macro 'dev_info'
_dev_info(dev, dev_fmt(fmt), ##__VA_ARGS__)
~~~ ^~~~~~~~~~~
include/linux/byteorder/generic.h:142:18: note: expanded from macro 'ntohs'
#define ntohs(x) ___ntohs(x)
^~~~~~~~~~~
include/linux/byteorder/generic.h:137:21: note: expanded from macro '___ntohs'
#define ___ntohs(x) __be16_to_cpu(x)
^~~~~~~~~~~~~~~~
include/uapi/linux/byteorder/little_endian.h:42:26: note: expanded from macro '__be16_to_cpu'
#define __be16_to_cpu(x) __swab16((__force __u16)(__be16)(x))
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/uapi/linux/swab.h:105:2: note: expanded from macro '__swab16'
(__builtin_constant_p((__u16)(x)) ? \
^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
2 warnings generated.
vim +340 drivers/net/ethernet/intel/iavf/iavf_fdir.c
316
317 /**
318 * iavf_print_fdir_fltr
319 * @adapter: adapter structure
320 * @fltr: Flow Director filter to print
321 *
322 * Print the Flow Director filter
323 **/
324 void iavf_print_fdir_fltr(struct iavf_adapter *adapter, struct iavf_fdir_fltr *fltr)
325 {
326 const char *proto = iavf_fdir_flow_proto_name(fltr->flow_type);
327
328 if (!proto)
329 return;
330
331 switch (fltr->flow_type) {
332 case IAVF_FDIR_FLOW_IPV4_TCP:
333 case IAVF_FDIR_FLOW_IPV4_UDP:
334 case IAVF_FDIR_FLOW_IPV4_SCTP:
335 dev_info(&adapter->pdev->dev, "Rule ID: %u dst_ip: %pI4 src_ip %pI4 %s: dst_port %hu src_port %hu\n",
336 fltr->loc,
337 &fltr->ip_data.v4_addrs.dst_ip,
338 &fltr->ip_data.v4_addrs.src_ip,
339 proto,
> 340 ntohs(fltr->ip_data.dst_port),
341 ntohs(fltr->ip_data.src_port));
342 break;
343 case IAVF_FDIR_FLOW_IPV4_AH:
344 case IAVF_FDIR_FLOW_IPV4_ESP:
345 dev_info(&adapter->pdev->dev, "Rule ID: %u dst_ip: %pI4 src_ip %pI4 %s: SPI %u\n",
346 fltr->loc,
347 &fltr->ip_data.v4_addrs.dst_ip,
348 &fltr->ip_data.v4_addrs.src_ip,
349 proto,
350 ntohl(fltr->ip_data.spi));
351 break;
352 case IAVF_FDIR_FLOW_IPV4_OTHER:
353 dev_info(&adapter->pdev->dev, "Rule ID: %u dst_ip: %pI4 src_ip %pI4 proto: %u L4_bytes: 0x%x\n",
354 fltr->loc,
355 &fltr->ip_data.v4_addrs.dst_ip,
356 &fltr->ip_data.v4_addrs.src_ip,
357 fltr->ip_data.proto,
358 ntohl(fltr->ip_data.l4_header));
359 break;
360 default:
361 break;
362 }
363 }
364
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[peterz-queue:mm/tlb 4/10] arch/parisc/include/asm/pgalloc.h:69:6: error: implicit declaration of function '__pmd_free'; did you mean
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git mm/tlb
head: 04b2c6816f14a93c6484f40b89fe3a6b8db346f3
commit: 8b0394d9c48ed2685f82ee506ca3c46272832811 [4/10] parisc/tlb: Fix __p*_free_tlb()
config: parisc-randconfig-r032-20210323 (attached as .config)
compiler: hppa64-linux-gcc (GCC) 9.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://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git/commit/?...
git remote add peterz-queue https://git.kernel.org/pub/scm/linux/kernel/git/peterz/queue.git
git fetch --no-tags peterz-queue mm/tlb
git checkout 8b0394d9c48ed2685f82ee506ca3c46272832811
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 make.cross ARCH=parisc
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 mm/memory.c:81:
mm/memory.c: In function 'free_pmd_range':
>> arch/parisc/include/asm/pgalloc.h:69:6: error: implicit declaration of function '__pmd_free'; did you mean 'pmd_free'? [-Werror=implicit-function-declaration]
69 | if (__pmd_free((tlb)->mm, (pmd))) \
| ^~~~~~~~~~
include/asm-generic/tlb.h:638:3: note: in expansion of macro '__pmd_free_tlb'
638 | __pmd_free_tlb(tlb, pmdp, address); \
| ^~~~~~~~~~~~~~
mm/memory.c:266:2: note: in expansion of macro 'pmd_free_tlb'
266 | pmd_free_tlb(tlb, pmd, start);
| ^~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +69 arch/parisc/include/asm/pgalloc.h
66
67 #define __pmd_free_tlb(tlb, pmd, addr) \
68 do { \
> 69 if (__pmd_free((tlb)->mm, (pmd))) \
70 tlb_remove_table((tlb), (pmd)); \
71 } while (0)
72
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[s390:for-next 1/11] arch/s390/kernel/uv.c:423:44: error: use of undeclared identifier 'prot_virt_host'; did you mean
by kernel test robot
tree: https://git.kernel.org/pub/scm/linux/kernel/git/s390/linux.git for-next
head: 5671d9718faf8c8520228c2acb91f3c0cc64192b
commit: 37564ed834aca26993b77b9b2a0119ec1ba6e00c [1/11] s390/uv: add prot virt guest/host indication files
config: s390-randconfig-r005-20210322 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 14696baaf4c43fe53f738bc292bbe169eed93d5d)
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://git.kernel.org/pub/scm/linux/kernel/git/s390/linux.git/commit/?id...
git remote add s390 https://git.kernel.org/pub/scm/linux/kernel/git/s390/linux.git
git fetch --no-tags s390 for-next
git checkout 37564ed834aca26993b77b9b2a0119ec1ba6e00c
# 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 errors (new ones prefixed by >>):
In file included from arch/s390/kernel/uv.c:14:
In file included from include/linux/memblock.h:14:
In file included from arch/s390/include/asm/dma.h:5:
In file included from arch/s390/include/asm/io.h:80:
include/asm-generic/io.h:464:31: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __raw_readb(PCI_IOBASE + addr);
~~~~~~~~~~ ^
include/asm-generic/io.h:477:61: warning: performing pointer arithmetic on a null pointer has undefined behavior [-Wnull-pointer-arithmetic]
val = __le16_to_cpu((__le16 __force)__raw_readw(PCI_IOBASE + addr));
~~~~~~~~~~ ^
include/uapi/linux/byteorder/big_endian.h:36:59: note: expanded from macro '__le16_to_cpu'
#define __le16_to_cpu(x) __swab16((__force __u16)(__le16)(x))
^
include/uapi/linux/swab.h:102:54: note: expanded from macro '__swab16'
#define __swab16(x) (__u16)__builtin_bswap16((__u16)(x))
^
In file included from arch/s390/kernel/uv.c:14:
In file included from include/linux/memblock.h:14:
In file included from arch/s390/include/asm/dma.h:5:
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:115:54: note: expanded from macro '__swab32'
#define __swab32(x) (__u32)__builtin_bswap32((__u32)(x))
^
In file included from arch/s390/kernel/uv.c:14:
In file included from include/linux/memblock.h:14:
In file included from arch/s390/include/asm/dma.h:5:
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);
~~~~~~~~~~ ^
>> arch/s390/kernel/uv.c:423:44: error: use of undeclared identifier 'prot_virt_host'; did you mean 'prot_virt_guest'?
return scnprintf(page, PAGE_SIZE, "%d\n", prot_virt_host);
^~~~~~~~~~~~~~
prot_virt_guest
arch/s390/kernel/uv.c:23:26: note: 'prot_virt_guest' declared here
int __bootdata_preserved(prot_virt_guest);
^
12 warnings and 1 error generated.
vim +423 arch/s390/kernel/uv.c
419
420 static ssize_t uv_is_prot_virt_host(struct kobject *kobj,
421 struct kobj_attribute *attr, char *page)
422 {
> 423 return scnprintf(page, PAGE_SIZE, "%d\n", prot_virt_host);
424 }
425
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[agd5f:drm-next 491/538] drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:190:43: warning: unused variable 'dmub_trace_irq_info_funcs'
by kernel test robot
Hi Wayne,
FYI, the error/warning still remains.
tree: https://gitlab.freedesktop.org/agd5f/linux.git drm-next
head: 4b3ec5ba08f35089e14006e7911934f92d0849d0
commit: 9bc6885a7abf90d4bfde44b6c9ba214a23b325dc [491/538] drm/amd/display: Support vertical interrupt 0 for all dcn ASIC
config: x86_64-randconfig-r006-20210322 (attached as .config)
compiler: clang version 13.0.0 (https://github.com/llvm/llvm-project 14696baaf4c43fe53f738bc292bbe169eed93d5d)
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 x86_64 cross compiling tool for clang build
# apt-get install binutils-x86-64-linux-gnu
git remote add agd5f https://gitlab.freedesktop.org/agd5f/linux.git
git fetch --no-tags agd5f drm-next
git checkout 9bc6885a7abf90d4bfde44b6c9ba214a23b325dc
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross ARCH=x86_64
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/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:43:20: warning: no previous prototype for function 'to_dal_irq_source_dcn21' [-Wmissing-prototypes]
enum dc_irq_source to_dal_irq_source_dcn21(
^
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:43:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
enum dc_irq_source to_dal_irq_source_dcn21(
^
static
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:389:2: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
vupdate_no_lock_int_entry(0),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:266:39: note: expanded from macro 'vupdate_no_lock_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:383:2: note: previous initialization is here
vupdate_int_entry(0),
^~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:255:39: note: expanded from macro 'vupdate_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:390:2: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
vupdate_no_lock_int_entry(1),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:266:39: note: expanded from macro 'vupdate_no_lock_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:384:2: note: previous initialization is here
vupdate_int_entry(1),
^~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:255:39: note: expanded from macro 'vupdate_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:391:2: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
vupdate_no_lock_int_entry(2),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:266:39: note: expanded from macro 'vupdate_no_lock_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:385:2: note: previous initialization is here
vupdate_int_entry(2),
^~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:255:39: note: expanded from macro 'vupdate_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:392:2: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
vupdate_no_lock_int_entry(3),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:266:39: note: expanded from macro 'vupdate_no_lock_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:386:2: note: previous initialization is here
vupdate_int_entry(3),
^~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:255:39: note: expanded from macro 'vupdate_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:393:2: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
vupdate_no_lock_int_entry(4),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:266:39: note: expanded from macro 'vupdate_no_lock_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:387:2: note: previous initialization is here
vupdate_int_entry(4),
^~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:255:39: note: expanded from macro 'vupdate_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:394:2: warning: initializer overrides prior initialization of this subobject [-Winitializer-overrides]
vupdate_no_lock_int_entry(5),
^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:266:39: note: expanded from macro 'vupdate_no_lock_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:388:2: note: previous initialization is here
vupdate_int_entry(5),
^~~~~~~~~~~~~~~~~~~~
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:255:39: note: expanded from macro 'vupdate_int_entry'
[DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
^~
>> drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c:190:43: warning: unused variable 'dmub_trace_irq_info_funcs' [-Wunused-const-variable]
static const struct irq_source_info_funcs dmub_trace_irq_info_funcs = {
^
8 warnings generated.
--
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn30/irq_service_dcn30.c:50:20: warning: no previous prototype for function 'to_dal_irq_source_dcn30' [-Wmissing-prototypes]
enum dc_irq_source to_dal_irq_source_dcn30(
^
drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn30/irq_service_dcn30.c:50:1: note: declare 'static' if the function is not intended to be used outside of this translation unit
enum dc_irq_source to_dal_irq_source_dcn30(
^
static
>> drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn30/irq_service_dcn30.c:196:43: warning: unused variable 'dmub_trace_irq_info_funcs' [-Wunused-const-variable]
static const struct irq_source_info_funcs dmub_trace_irq_info_funcs = {
^
2 warnings generated.
vim +/dmub_trace_irq_info_funcs +190 drivers/gpu/drm/amd/amdgpu/../display/dc/irq/dcn21/irq_service_dcn21.c
189
> 190 static const struct irq_source_info_funcs dmub_trace_irq_info_funcs = {
191 .set = NULL,
192 .ack = NULL
193 };
194
195 static const struct irq_source_info_funcs vline0_irq_info_funcs = {
196 .set = NULL,
197 .ack = NULL
198 };
199
200 #undef BASE_INNER
201 #define BASE_INNER(seg) DMU_BASE__INST0_SEG ## seg
202
203 /* compile time expand base address. */
204 #define BASE(seg) \
205 BASE_INNER(seg)
206
207
208 #define SRI(reg_name, block, id)\
209 BASE(mm ## block ## id ## _ ## reg_name ## _BASE_IDX) + \
210 mm ## block ## id ## _ ## reg_name
211
212
213 #define IRQ_REG_ENTRY(block, reg_num, reg1, mask1, reg2, mask2)\
214 .enable_reg = SRI(reg1, block, reg_num),\
215 .enable_mask = \
216 block ## reg_num ## _ ## reg1 ## __ ## mask1 ## _MASK,\
217 .enable_value = {\
218 block ## reg_num ## _ ## reg1 ## __ ## mask1 ## _MASK,\
219 ~block ## reg_num ## _ ## reg1 ## __ ## mask1 ## _MASK \
220 },\
221 .ack_reg = SRI(reg2, block, reg_num),\
222 .ack_mask = \
223 block ## reg_num ## _ ## reg2 ## __ ## mask2 ## _MASK,\
224 .ack_value = \
225 block ## reg_num ## _ ## reg2 ## __ ## mask2 ## _MASK \
226
227
228
229 #define hpd_int_entry(reg_num)\
230 [DC_IRQ_SOURCE_HPD1 + reg_num] = {\
231 IRQ_REG_ENTRY(HPD, reg_num,\
232 DC_HPD_INT_CONTROL, DC_HPD_INT_EN,\
233 DC_HPD_INT_CONTROL, DC_HPD_INT_ACK),\
234 .status_reg = SRI(DC_HPD_INT_STATUS, HPD, reg_num),\
235 .funcs = &hpd_irq_info_funcs\
236 }
237
238 #define hpd_rx_int_entry(reg_num)\
239 [DC_IRQ_SOURCE_HPD1RX + reg_num] = {\
240 IRQ_REG_ENTRY(HPD, reg_num,\
241 DC_HPD_INT_CONTROL, DC_HPD_RX_INT_EN,\
242 DC_HPD_INT_CONTROL, DC_HPD_RX_INT_ACK),\
243 .status_reg = SRI(DC_HPD_INT_STATUS, HPD, reg_num),\
244 .funcs = &hpd_rx_irq_info_funcs\
245 }
246 #define pflip_int_entry(reg_num)\
247 [DC_IRQ_SOURCE_PFLIP1 + reg_num] = {\
248 IRQ_REG_ENTRY(HUBPREQ, reg_num,\
249 DCSURF_SURFACE_FLIP_INTERRUPT, SURFACE_FLIP_INT_MASK,\
250 DCSURF_SURFACE_FLIP_INTERRUPT, SURFACE_FLIP_CLEAR),\
251 .funcs = &pflip_irq_info_funcs\
252 }
253
254 #define vupdate_int_entry(reg_num)\
255 [DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
256 IRQ_REG_ENTRY(OTG, reg_num,\
257 OTG_GLOBAL_SYNC_STATUS, VUPDATE_INT_EN,\
258 OTG_GLOBAL_SYNC_STATUS, VUPDATE_EVENT_CLEAR),\
259 .funcs = &vblank_irq_info_funcs\
260 }
261
262 /* vupdate_no_lock_int_entry maps to DC_IRQ_SOURCE_VUPDATEx, to match semantic
263 * of DCE's DC_IRQ_SOURCE_VUPDATEx.
264 */
265 #define vupdate_no_lock_int_entry(reg_num)\
> 266 [DC_IRQ_SOURCE_VUPDATE1 + reg_num] = {\
267 IRQ_REG_ENTRY(OTG, reg_num,\
268 OTG_GLOBAL_SYNC_STATUS, VUPDATE_NO_LOCK_INT_EN,\
269 OTG_GLOBAL_SYNC_STATUS, VUPDATE_NO_LOCK_EVENT_CLEAR),\
270 .funcs = &vupdate_no_lock_irq_info_funcs\
271 }
272
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months
[sashal-linux-stable:queue-5.4 25/33] drivers/vfio/vfio_iommu_type1.c:366:22: error: implicit declaration of function 'pte_write'; did you mean
by kernel test robot
Hi Jason,
First bad commit (maybe != root cause):
tree: https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git queue-5.4
head: 52992c043a324332256525c1be1cd6b34b766048
commit: e2b35dbc9cd294d70cac30fbe89b14c526d813ec [25/33] vfio: IOMMU_API should be selected
config: arm-randconfig-r036-20210322 (attached as .config)
compiler: arm-linux-gnueabi-gcc (GCC) 9.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://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git/c...
git remote add sashal-linux-stable https://git.kernel.org/pub/scm/linux/kernel/git/sashal/linux-stable.git
git fetch --no-tags sashal-linux-stable queue-5.4
git checkout e2b35dbc9cd294d70cac30fbe89b14c526d813ec
# save the attached .config to linux build tree
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-9.3.0 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 >>):
drivers/vfio/vfio_iommu_type1.c: In function 'follow_fault_pfn':
>> drivers/vfio/vfio_iommu_type1.c:366:22: error: implicit declaration of function 'pte_write'; did you mean 'vfs_write'? [-Werror=implicit-function-declaration]
366 | if (write_fault && !pte_write(*ptep))
| ^~~~~~~~~
| vfs_write
>> drivers/vfio/vfio_iommu_type1.c:369:10: error: implicit declaration of function 'pte_pfn'; did you mean 'put_pfn'? [-Werror=implicit-function-declaration]
369 | *pfn = pte_pfn(*ptep);
| ^~~~~~~
| put_pfn
In file included from include/linux/highmem.h:8,
from drivers/vfio/vfio_iommu_type1.c:27:
>> include/linux/mm.h:1988:2: error: implicit declaration of function 'pte_unmap'; did you mean 'memunmap'? [-Werror=implicit-function-declaration]
1988 | pte_unmap(pte); \
| ^~~~~~~~~
drivers/vfio/vfio_iommu_type1.c:371:2: note: in expansion of macro 'pte_unmap_unlock'
371 | pte_unmap_unlock(ptep, ptl);
| ^~~~~~~~~~~~~~~~
cc1: some warnings being treated as errors
vim +366 drivers/vfio/vfio_iommu_type1.c
73fa0d10d077d9 Alex Williamson 2012-07-31 338
270c35d0723a2f Ajay Kaher 2020-09-06 339 static int follow_fault_pfn(struct vm_area_struct *vma, struct mm_struct *mm,
270c35d0723a2f Ajay Kaher 2020-09-06 340 unsigned long vaddr, unsigned long *pfn,
270c35d0723a2f Ajay Kaher 2020-09-06 341 bool write_fault)
270c35d0723a2f Ajay Kaher 2020-09-06 342 {
e41bb745fd0fca Alex Williamson 2021-02-16 343 pte_t *ptep;
e41bb745fd0fca Alex Williamson 2021-02-16 344 spinlock_t *ptl;
270c35d0723a2f Ajay Kaher 2020-09-06 345 int ret;
270c35d0723a2f Ajay Kaher 2020-09-06 346
e41bb745fd0fca Alex Williamson 2021-02-16 347 ret = follow_pte(vma->vm_mm, vaddr, &ptep, &ptl);
270c35d0723a2f Ajay Kaher 2020-09-06 348 if (ret) {
270c35d0723a2f Ajay Kaher 2020-09-06 349 bool unlocked = false;
270c35d0723a2f Ajay Kaher 2020-09-06 350
270c35d0723a2f Ajay Kaher 2020-09-06 351 ret = fixup_user_fault(NULL, mm, vaddr,
270c35d0723a2f Ajay Kaher 2020-09-06 352 FAULT_FLAG_REMOTE |
270c35d0723a2f Ajay Kaher 2020-09-06 353 (write_fault ? FAULT_FLAG_WRITE : 0),
270c35d0723a2f Ajay Kaher 2020-09-06 354 &unlocked);
270c35d0723a2f Ajay Kaher 2020-09-06 355 if (unlocked)
270c35d0723a2f Ajay Kaher 2020-09-06 356 return -EAGAIN;
270c35d0723a2f Ajay Kaher 2020-09-06 357
270c35d0723a2f Ajay Kaher 2020-09-06 358 if (ret)
270c35d0723a2f Ajay Kaher 2020-09-06 359 return ret;
270c35d0723a2f Ajay Kaher 2020-09-06 360
e41bb745fd0fca Alex Williamson 2021-02-16 361 ret = follow_pte(vma->vm_mm, vaddr, &ptep, &ptl);
e41bb745fd0fca Alex Williamson 2021-02-16 362 if (ret)
e41bb745fd0fca Alex Williamson 2021-02-16 363 return ret;
270c35d0723a2f Ajay Kaher 2020-09-06 364 }
270c35d0723a2f Ajay Kaher 2020-09-06 365
e41bb745fd0fca Alex Williamson 2021-02-16 @366 if (write_fault && !pte_write(*ptep))
e41bb745fd0fca Alex Williamson 2021-02-16 367 ret = -EFAULT;
e41bb745fd0fca Alex Williamson 2021-02-16 368 else
e41bb745fd0fca Alex Williamson 2021-02-16 @369 *pfn = pte_pfn(*ptep);
e41bb745fd0fca Alex Williamson 2021-02-16 370
e41bb745fd0fca Alex Williamson 2021-02-16 371 pte_unmap_unlock(ptep, ptl);
270c35d0723a2f Ajay Kaher 2020-09-06 372 return ret;
270c35d0723a2f Ajay Kaher 2020-09-06 373 }
270c35d0723a2f Ajay Kaher 2020-09-06 374
:::::: The code at line 366 was first introduced by commit
:::::: e41bb745fd0fcaa1d37a7bd4da46230822ffe18f vfio/type1: Use follow_pte()
:::::: TO: Alex Williamson <alex.williamson(a)redhat.com>
:::::: CC: Greg Kroah-Hartman <gregkh(a)linuxfoundation.org>
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org
1 year, 6 months