Building the Linux kernel with Clang and LLVM
 help / color / mirror / Atom feed
* [toke:mq-cake-api-experiments 2/2] net/sched/sch_cake.c:1995:26: error: call to '__compiletime_assert_676' declared with 'error' attribute: min(priv->min_timer_slack, diff) signedness error
@ 2025-03-09 23:37 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2025-03-09 23:37 UTC (permalink / raw)
  To: Toke Høiland-Jørgensen; +Cc: llvm, oe-kbuild-all

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/toke/linux.git mq-cake-api-experiments
head:   a9175301728058ffe2aaa7943c9882edbc88accb
commit: a9175301728058ffe2aaa7943c9882edbc88accb [2/2] net/sched: Convert mq-cake to use shared state API
config: hexagon-randconfig-002-20250310 (https://download.01.org/0day-ci/archive/20250310/202503100749.dxifTDc6-lkp@intel.com/config)
compiler: clang version 21.0.0git (https://github.com/llvm/llvm-project e15545cad8297ec7555f26e5ae74a9f0511203e7)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250310/202503100749.dxifTDc6-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/202503100749.dxifTDc6-lkp@intel.com/

All errors (new ones prefixed by >>):

>> net/sched/sch_cake.c:1995:26: error: call to '__compiletime_assert_676' declared with 'error' attribute: min(priv->min_timer_slack, diff) signedness error
    1995 |         priv->min_timer_slack = min(priv->min_timer_slack, diff);
         |                                 ^
   include/linux/minmax.h:105:19: note: expanded from macro 'min'
     105 | #define min(x, y)       __careful_cmp(min, x, y)
         |                         ^
   include/linux/minmax.h:98:2: note: expanded from macro '__careful_cmp'
      98 |         __careful_cmp_once(op, x, y, __UNIQUE_ID(x_), __UNIQUE_ID(y_))
         |         ^
   include/linux/minmax.h:93:2: note: expanded from macro '__careful_cmp_once'
      93 |         BUILD_BUG_ON_MSG(!__types_ok(ux, uy),           \
         |         ^
   note: (skipping 2 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
   include/linux/compiler_types.h:530:2: note: expanded from macro '_compiletime_assert'
     530 |         __compiletime_assert(condition, msg, prefix, suffix)
         |         ^
   include/linux/compiler_types.h:523:4: note: expanded from macro '__compiletime_assert'
     523 |                         prefix ## suffix();                             \
         |                         ^
   <scratch space>:51:1: note: expanded from here
      51 | __compiletime_assert_676
         | ^
   1 error generated.


vim +1995 net/sched/sch_cake.c

046f6fd5daefac7 Toke Høiland-Jørgensen 2018-07-06  1987  
e3ac36ec3b7d956 Jonas                  2024-11-14  1988  static inline void cake_update_timer_slack(ktime_t now, ktime_t next, struct cake_sched_data *priv)
e3ac36ec3b7d956 Jonas                  2024-11-14  1989  {
e3ac36ec3b7d956 Jonas                  2024-11-14  1990  	s64 diff = ktime_to_ns(ktime_sub(now, next));
e3ac36ec3b7d956 Jonas                  2024-11-14  1991  	if (diff < 0) {
e3ac36ec3b7d956 Jonas                  2024-11-14  1992  		pr_warn("diff is %lli\n", diff);
e3ac36ec3b7d956 Jonas                  2024-11-14  1993  		return;
e3ac36ec3b7d956 Jonas                  2024-11-14  1994  	}
e3ac36ec3b7d956 Jonas                  2024-11-14 @1995  	priv->min_timer_slack = min(priv->min_timer_slack, diff);
e3ac36ec3b7d956 Jonas                  2024-11-14  1996  	priv->max_timer_slack = max(priv->max_timer_slack, diff);
e3ac36ec3b7d956 Jonas                  2024-11-14  1997  	priv->avg_timer_slack = cake_ewma(priv->avg_timer_slack, diff, 3);
e3ac36ec3b7d956 Jonas                  2024-11-14  1998  }
e3ac36ec3b7d956 Jonas                  2024-11-14  1999  

:::::: The code at line 1995 was first introduced by commit
:::::: e3ac36ec3b7d9566a566c4140af356372efb69ea net: sched: turn cake into mq_cake

:::::: TO: Jonas <j.koeppeler@tu-berlin.de>
:::::: CC: Jonas Köppeler <j.koeppeler@tu-berlin.de>

-- 
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-03-09 23:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-09 23:37 [toke:mq-cake-api-experiments 2/2] net/sched/sch_cake.c:1995:26: error: call to '__compiletime_assert_676' declared with 'error' attribute: min(priv->min_timer_slack, diff) signedness error 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