All of lore.kernel.org
 help / color / mirror / Atom feed
* [djwong-xfs:timestats-cleanups 542/548] fs/bcachefs/io_write.c:91:22: error: incompatible pointer types passing 'struct time_stats_quantiles *' to parameter of type 'struct time_stats *'
@ 2024-02-07  1:34 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-02-07  1:34 UTC (permalink / raw)
  To: Darrick J. Wong; +Cc: oe-kbuild-all

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/djwong/xfs-linux.git timestats-cleanups
head:   d07e8ccdf01715f8c7fbbdea9d7910d89c6684fb
commit: 2305f6e0a722327c9e83a1a353ece28e101603fd [542/548] time_stats: split stats-with-quantiles into a separate structure
config: x86_64-buildonly-randconfig-002-20240206 (https://download.01.org/0day-ci/archive/20240207/202402070937.SBvT1Rip-lkp@intel.com/config)
compiler: clang version 17.0.6 (https://github.com/llvm/llvm-project 6009708b4367171ccdbf4b5905cb6a803753fe18)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240207/202402070937.SBvT1Rip-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/202402070937.SBvT1Rip-lkp@intel.com/

All errors (new ones prefixed by >>):

>> fs/bcachefs/io_write.c:91:22: error: incompatible pointer types passing 'struct time_stats_quantiles *' to parameter of type 'struct time_stats *' [-Werror,-Wincompatible-pointer-types]
      91 |         __time_stats_update(&ca->io_latency[rw], submit_time, now);
         |                             ^~~~~~~~~~~~~~~~~~~
   include/linux/time_stats.h:111:45: note: passing argument to parameter 'stats' here
     111 | void __time_stats_update(struct time_stats *stats, u64, u64);
         |                                             ^
   1 error generated.


vim +91 fs/bcachefs/io_write.c

1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  64  
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  65  void bch2_latency_acct(struct bch_dev *ca, u64 submit_time, int rw)
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  66  {
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  67  	atomic64_t *latency = &ca->cur_latency[rw];
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  68  	u64 now = local_clock();
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  69  	u64 io_latency = time_after64(now, submit_time)
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  70  		? now - submit_time
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  71  		: 0;
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  72  	u64 old, new, v = atomic64_read(latency);
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  73  
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  74  	do {
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  75  		old = v;
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  76  
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  77  		/*
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  78  		 * If the io latency was reasonably close to the current
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  79  		 * latency, skip doing the update and atomic operation - most of
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  80  		 * the time:
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  81  		 */
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  82  		if (abs((int) (old - io_latency)) < (old >> 1) &&
2cd0563461b68b fs/bcachefs/io.c       Brett Holman    2021-05-16  83  		    now & ~(~0U << 5))
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  84  			break;
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  85  
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  86  		new = ewma_add(old, io_latency, 5);
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  87  	} while ((v = atomic64_cmpxchg(latency, old, new)) != old);
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  88  
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  89  	bch2_congested_acct(ca, io_latency, now, rw);
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  90  
753f4c53cf0ad1 fs/bcachefs/io_write.c Kent Overstreet 2024-02-01 @91  	__time_stats_update(&ca->io_latency[rw], submit_time, now);
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  92  }
1c6fdbd8f2465d fs/bcachefs/io.c       Kent Overstreet 2017-03-16  93  

:::::: The code at line 91 was first introduced by commit
:::::: 753f4c53cf0ad12ccf6cfef1681ec07b79fb0555 time_stats: Promote to lib/

:::::: TO: Kent Overstreet <kent.overstreet@linux.dev>
:::::: CC: Darrick J. Wong <djwong@kernel.org>

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

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

only message in thread, other threads:[~2024-02-07  1:34 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-02-07  1:34 [djwong-xfs:timestats-cleanups 542/548] fs/bcachefs/io_write.c:91:22: error: incompatible pointer types passing 'struct time_stats_quantiles *' to parameter of type 'struct time_stats *' kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.