tree:
https://android.googlesource.com/kernel/common android11-kiwi-5.4
head: 04f660d6724f5df1b07f8cf9e1c55f70fb43d1d2
commit: 04f660d6724f5df1b07f8cf9e1c55f70fb43d1d2 [1/1] ANDROID: virtio: virtio_pvclock:
initial driver impl
config: i386-allyesconfig (attached as .config)
compiler: gcc-9 (Debian 9.3.0-22) 9.3.0
reproduce (this is a W=1 build):
git remote add android-common
https://android.googlesource.com/kernel/common
git fetch --no-tags android-common android11-kiwi-5.4
git checkout 04f660d6724f5df1b07f8cf9e1c55f70fb43d1d2
# save the attached .config to linux build tree
make W=1 ARCH=i386
If you fix the issue, kindly add following tag as appropriate
Reported-by: kernel test robot <lkp(a)intel.com>
All warnings (new ones prefixed by >>):
> drivers/virtio/virtio_pvclock.c:48:6: warning: no previous
prototype for 'update_suspend_time' [-Wmissing-prototypes]
48 | void
update_suspend_time(struct work_struct *work)
| ^~~~~~~~~~~~~~~~~~~
drivers/virtio/virtio_pvclock.c: In function 'virtpvclock_validate':
> drivers/virtio/virtio_pvclock.c:294:2: warning: ISO C90 forbids
mixed declarations and code [-Wdeclaration-after-statement]
294 | uint32_t
rating =
| ^~~~~~~~
vim +/update_suspend_time +48 drivers/virtio/virtio_pvclock.c
47
48 void update_suspend_time(struct work_struct *work)
49 {
50 u64 suspend_ns, suspend_time_delta = 0;
51 struct timespec64 inject_time;
52 struct virtio_pvclock *vp;
53
54 vp = container_of(work, struct virtio_pvclock,
55 update_suspend_time_work);
56
57 virtio_cread(vp->vdev, struct virtio_pvclock_config, suspend_time_ns,
58 &suspend_ns);
59
60 mutex_lock(&vp->inject_suspend_lock);
61 if (suspend_ns > vp->injected_suspend_ns) {
62 suspend_time_delta = suspend_ns - vp->injected_suspend_ns;
63 vp->injected_suspend_ns = suspend_ns;
64 }
65 mutex_unlock(&vp->inject_suspend_lock);
66
67 if (suspend_time_delta == 0) {
68 dev_err(&vp->vdev->dev,
69 "%s: suspend_time_ns is less than injected_suspend_ns\n",
70 __func__);
71 return;
72 }
73
74 inject_time = ns_to_timespec64(suspend_time_delta);
75
76 timekeeping_inject_sleeptime64(&inject_time);
77
78 dev_info(&vp->vdev->dev, "injected sleeptime: %llu ns\n",
79 suspend_time_delta);
80 }
81
---
0-DAY CI Kernel Test Service, Intel Corporation
https://lists.01.org/hyperkitty/list/kbuild-all@lists.01.org