Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

init/calibrate.c: provide proper prototype

Sparse issues a warning:

CHECK init/calibrate.c
init/calibrate.c:271:28: warning: symbol 'calibration_delay_done' was not declared. Should it be static?

The actual issue is that it's a __weak symbol that archs can override
(in fact, ARM does so), but no prototype is provided. Let's provide one
to prevent surprises.

Link: http://lkml.kernel.org/r/18827.1548750938@turing-police.cc.vt.edu
Signed-off-by: Valdis Kletnieks <valdis.kletnieks@vt.edu>
Reviewed-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>

authored by

Valdis Kletnieks and committed by
Linus Torvalds
8496ecd0 49ac9819

+1
+1
include/linux/delay.h
··· 55 55 56 56 extern unsigned long lpj_fine; 57 57 void calibrate_delay(void); 58 + void __attribute__((weak)) calibration_delay_done(void); 58 59 void msleep(unsigned int msecs); 59 60 unsigned long msleep_interruptible(unsigned int msecs); 60 61 void usleep_range(unsigned long min, unsigned long max);