[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202501180914.vD2HyOZ2-lkp@intel.com>
Date: Sat, 18 Jan 2025 09:25:05 +0800
From: kernel test robot <lkp@...el.com>
To: Mark Pearson <mpearson-lenovo@...ebb.ca>
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
wim@...ux-watchdog.org, linux@...ck-us.net, dober@...ovo.com,
linux-watchdog@...r.kernel.org, linux-kernel@...r.kernel.org
Subject: Re: [PATCH] watchdog: lenovo_se30_wdt: Watchdog driver for Lenovo
SE30 platform
Hi Mark,
kernel test robot noticed the following build errors:
[auto build test ERROR on groeck-staging/hwmon-next]
[also build test ERROR on linus/master v6.13-rc7 next-20250117]
[If your patch is applied to the wrong git tree, kindly drop us a note.
And when submitting patch, we suggest to use '--base' as documented in
https://git-scm.com/docs/git-format-patch#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Mark-Pearson/watchdog-lenovo_se30_wdt-Watchdog-driver-for-Lenovo-SE30-platform/20250115-220703
base: https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git hwmon-next
patch link: https://lore.kernel.org/r/20250115140510.2017-1-mpearson-lenovo%40squebb.ca
patch subject: [PATCH] watchdog: lenovo_se30_wdt: Watchdog driver for Lenovo SE30 platform
config: riscv-allmodconfig (https://download.01.org/0day-ci/archive/20250118/202501180914.vD2HyOZ2-lkp@intel.com/config)
compiler: clang version 20.0.0git (https://github.com/llvm/llvm-project f5cd181ffbb7cb61d582fe130d46580d5969d47a)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20250118/202501180914.vD2HyOZ2-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202501180914.vD2HyOZ2-lkp@intel.com/
All errors (new ones prefixed by >>):
In file included from drivers/watchdog/lenovo_se30_wdt.c:11:
In file included from include/linux/iommu.h:10:
In file included from include/linux/scatterlist.h:8:
In file included from include/linux/mm.h:2223:
include/linux/vmstat.h:504:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
504 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~ ^
505 | item];
| ~~~~
include/linux/vmstat.h:511:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
511 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~ ^
512 | NR_VM_NUMA_EVENT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~~
include/linux/vmstat.h:518:36: warning: arithmetic between different enumeration types ('enum node_stat_item' and 'enum lru_list') [-Wenum-enum-conversion]
518 | return node_stat_name(NR_LRU_BASE + lru) + 3; // skip "nr_"
| ~~~~~~~~~~~ ^ ~~~
include/linux/vmstat.h:524:43: warning: arithmetic between different enumeration types ('enum zone_stat_item' and 'enum numa_stat_item') [-Wenum-enum-conversion]
524 | return vmstat_text[NR_VM_ZONE_STAT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~ ^
525 | NR_VM_NUMA_EVENT_ITEMS +
| ~~~~~~~~~~~~~~~~~~~~~~
>> drivers/watchdog/lenovo_se30_wdt.c:314:24: error: call to undeclared function 'ioremap_cache'; ISO C99 and later do not support implicit function declarations [-Wimplicit-function-declaration]
314 | priv->shm.base_addr = ioremap_cache(priv->shm.base_phys, SHM_WIN_SIZE);
| ^
drivers/watchdog/lenovo_se30_wdt.c:314:24: note: did you mean 'ioremap_uc'?
include/asm-generic/io.h:1145:29: note: 'ioremap_uc' declared here
1145 | static inline void __iomem *ioremap_uc(phys_addr_t offset, size_t size)
| ^
include/asm-generic/io.h:1144:20: note: expanded from macro 'ioremap_uc'
1144 | #define ioremap_uc ioremap_uc
| ^
>> drivers/watchdog/lenovo_se30_wdt.c:314:22: error: incompatible integer to pointer conversion assigning to 'unsigned char *' from 'int' [-Wint-conversion]
314 | priv->shm.base_addr = ioremap_cache(priv->shm.base_phys, SHM_WIN_SIZE);
| ^ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
4 warnings and 2 errors generated.
vim +/ioremap_cache +314 drivers/watchdog/lenovo_se30_wdt.c
276
277 static int lenovo_se30_wdt_probe(struct platform_device *pdev)
278 {
279 struct device *dev = &pdev->dev;
280 struct lenovo_se30_wdt *priv;
281 unsigned long base_phys;
282 unsigned short val;
283 int err;
284
285 err = superio_enter(UNLOCK_KEY, SIO_REG, LNV_SE30_NAME);
286 if (err)
287 return err;
288
289 val = superio_inb(SIO_REG, CHIPID_REG) << 8;
290 val |= superio_inb(SIO_REG, CHIPID_REG + 1);
291
292 if ((val & CHIPID_MASK) != LNV_SE30_ID) {
293 superio_exit(LOCK_KEY, SIO_REG);
294 return -ENODEV;
295 }
296
297 superio_outb(SIO_REG, LDN_REG, LD_NUM_SHM);
298 base_phys = (superio_inb(SIO_REG, LD_BASE_ADDR) |
299 (superio_inb(SIO_REG, LD_BASE_ADDR + 1) << 8) |
300 (superio_inb(SIO_REG, LD_BASE_ADDR + 2) << 16) |
301 (superio_inb(SIO_REG, LD_BASE_ADDR + 3) << 24)) &
302 0xFFFFFFFF;
303
304 superio_exit(LOCK_KEY, SIO_REG);
305 if (base_phys == 0xFFFFFFFF || base_phys == 0)
306 return -ENODEV;
307
308 priv = devm_kzalloc(dev, sizeof(*priv), GFP_KERNEL);
309 if (!priv)
310 return -ENOMEM;
311
312 priv->sio.base_phys = base_phys;
313 priv->shm.base_phys = base_phys;
> 314 priv->shm.base_addr = ioremap_cache(priv->shm.base_phys, SHM_WIN_SIZE);
315
316 priv->wdt_cfg.mod = WDT_MODULE;
317 priv->wdt_cfg.idx = WDT_CFG_INDEX;
318 priv->wdt_cnt.mod = WDT_MODULE;
319 priv->wdt_cnt.idx = WDT_CNT_INDEX;
320
321 priv->wdt.ops = &lenovo_se30_wdt_ops;
322 priv->wdt.info = &lenovo_se30_wdt_info;
323 priv->wdt.timeout = WATCHDOG_TIMEOUT; /* Set default timeout */
324 priv->wdt.min_timeout = MIN_TIMEOUT;
325 priv->wdt.max_timeout = MAX_TIMEOUT;
326 priv->wdt.parent = dev;
327
328 watchdog_init_timeout(&priv->wdt, timeout, dev);
329 watchdog_set_drvdata(&priv->wdt, priv);
330 watchdog_set_nowayout(&priv->wdt, nowayout);
331 watchdog_stop_on_reboot(&priv->wdt);
332 watchdog_stop_on_unregister(&priv->wdt);
333
334 return devm_watchdog_register_device(dev, &priv->wdt);
335 }
336
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki
Powered by blists - more mailing lists