mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "Leonardo Brás" <leobras.c@gmail.com>
To: Thomas Petazzoni <thomas.petazzoni@free-electrons.com>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org
Subject: [PATCH v2 10/15] staging: fbtft: Fixes some defines styles - Style
Date: Tue, 7 Aug 2018 21:29:25 -0300	[thread overview]
Message-ID: <cb5b3900e97e3b295dda63b5d8b29d6fed669893.1533686201.git.leobras.c@gmail.com> (raw)
In-Reply-To: <cover.1533686201.git.leobras.c@gmail.com>

Fixing some styles as recommended by checkpatch.pl.

Signed-off-by: Leonardo Brás <leobras.c@gmail.com>
---
 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 8ce1ff9b6c2a..20d94712cc84 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 64f69d1a3029..8b79353c722a 100644
--- a/drivers/staging/fbtft/fbtft-core.c
+++ b/drivers/staging/fbtft/fbtft-core.c
@@ -275,6 +275,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,
@@ -312,12 +313,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 87114502e836..6ee9ff320567 100644
--- a/drivers/staging/fbtft/fbtft.h
+++ b/drivers/staging/fbtft/fbtft.h
@@ -232,7 +232,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__))
@@ -342,7 +342,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


  parent reply	other threads:[~2018-08-08  0:29 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-08-08  0:27 [PATCH v2 00/15] staging: fbtft: Fixes some issues found with checkpatch.pl Leonardo Brás
2018-08-08  0:28 ` [PATCH v2 01/15] staging: fbtft: Changes udelay(n) to usleep_range(n, n + x). - Style Leonardo Brás
2018-08-08 12:18   ` Greg Kroah-Hartman
2018-08-08  0:28 ` [PATCH v2 02/15] staging: fbtft: Puts macro arguments in parenthesis to avoid precedence issues " Leonardo Brás
2018-08-08  0:28 ` [PATCH v2 03/15] staging: fbtft: Fixes some alignment " Leonardo Brás
2018-08-08  0:28 ` [PATCH v2 04/15] staging: fbtft: Fixes some lines long lines (>80) " Leonardo Brás
2018-08-08 12:19   ` Greg Kroah-Hartman
2018-08-08  0:28 ` [PATCH v2 05/15] staging: fbtft: A bit more information on dev_err Leonardo Brás
2018-08-08  0:28 ` [PATCH v2 06/15] staging: fbtft: Changes gamma table to define Leonardo Brás
2018-08-08  0:29 ` [PATCH v2 07/15] staging: fbtft: Removes one nesting level to help readability - Style Leonardo Brás
2018-08-08  0:29 ` [PATCH v2 08/15] staging: fbtft: Adjust some empty-line problems " Leonardo Brás
2018-08-08  0:29 ` [PATCH v2 09/15] staging: fbtft: Erases some repetitive usage of function name " Leonardo Brás
2018-08-08  0:29 ` Leonardo Brás [this message]
2018-08-08 12:22   ` [PATCH v2 10/15] staging: fbtft: Fixes some defines styles " Greg Kroah-Hartman
     [not found]     ` <CADvQ+rGiF2kT62tBJjruGkQ8TbxU45PmgpW7xfrMy8xi1tOTBg@mail.gmail.com>
2018-08-09  9:49       ` Greg Kroah-Hartman
2018-08-08  0:29 ` [PATCH v2 11/15] staging: fbtft: Includes description to mutex and spinlock " Leonardo Brás
2018-08-08 12:22   ` Greg Kroah-Hartman
2018-08-08  0:29 ` [PATCH v2 12/15] staging: fbtft: Add spaces around / " Leonardo Brás
2018-08-08  0:29 ` [PATCH v2 13/15] staging: fbtft: Corrects long index line " Leonardo Brás
2018-08-08  0:30 ` [PATCH v2 14/15] staging: fbtft: Replaces (1 << n) for macro BIT(n) " Leonardo Brás
2018-08-08  0:30 ` [PATCH v2 15/15] staging: fbtft: Replaces custom debug macro with dev_dbg() Leonardo Brás
2018-08-08 12:24   ` Greg Kroah-Hartman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=cb5b3900e97e3b295dda63b5d8b29d6fed669893.1533686201.git.leobras.c@gmail.com \
    --to=leobras.c@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=thomas.petazzoni@free-electrons.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®