* [linux-next:master 2589/2998] drivers/leds/leds-sun50i-a100.c:309:12: error: call to __compiletime_assert_280 declared with 'error' attribute: FIELD_PREP: value too large for the field
@ 2023-11-27 3:11 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2023-11-27 3:11 UTC (permalink / raw)
To: Samuel Holland; +Cc: oe-kbuild-all, Linux Memory Management List, Lee Jones
tree: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master
head: 8c9660f6515396aba78d1168d2e17951d653ebf2
commit: 090a25ad97983720f52b11d9c5a8d1a446217c1d [2589/2998] leds: sun50i-a100: New driver for the A100 LED controller
config: powerpc64-randconfig-r123-20231126 (https://download.01.org/0day-ci/archive/20231127/202311270852.wLjVrXUy-lkp@intel.com/config)
compiler: clang version 14.0.6 (https://github.com/llvm/llvm-project.git f28c006a5895fc0e329fe15fead81e37457cb1d1)
reproduce: (https://download.01.org/0day-ci/archive/20231127/202311270852.wLjVrXUy-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/202311270852.wLjVrXUy-lkp@intel.com/
All errors (new ones prefixed by >>):
>> drivers/leds/leds-sun50i-a100.c:309:12: error: call to __compiletime_assert_280 declared with 'error' attribute: FIELD_PREP: value too large for the field
control = FIELD_PREP(LEDC_T01_TIMING_CTRL_REG_T1H, timing->t1h_ns / cycle_ns) |
^
include/linux/bitfield.h:114:3: note: expanded from macro 'FIELD_PREP'
__BF_FIELD_CHECK(_mask, 0ULL, _val, "FIELD_PREP: "); \
^
include/linux/bitfield.h:68:3: note: expanded from macro '__BF_FIELD_CHECK'
BUILD_BUG_ON_MSG(__builtin_constant_p(_val) ? \
^
include/linux/build_bug.h:39:37: note: expanded from macro 'BUILD_BUG_ON_MSG'
#define BUILD_BUG_ON_MSG(cond, msg) compiletime_assert(!(cond), msg)
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler_types.h:423:2: note: expanded from macro '_compiletime_assert'
__compiletime_assert(condition, msg, prefix, suffix)
^
include/linux/compiler_types.h:416:4: note: expanded from macro '__compiletime_assert'
prefix ## suffix(); \
^
<scratch space>:54:1: note: expanded from here
__compiletime_assert_280
^
1 error generated.
vim +/error +309 drivers/leds/leds-sun50i-a100.c
301
302 static void sun50i_a100_ledc_set_timing(struct sun50i_a100_ledc *priv)
303 {
304 const struct sun50i_a100_ledc_timing *timing = &priv->timing;
305 unsigned long mod_freq = clk_get_rate(priv->mod_clk);
306 u32 cycle_ns = NSEC_PER_SEC / mod_freq;
307 u32 control;
308
> 309 control = FIELD_PREP(LEDC_T01_TIMING_CTRL_REG_T1H, timing->t1h_ns / cycle_ns) |
310 FIELD_PREP(LEDC_T01_TIMING_CTRL_REG_T1L, timing->t1l_ns / cycle_ns) |
311 FIELD_PREP(LEDC_T01_TIMING_CTRL_REG_T0H, timing->t0h_ns / cycle_ns) |
312 FIELD_PREP(LEDC_T01_TIMING_CTRL_REG_T0L, timing->t0l_ns / cycle_ns);
313 writel(control, priv->base + LEDC_T01_TIMING_CTRL_REG);
314
315 control = FIELD_PREP(LEDC_RESET_TIMING_CTRL_REG_TR, timing->treset_ns / cycle_ns) |
316 FIELD_PREP(LEDC_RESET_TIMING_CTRL_REG_LED_NUM, priv->max_addr);
317 writel(control, priv->base + LEDC_RESET_TIMING_CTRL_REG);
318 }
319
--
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:[~2023-11-27 3:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-11-27 3:11 [linux-next:master 2589/2998] drivers/leds/leds-sun50i-a100.c:309:12: error: call to __compiletime_assert_280 declared with 'error' attribute: FIELD_PREP: value too large for the field 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