From: w.sang@pengutronix.de (Wolfram Sang)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] arm: mach-imx: enable all uart clocks for DEBUG_LL
Date: Thu, 25 Aug 2011 12:57:36 +0200 [thread overview]
Message-ID: <1314269856-20000-1-git-send-email-w.sang@pengutronix.de> (raw)
If you want to move the DEBUG_LL uart, simply changing the base address
in debug-macro.S will not be enough. One needs to enable the correct
clock during clock init, too, otherwise the kernel remains silent. This
is too easy to forget, so enable all uart clocks for DEBUG_LL to save
precious developer time.
Signed-off-by: Wolfram Sang <w.sang@pengutronix.de>
Cc: Sascha Hauer <s.hauer@pengutronix.de>
---
arch/arm/mach-imx/clock-imx21.c | 3 +++
arch/arm/mach-imx/clock-imx25.c | 4 ++++
arch/arm/mach-imx/clock-imx27.c | 5 +++++
arch/arm/mach-imx/clock-imx35.c | 2 +-
4 files changed, 13 insertions(+), 1 deletions(-)
diff --git a/arch/arm/mach-imx/clock-imx21.c b/arch/arm/mach-imx/clock-imx21.c
index ee15d8c..e04c264 100644
--- a/arch/arm/mach-imx/clock-imx21.c
+++ b/arch/arm/mach-imx/clock-imx21.c
@@ -1231,6 +1231,9 @@ int __init mx21_clocks_init(unsigned long lref, unsigned long href)
#if defined(CONFIG_DEBUG_LL) && !defined(CONFIG_DEBUG_ICEDCC)
clk_enable(&uart_clk[0]);
+ clk_enable(&uart_clk[1]);
+ clk_enable(&uart_clk[2]);
+ clk_enable(&uart_clk[3]);
#endif
mxc_timer_init(&gpt_clk[0], MX21_IO_ADDRESS(MX21_GPT1_BASE_ADDR),
diff --git a/arch/arm/mach-imx/clock-imx25.c b/arch/arm/mach-imx/clock-imx25.c
index e63e235..9c3e655 100644
--- a/arch/arm/mach-imx/clock-imx25.c
+++ b/arch/arm/mach-imx/clock-imx25.c
@@ -325,6 +325,10 @@ int __init mx25_clocks_init(void)
__raw_writel((1 << 5), CRM_BASE + CCM_CGCR2);
#if defined(CONFIG_DEBUG_LL) && !defined(CONFIG_DEBUG_ICEDCC)
clk_enable(&uart1_clk);
+ clk_enable(&uart2_clk);
+ clk_enable(&uart3_clk);
+ clk_enable(&uart4_clk);
+ clk_enable(&uart5_clk);
#endif
/* Clock source for lcdc and csi is upll */
diff --git a/arch/arm/mach-imx/clock-imx27.c b/arch/arm/mach-imx/clock-imx27.c
index 6912b82..561f88e 100644
--- a/arch/arm/mach-imx/clock-imx27.c
+++ b/arch/arm/mach-imx/clock-imx27.c
@@ -754,6 +754,11 @@ int __init mx27_clocks_init(unsigned long fref)
#if defined(CONFIG_DEBUG_LL) && !defined(CONFIG_DEBUG_ICEDCC)
clk_enable(&uart1_clk);
+ clk_enable(&uart2_clk);
+ clk_enable(&uart3_clk);
+ clk_enable(&uart4_clk);
+ clk_enable(&uart5_clk);
+ clk_enable(&uart6_clk);
#endif
mxc_timer_init(&gpt1_clk, MX27_IO_ADDRESS(MX27_GPT1_BASE_ADDR),
diff --git a/arch/arm/mach-imx/clock-imx35.c b/arch/arm/mach-imx/clock-imx35.c
index 88b62a0..4957778 100644
--- a/arch/arm/mach-imx/clock-imx35.c
+++ b/arch/arm/mach-imx/clock-imx35.c
@@ -510,7 +510,7 @@ int __init mx35_clocks_init()
unsigned int cgr2 = 3 << 26, cgr3 = 0;
#if defined(CONFIG_DEBUG_LL) && !defined(CONFIG_DEBUG_ICEDCC)
- cgr2 |= 3 << 16;
+ cgr2 |= 3 << 16 | 3 << 18 | 3 << 20;
#endif
clkdev_add_table(lookups, ARRAY_SIZE(lookups));
--
1.7.5.4
next reply other threads:[~2011-08-25 10:57 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-08-25 10:57 Wolfram Sang [this message]
2011-08-30 14:56 ` [PATCH] arm: mach-imx: enable all uart clocks for DEBUG_LL Shawn Guo
2011-08-30 15:27 ` Shawn Guo
2011-08-30 15:55 ` Wolfram Sang
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=1314269856-20000-1-git-send-email-w.sang@pengutronix.de \
--to=w.sang@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.org \
/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;
as well as URLs for NNTP newsgroup(s).