From: Kevin Hilman <khilman@deeprootsystems.com>
To: Paul Walmsley <paul@pwsan.com>
Cc: Pramod <pramod.gurav@ti.com>, Ming Lei <tom.leiming@gmail.com>,
Govindraj <govindraj.ti@gmail.com>,
"Premi, Sanjeev" <premi@ti.com>,
"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
"Govindraj R." <govindraj.raja@ti.com>
Subject: Re: beagle hangs in uart3 disabling clocks
Date: Tue, 05 Oct 2010 10:33:32 -0700 [thread overview]
Message-ID: <87hbh0sfwz.fsf@deeprootsystems.com> (raw)
In-Reply-To: <alpine.DEB.2.00.1010051021350.13816@utopia.booyaka.com> (Paul Walmsley's message of "Tue, 5 Oct 2010 11:26:19 -0600 (MDT)")
Paul Walmsley <paul@pwsan.com> writes:
> On Tue, 5 Oct 2010, Pramod wrote:
>
>> On Tuesday 05 October 2010 03:33 PM, Paul Walmsley wrote:
>> >
>> > Looks to me like it boots fine. If you had hwmod debugging enabled, your
>> > kernel should have crashed after
>> >
>> > omap-hsuart.0: ttyO0 at MMIO 0x4806a000 (irq = 72) is a OMAP UART0
>> > omap-hsuart.1: ttyO1 at MMIO 0x4806c000 (irq = 73) is a OMAP UART1
>> > omap-hsuart.2: ttyO2 at MMIO 0x49020000 (irq = 74) is a OMAP UART2
>> >
>> > ... but it didn't crash there. I'm not seeing any hwmod debug messages
>> > though, so you probably don't have DEBUG defined in omap_hwmod.c.
>> >
>> > So, I suspect whatever problem you're seeing is unrelated to the problem
>> > that the patch was intended to solve.
>> >
>> >
>> > - Paul
>>
>> The hwmod debug messages will be seen when I enable them on the go with:
>> echo -n 'file omap_hwmod.c +p' > /debug/dynamic_debug/control
>>
>> This will show lots of logs as below ending with UART3 clock disabling and a
>> hang.
>>
>> omap_hwmod:omap_hwmod: uart1: idling
>> omap_hwmod:omap_hwmod: uart1: disabling clocks
>> omap_hwmod:omap_hwmod: uart2: idling
>> omap_hwmod:omap_hwmod: uart2: disabling clocks
>> omap_hwmod:omap_hwmod: uart1: enabling
>> omap_hwmod:omap_hwmod: uart1: enabling clocks
>> omap_hwmod:omap_hwmod: uart2: enabling
>> omap_hwmod:omap_hwmod: uart2: enabling clocks
>> omap_hwmod:omap_hwmod: uart3: idling
>> omap_hwmod:omap_hwmod: uart3: disabling clock
>
> OK, the problem here is probably with the real serial console generating
> messages while the hwmod is idle, not earlyconsole/bootconsole. The patch
> could be extended to fix that, but it doesn't address that right now. Why
> don't you take a shot at doing that?
>
> In this context, the real serial console is only part of the problem.
> For a complete fix, I suspect that one would have to tinker with the OMAP
> UART driver or serial core, since other drivers beyond the real console
> may be using the serial port (e.g. Bluetooth).
>
> Also, thinking about this issue further, there needs to be an additional
> fix at least in omap_serial_init_port() to ensure that the UART TX FIFO is
> completely drained before it starts messing around with the underlying
> hwmod. Similarly, whenever the PM runtime conversion is done for
> drivers/serial/omap-serial.c, it will need to ensure that the TX FIFO has
> drained before going to idle.
Now that the base omap-serial driver is queued for mainline, the next
step is to move all the PM hackery from mach-omap2/serial.c into the
driver itself by using the runtime PM API.
This should ensure that any users of the real serial driver will have an
active UART.
Kevin
next prev parent reply other threads:[~2010-10-05 17:33 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-10-03 9:04 beagle hangs in uart3 disabling clocks Ming Lei
2010-10-03 17:27 ` Premi, Sanjeev
2010-10-04 12:13 ` Ming Lei
2010-10-04 12:17 ` Pramod
2010-10-04 12:38 ` Govindraj
2010-10-04 15:18 ` Ming Lei
2010-10-04 15:44 ` Kevin Hilman
2010-10-04 16:17 ` Ming Lei
2010-10-04 18:54 ` Kevin Hilman
2010-10-05 5:36 ` Ming Lei
2010-10-05 6:14 ` Paul Walmsley
2010-10-05 6:47 ` Ming Lei
2010-10-05 7:13 ` Pramod
2010-10-05 7:19 ` Paul Walmsley
2010-10-05 9:34 ` Pramod
2010-10-05 9:47 ` Paul Walmsley
2010-10-05 9:58 ` Pramod
2010-10-05 10:03 ` Paul Walmsley
2010-10-05 11:09 ` Pramod
2010-10-05 17:26 ` Paul Walmsley
2010-10-05 17:33 ` Kevin Hilman [this message]
2010-10-04 15:25 ` Kevin Hilman
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=87hbh0sfwz.fsf@deeprootsystems.com \
--to=khilman@deeprootsystems.com \
--cc=govindraj.raja@ti.com \
--cc=govindraj.ti@gmail.com \
--cc=linux-omap@vger.kernel.org \
--cc=paul@pwsan.com \
--cc=pramod.gurav@ti.com \
--cc=premi@ti.com \
--cc=tom.leiming@gmail.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.