* [PATCH 01/11] fbcon: Kill compile warning
@ 2007-08-01 7:33 Antonino A. Daplas
2007-08-01 22:41 ` Andrew Morton
0 siblings, 1 reply; 3+ messages in thread
From: Antonino A. Daplas @ 2007-08-01 7:33 UTC (permalink / raw)
To: Andrew Morton; +Cc: Linux Fbdev development list
Fix compile warning ('map_override unused') if fbcon is compiled as a
module and CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY=n.
Signed-off-by: Antonino Daplas <adaplas@gmail.com>
---
drivers/video/console/fbcon.c | 12 +++++++++++-
1 files changed, 11 insertions(+), 1 deletions(-)
diff --git a/drivers/video/console/fbcon.c b/drivers/video/console/fbcon.c
index decfdc8..08f4dd0 100644
--- a/drivers/video/console/fbcon.c
+++ b/drivers/video/console/fbcon.c
@@ -127,8 +127,18 @@ static int last_fb_vc = MAX_NR_CONSOLES
static int fbcon_is_default = 1;
static int fbcon_has_exited;
static int primary_device = -1;
+
+#ifdef CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY
static int map_override;
+static inline void fbcon_map_override(void)
+{
+ map_override = 1;
+}
+#else
+#define fbcon_map_override(...) do { } while (0)
+#endif /* CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY */
+
/* font data */
static char fontname[40];
@@ -506,7 +516,7 @@ static int __init fb_console_setup(char
(options[j++]-'0') % FB_MAX;
}
- map_override = 1;
+ fbcon_map_override();
}
return 1;
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply related [flat|nested] 3+ messages in thread* Re: [PATCH 01/11] fbcon: Kill compile warning
2007-08-01 7:33 [PATCH 01/11] fbcon: Kill compile warning Antonino A. Daplas
@ 2007-08-01 22:41 ` Andrew Morton
2007-08-02 1:23 ` Antonino A. Daplas
0 siblings, 1 reply; 3+ messages in thread
From: Andrew Morton @ 2007-08-01 22:41 UTC (permalink / raw)
To: Antonino A. Daplas; +Cc: Linux Fbdev development list
On Wed, 01 Aug 2007 15:33:09 +0800
"Antonino A. Daplas" <adaplas@gmail.com> wrote:
> +static inline void fbcon_map_override(void)
> +{
> + map_override = 1;
> +}
> +#else
> +#define fbcon_map_override(...) do { } while (0)
> +#endif /* CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY */
It's odd to use a C function in one case and a macro in the other.
Was there a reason to not use plain old static inline?
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply [flat|nested] 3+ messages in thread* Re: [PATCH 01/11] fbcon: Kill compile warning
2007-08-01 22:41 ` Andrew Morton
@ 2007-08-02 1:23 ` Antonino A. Daplas
0 siblings, 0 replies; 3+ messages in thread
From: Antonino A. Daplas @ 2007-08-02 1:23 UTC (permalink / raw)
To: Andrew Morton; +Cc: Linux Fbdev development list
On Wed, 2007-08-01 at 15:41 -0700, Andrew Morton wrote:
> On Wed, 01 Aug 2007 15:33:09 +0800
> "Antonino A. Daplas" <adaplas@gmail.com> wrote:
>
> > +static inline void fbcon_map_override(void)
> > +{
> > + map_override = 1;
> > +}
> > +#else
> > +#define fbcon_map_override(...) do { } while (0)
> > +#endif /* CONFIG_FRAMEBUFFER_CONSOLE_DETECT_PRIMARY */
>
> It's odd to use a C function in one case and a macro in the other.
> Was there a reason to not use plain old static inline?
No reason, an empty inline function is fine with me too.
Tony
-------------------------------------------------------------------------
This SF.net email is sponsored by: Splunk Inc.
Still grepping through log files to find problems? Stop.
Now Search log events and configuration files using AJAX and a browser.
Download your FREE copy of Splunk now >> http://get.splunk.com/
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2007-08-02 1:23 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-08-01 7:33 [PATCH 01/11] fbcon: Kill compile warning Antonino A. Daplas
2007-08-01 22:41 ` Andrew Morton
2007-08-02 1:23 ` Antonino A. Daplas
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).