* [groeck-staging:watchdog-next 37/38] drivers/watchdog/wm8350_wdt.c:156:46: error: passing argument 1 of 'devm_watchdog_register_device' from incompatible pointer type
@ 2023-03-07 0:37 kernel test robot
0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2023-03-07 0:37 UTC (permalink / raw)
To: Uwe Kleine-König; +Cc: oe-kbuild-all, linux-hwmon, Guenter Roeck
tree: https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git watchdog-next
head: faaf9f98d1032c901d8e859e3b6883c7e67614b6
commit: d0b1813194e77e8f3a11e203472bd0dbcce52c2e [37/38] watchdog: wm8350: Simplify using devm_watchdog_register_device()
config: arm-randconfig-r046-20230306 (https://download.01.org/0day-ci/archive/20230307/202303070842.5mR8qwK4-lkp@intel.com/config)
compiler: arm-linux-gnueabi-gcc (GCC) 12.1.0
reproduce (this is a W=1 build):
wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross
chmod +x ~/bin/make.cross
# https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git/commit/?id=d0b1813194e77e8f3a11e203472bd0dbcce52c2e
git remote add groeck-staging https://git.kernel.org/pub/scm/linux/kernel/git/groeck/linux-staging.git
git fetch --no-tags groeck-staging watchdog-next
git checkout d0b1813194e77e8f3a11e203472bd0dbcce52c2e
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm olddefconfig
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash drivers/watchdog/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@intel.com>
| Link: https://lore.kernel.org/oe-kbuild-all/202303070842.5mR8qwK4-lkp@intel.com/
All errors (new ones prefixed by >>):
drivers/watchdog/wm8350_wdt.c: In function 'wm8350_wdt_probe':
>> drivers/watchdog/wm8350_wdt.c:156:46: error: passing argument 1 of 'devm_watchdog_register_device' from incompatible pointer type [-Werror=incompatible-pointer-types]
156 | return devm_watchdog_register_device(&wm8350_wdt);
| ^~~~~~~~~~~
| |
| struct watchdog_device *
In file included from drivers/watchdog/wm8350_wdt.c:15:
include/linux/watchdog.h:226:50: note: expected 'struct device *' but argument is of type 'struct watchdog_device *'
226 | int devm_watchdog_register_device(struct device *dev, struct watchdog_device *);
| ~~~~~~~~~~~~~~~^~~
>> drivers/watchdog/wm8350_wdt.c:156:16: error: too few arguments to function 'devm_watchdog_register_device'
156 | return devm_watchdog_register_device(&wm8350_wdt);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
include/linux/watchdog.h:226:5: note: declared here
226 | int devm_watchdog_register_device(struct device *dev, struct watchdog_device *);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/watchdog/wm8350_wdt.c:157:1: error: control reaches end of non-void function [-Werror=return-type]
157 | }
| ^
cc1: some warnings being treated as errors
vim +/devm_watchdog_register_device +156 drivers/watchdog/wm8350_wdt.c
139
140 static int wm8350_wdt_probe(struct platform_device *pdev)
141 {
142 struct wm8350 *wm8350 = platform_get_drvdata(pdev);
143
144 if (!wm8350) {
145 pr_err("No driver data supplied\n");
146 return -ENODEV;
147 }
148
149 watchdog_set_nowayout(&wm8350_wdt, nowayout);
150 watchdog_set_drvdata(&wm8350_wdt, wm8350);
151 wm8350_wdt.parent = &pdev->dev;
152
153 /* Default to 4s timeout */
154 wm8350_wdt_set_timeout(&wm8350_wdt, 4);
155
> 156 return devm_watchdog_register_device(&wm8350_wdt);
157 }
158
--
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2023-03-07 0:37 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-03-07 0:37 [groeck-staging:watchdog-next 37/38] drivers/watchdog/wm8350_wdt.c:156:46: error: passing argument 1 of 'devm_watchdog_register_device' from incompatible pointer type 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.