Building the Linux kernel with Clang and LLVM
 help / color / mirror / Atom feed
From: kernel test robot <lkp@intel.com>
To: "Toke Høiland-Jørgensen" <toke@redhat.com>
Cc: llvm@lists.linux.dev, oe-kbuild-all@lists.linux.dev
Subject: [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
Date: Mon, 10 Mar 2025 07:37:22 +0800	[thread overview]
Message-ID: <202503100749.dxifTDc6-lkp@intel.com> (raw)

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

                 reply	other threads:[~2025-03-09 23:38 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=202503100749.dxifTDc6-lkp@intel.com \
    --to=lkp@intel.com \
    --cc=llvm@lists.linux.dev \
    --cc=oe-kbuild-all@lists.linux.dev \
    --cc=toke@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox