Messages in this thread | | | Date | Sat, 8 Jan 2022 16:20:31 +0800 | From | kernel test robot <> | Subject | [ammarfaizi2-block:google/android/kernel/common/android11-kiwi-5.4 9998/9999] drivers/virtio/virtio_pvclock.c:48:6: warning: no previous prototype for 'update_suspend_time' |
| |
Hi Colin,
FYI, the error/warning still remains.
tree: https://github.com/ammarfaizi2/linux-block google/android/kernel/common/android11-kiwi-5.4 head: 7d1d5848183bd1d9086d0572f9af431d3ded407f commit: 04f660d6724f5df1b07f8cf9e1c55f70fb43d1d2 [9998/9999] ANDROID: virtio: virtio_pvclock: initial driver impl config: i386-allyesconfig (https://download.01.org/0day-ci/archive/20220108/202201081651.n1OTPsay-lkp@intel.com/config) compiler: gcc-9 (Debian 9.3.0-22) 9.3.0 reproduce (this is a W=1 build): # https://github.com/ammarfaizi2/linux-block/commit/04f660d6724f5df1b07f8cf9e1c55f70fb43d1d2 git remote add ammarfaizi2-block https://github.com/ammarfaizi2/linux-block git fetch --no-tags ammarfaizi2-block google/android/kernel/common/android11-kiwi-5.4 git checkout 04f660d6724f5df1b07f8cf9e1c55f70fb43d1d2 # save the config file to linux build tree mkdir build_dir make W=1 O=build_dir ARCH=i386 SHELL=/bin/bash drivers/virtio/
If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@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
| |