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

backlight: corgi_lcd: fix missing prototype

The corgi_lcd_limit_intensity() function is called from platform
and defined in a driver, but the driver does not see the declaration:

drivers/video/backlight/corgi_lcd.c:434:6: error: no previous prototype for 'corgi_lcd_limit_intensity' [-Werror=missing-prototypes]
434 | void corgi_lcd_limit_intensity(int limit)

Move the prototype into a header that can be included from both
sides to shut up the warning.

Reviewed-by: Daniel Thompson <daniel.thompson@linaro.org>
Signed-off-by: Arnd Bergmann <arnd@arndb.de>

+3 -1
-1
arch/arm/mach-pxa/sharpsl_pm.h
··· 105 105 #define MAX1111_ACIN_VOLT 6u 106 106 int sharpsl_pm_pxa_read_max1111(int channel); 107 107 108 - void corgi_lcd_limit_intensity(int limit); 109 108 #endif
+1
arch/arm/mach-pxa/spitz_pm.c
··· 15 15 #include <linux/interrupt.h> 16 16 #include <linux/platform_device.h> 17 17 #include <linux/apm-emulation.h> 18 + #include <linux/spi/corgi_lcd.h> 18 19 19 20 #include <asm/irq.h> 20 21 #include <asm/mach-types.h>
+2
include/linux/spi/corgi_lcd.h
··· 15 15 void (*kick_battery)(void); 16 16 }; 17 17 18 + void corgi_lcd_limit_intensity(int limit); 19 + 18 20 #endif /* __LINUX_SPI_CORGI_LCD_H */