* [anna-nfs:linux-next 20/32] fs/nfs/flexfilelayout/flexfilelayout.c:614:2: error: incompatible pointer types passing 'u32 *' (aka 'unsigned int *') to parameter of type 'uint64_t *' (aka 'unsigned long long *')
@ 2025-09-18 0:19 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-09-18 0:19 UTC (permalink / raw)
To: Jonathan Curley; +Cc: llvm, oe-kbuild-all, Anna Schumaker
tree: git://git.linux-nfs.org/projects/anna/linux-nfs.git linux-next
head: 790035f57131cbc430418b4a2d3f3f24caa7c40f
commit: 67ee714244dfb06cdeab07ee624e2eeddab35067 [20/32] NFSv4/flexfiles: Commit path updates for striped layouts
config: powerpc-randconfig-003-20250918 (https://download.01.org/0day-ci/archive/20250918/202509180839.UzAynv63-lkp@intel.com/config)
compiler: clang version 19.1.7 (https://github.com/llvm/llvm-project cd708029e0b2869e80abe31ddb175f7c35361f90)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250918/202509180839.UzAynv63-lkp@intel.com/reproduce)
If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202509180839.UzAynv63-lkp@intel.com/
All error/warnings (new ones prefixed by >>):
>> fs/nfs/flexfilelayout/flexfilelayout.c:614:2: warning: comparison of distinct pointer types ('typeof ((mirror_idx)) *' (aka 'unsigned int *') and 'uint64_t *' (aka 'unsigned long long *')) [-Wcompare-distinct-pointer-types]
614 | do_div(mirror_idx, flseg->mirror_array[0]->dss_count);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/div64.h:183:28: note: expanded from macro 'do_div'
183 | (void)(((typeof((n)) *)0) == ((uint64_t *)0)); \
| ~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~
>> fs/nfs/flexfilelayout/flexfilelayout.c:614:2: error: incompatible pointer types passing 'u32 *' (aka 'unsigned int *') to parameter of type 'uint64_t *' (aka 'unsigned long long *') [-Werror,-Wincompatible-pointer-types]
614 | do_div(mirror_idx, flseg->mirror_array[0]->dss_count);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/div64.h:199:22: note: expanded from macro 'do_div'
199 | __rem = __div64_32(&(n), __base); \
| ^~~~
include/asm-generic/div64.h:174:38: note: passing argument to parameter 'dividend' here
174 | extern uint32_t __div64_32(uint64_t *dividend, uint32_t divisor);
| ^
>> fs/nfs/flexfilelayout/flexfilelayout.c:614:2: warning: shift count >= width of type [-Wshift-count-overflow]
614 | do_div(mirror_idx, flseg->mirror_array[0]->dss_count);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/div64.h:195:25: note: expanded from macro 'do_div'
195 | } else if (likely(((n) >> 32) == 0)) { \
| ^ ~~
include/linux/compiler.h:76:40: note: expanded from macro 'likely'
76 | # define likely(x) __builtin_expect(!!(x), 1)
| ^
fs/nfs/flexfilelayout/flexfilelayout.c:625:9: warning: comparison of distinct pointer types ('typeof ((mirror_idx)) *' (aka 'unsigned int *') and 'uint64_t *' (aka 'unsigned long long *')) [-Wcompare-distinct-pointer-types]
625 | return do_div(mirror_idx, flseg->mirror_array[0]->dss_count);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/div64.h:183:28: note: expanded from macro 'do_div'
183 | (void)(((typeof((n)) *)0) == ((uint64_t *)0)); \
| ~~~~~~~~~~~~~~~~~~ ^ ~~~~~~~~~~~~~~~
fs/nfs/flexfilelayout/flexfilelayout.c:625:9: error: incompatible pointer types passing 'u32 *' (aka 'unsigned int *') to parameter of type 'uint64_t *' (aka 'unsigned long long *') [-Werror,-Wincompatible-pointer-types]
625 | return do_div(mirror_idx, flseg->mirror_array[0]->dss_count);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/div64.h:199:22: note: expanded from macro 'do_div'
199 | __rem = __div64_32(&(n), __base); \
| ^~~~
include/asm-generic/div64.h:174:38: note: passing argument to parameter 'dividend' here
174 | extern uint32_t __div64_32(uint64_t *dividend, uint32_t divisor);
| ^
fs/nfs/flexfilelayout/flexfilelayout.c:625:9: warning: shift count >= width of type [-Wshift-count-overflow]
625 | return do_div(mirror_idx, flseg->mirror_array[0]->dss_count);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/asm-generic/div64.h:195:25: note: expanded from macro 'do_div'
195 | } else if (likely(((n) >> 32) == 0)) { \
| ^ ~~
include/linux/compiler.h:76:40: note: expanded from macro 'likely'
76 | # define likely(x) __builtin_expect(!!(x), 1)
| ^
4 warnings and 2 errors generated.
vim +614 fs/nfs/flexfilelayout/flexfilelayout.c
607
608 static u32 calc_mirror_idx_from_commit(struct pnfs_layout_segment *lseg,
609 u32 commit_index)
610 {
611 struct nfs4_ff_layout_segment *flseg = FF_LAYOUT_LSEG(lseg);
612 u32 mirror_idx = commit_index;
613
> 614 do_div(mirror_idx, flseg->mirror_array[0]->dss_count);
615
616 return mirror_idx;
617 }
618
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2025-09-18 0:19 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-09-18 0:19 [anna-nfs:linux-next 20/32] fs/nfs/flexfilelayout/flexfilelayout.c:614:2: error: incompatible pointer types passing 'u32 *' (aka 'unsigned int *') to parameter of type 'uint64_t *' (aka 'unsigned long long *') kernel test robot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox