Skip to contentSkip to conversation

Staging: fbtft: Declare Exprot symbols immediately

PATCH In review Bhanusree Pola 2 participants 2 messages Feb 21, 2019

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 2/3 Staging: fbtft: Declare Exprot symbols immediately

Declaring EXPORT_SYMBOLS immediately after function/variable would be more appropriate.
This solves the checkpatch.pl warning:
WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable

---
 drivers/staging/fbtft/fbtft-core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/fbtft/fbtft-core.c +2 -2
index 9d78ce6e819f..a5cdce4766bb 100644
@@ -212,10 +212,10 @@ void fbtft_register_backlight(struct fbtft_par *par)
 }
 #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)
Signature · 1 line
2.17.1
#1 lore raw
Quoted 15 lines · Bhanusree Pola

Declaring EXPORT_SYMBOLS immediately after function/variable would be more appropriate.
This solves the checkpatch.pl warning:
WARNING: EXPORT_SYMBOL(foo); should immediately follow its function/variable

---
 drivers/staging/fbtft/fbtft-core.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/fbtft/fbtft-core.c +0 -0
index 9d78ce6e819f..a5cdce4766bb 100644

drivers/staging/fbtft/fbtft-core.c void fbtft_register_backlight(struct fbtft_par *par) · line 218

Quoted 9 lines
drivers/staging/fbtft/fbtft-core.c +2 -2
@@ -212,10 +212,10 @@ void fbtft_register_backlight(struct fbtft_par *par)
 }
 #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

Nah, the original is nicer to read, I would just leave it alone.

thanks,

greg k-h