From: Olaf Mandel <o.mandel@menlosystems.com>
To: linux@arm.linux.org.uk
Cc: linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org,
Olaf Mandel <o.mandel@menlosystems.com>,
Marek Vasut <marex@denx.de>
Subject: [PATCH] arm: add CONFIG_ARM_VERBOSE_BOOTUP
Date: Mon, 18 May 2015 17:50:43 +0200 [thread overview]
Message-ID: <1431964243-9995-1-git-send-email-o.mandel@menlosystems.com> (raw)
The new option copies the behaviour of CONFIG_X86_VERBOSE_BOOTUP
to the arm architecture, allowing to completely silence the
serial port. The default value is y, which is the original
behaviour.
Signed-off-by: Olaf Mandel <o.mandel@menlosystems.com>
CC: Marek Vasut <marex@denx.de>
---
arch/arm/Kconfig.debug | 9 +++++++++
arch/arm/boot/compressed/misc.c | 16 +++++++++++-----
2 files changed, 20 insertions(+), 5 deletions(-)
diff --git a/arch/arm/Kconfig.debug b/arch/arm/Kconfig.debug
index 0c12ffb..644f585 100644
--- a/arch/arm/Kconfig.debug
+++ b/arch/arm/Kconfig.debug
@@ -1565,6 +1565,15 @@ config UNCOMPRESS_INCLUDE
ARCH_SHMOBILE_LEGACY
default "mach/uncompress.h"
+config ARM_VERBOSE_BOOTUP
+ bool "Enable verbose arm bootup info messages"
+ default y
+ ---help---
+ Enables the informational output from the decompression stage
+ (e.g. bzImage) of the boot. Disable this if you want silent
+ bootup. Error messages from the compression stage are shown
+ even if this option is disabled.
+
config EARLY_PRINTK
bool "Early printk"
depends on DEBUG_LL
diff --git a/arch/arm/boot/compressed/misc.c b/arch/arm/boot/compressed/misc.c
index d4f891f..4873708 100644
--- a/arch/arm/boot/compressed/misc.c
+++ b/arch/arm/boot/compressed/misc.c
@@ -22,7 +22,13 @@ unsigned int __machine_arch_type;
#include <linux/types.h>
#include <linux/linkage.h>
-static void putstr(const char *ptr);
+static void __putstr(const char *ptr);
+#ifdef CONFIG_ARM_VERBOSE_BOOTUP
+#define putstr(__x) __putstr(__x)
+#else
+static inline void putstr(const char *ptr)
+{ }
+#endif
extern void error(char *x);
#include CONFIG_UNCOMPRESS_INCLUDE
@@ -83,7 +89,7 @@ static void icedcc_putc(int ch)
#define putc(ch) icedcc_putc(ch)
#endif
-static void putstr(const char *ptr)
+static void __putstr(const char *ptr)
{
char c;
@@ -115,9 +121,9 @@ void error(char *x)
{
arch_error(x);
- putstr("\n\n");
- putstr(x);
- putstr("\n\n -- System halted");
+ __putstr("\n\n");
+ __putstr(x);
+ __putstr("\n\n -- System halted");
while(1); /* Halt */
}
--
2.1.4
reply other threads:[~2015-05-18 15:52 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=1431964243-9995-1-git-send-email-o.mandel@menlosystems.com \
--to=o.mandel@menlosystems.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux@arm.linux.org.uk \
--cc=marex@denx.de \
/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®