Signed-off-by: Leonardo Brás <leobras.c@xxxxxxxxx> --- drivers/staging/fbtft/fbtft-bus.c | 10 ++++++---- drivers/staging/fbtft/fbtft-core.c | 6 ++++-- drivers/staging/fbtft/fbtft.h | 4 ++-- 3 files changed, 12 insertions(+), 8 deletions(-) diff --git a/drivers/staging/fbtft/fbtft-bus.c b/drivers/staging/fbtft/fbtft-bus.c index 5c768c658258..5a68802abac7 100644 --- a/drivers/staging/fbtft/fbtft-bus.c +++ b/drivers/staging/fbtft/fbtft-bus.c @@ -60,11 +60,13 @@ void func(struct fbtft_par *par, int len, ...) \ out: \ va_end(args); \ } \ -EXPORT_SYMBOL(func); +EXPORT_SYMBOL(func) -define_fbtft_write_reg(fbtft_write_reg8_bus8, u8, u8, ) -define_fbtft_write_reg(fbtft_write_reg16_bus8, __be16, u16, cpu_to_be16) -define_fbtft_write_reg(fbtft_write_reg16_bus16, u16, u16, ) +#define no_modf /*No modifier*/ + +define_fbtft_write_reg(fbtft_write_reg8_bus8, u8, u8, no_modf); +define_fbtft_write_reg(fbtft_write_reg16_bus8, __be16, u16, cpu_to_be16); +define_fbtft_write_reg(fbtft_write_reg16_bus16, u16, u16, no_modf); void fbtft_write_reg8_bus9(struct fbtft_par *par, int len, ...) { diff --git a/drivers/staging/fbtft/fbtft-core.c b/drivers/staging/fbtft/fbtft-core.c index 4660a9f9eace..a9ee586ee6ba 100644 --- a/drivers/staging/fbtft/fbtft-core.c +++ b/drivers/staging/fbtft/fbtft-core.c @@ -278,6 +278,7 @@ void fbtft_unregister_backlight(struct fbtft_par *par) par->info->bl_dev = NULL; } } +EXPORT_SYMBOL(fbtft_unregister_backlight); static const struct backlight_ops fbtft_bl_ops = { .get_brightness = fbtft_backlight_get_brightness, @@ -315,12 +316,13 @@ void fbtft_register_backlight(struct fbtft_par *par) if (!par->fbtftops.unregister_backlight) par->fbtftops.unregister_backlight = fbtft_unregister_backlight; } +EXPORT_SYMBOL(fbtft_register_backlight); #else void fbtft_register_backlight(struct fbtft_par *par) { }; -void fbtft_unregister_backlight(struct fbtft_par *par) { }; -#endif EXPORT_SYMBOL(fbtft_register_backlight); +void fbtft_unregister_backlight(struct fbtft_par *par) { }; EXPORT_SYMBOL(fbtft_unregister_backlight); +#endif static void fbtft_set_addr_win(struct fbtft_par *par, int xs, int ys, int xe, int ye) diff --git a/drivers/staging/fbtft/fbtft.h b/drivers/staging/fbtft/fbtft.h index a1411590732d..d8e7204a8d74 100644 --- a/drivers/staging/fbtft/fbtft.h +++ b/drivers/staging/fbtft/fbtft.h @@ -236,7 +236,7 @@ struct fbtft_par { bool polarity; }; -#define NUMARGS(...) (sizeof((int[]){__VA_ARGS__})/sizeof(int)) +#define NUMARGS(...) (sizeof((int[]){__VA_ARGS__}) / sizeof(int)) #define write_reg(par, ...) \ ((par)->fbtftops.write_register(par, NUMARGS(__VA_ARGS__), __VA_ARGS__)) @@ -346,7 +346,7 @@ static void __exit fbtft_driver_module_exit(void) \ } \ \ module_init(fbtft_driver_module_init); \ -module_exit(fbtft_driver_module_exit); +module_exit(fbtft_driver_module_exit) /* Debug macros */ -- 2.18.0 _______________________________________________ devel mailing list devel@xxxxxxxxxxxxxxxxxxxxxx http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel