From: Tomi Valkeinen <tomi.valkeinen@ti.com>
To: Paul Walmsley <paul@pwsan.com>
Cc: "Cousson, Benoit" <b-cousson@ti.com>,
"Hilman, Kevin" <khilman@ti.com>,
"linux-omap@vger.kernel.org" <linux-omap@vger.kernel.org>,
"linux-arm-kernel@lists.infradead.org"
<linux-arm-kernel@lists.infradead.org>
Subject: Re: [PATCHv2 2/2] OMAP: add omap_device_reset()
Date: Mon, 30 May 2011 08:55:47 +0300 [thread overview]
Message-ID: <1306734947.2117.9.camel@deskari> (raw)
In-Reply-To: <alpine.DEB.2.00.1105292022080.8973@utopia.booyaka.com>
On Sun, 2011-05-29 at 20:24 -0600, Paul Walmsley wrote:
> Hi Tomi,
>
> On Fri, 27 May 2011, Tomi Valkeinen wrote:
>
> > DSS driver has been designed so that it resets the HW before it begins
> > programming it. That way we get the HW into known state. Otherwise we
> > need to be extra careful to program all possible registers to a sane
> > value. Not impossible, of course, but requires extra work.
> >
> > I noticed the problem with DSI driver, it didn't work anymore if I
> > didn't reset it.
>
> One thing that I don't quite understand about this thread is that the
> hwmod code should be resetting the DSS hwmods when the system boots. Is
> something not working with this process?
I believe that is working fine.
The problem appears when DSS is turned off (i.e. the screen is blanked)
and then started again. The driver has been written so that it will
reset the DSS HW before starting to use that particular DSS HW block, to
get a clean state. Remove that reset, and we've got all the old register
values lying around, causing the device to malfunction.
This should be fixable in the driver, of course, although my experience
with DSI (and DSS in general) shows that it's not always very easy to
stop and restart the HW without a reset.
However, I'd still argue that a driver is more robust if it does do a
reset when starting up the HW. Perhaps the driver should be developed
without that reset, but in the production device the reset should give
us extra protection for unexpected situations.
> That is a separate case from the error recovery case. Sounds like we may
> need to expose a reset function for that purpose as well. Tomi, I don't
> think your proposed patch is enough for this, though: we'd also need to
> reset the hwmod internal state for that module, and reprogram the
> SYSCONFIG bits, etc. as mach-omap2/omap_hwmod.c:_setup() does.
Ah, ok, sounds right. It worked for me, but I probably wouldn't notice
if the PM bits in SYSCONFIG are wrong, as I didn't do any PM testing.
Tomi
prev parent reply other threads:[~2011-05-30 5:55 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-05-27 7:38 [PATCHv2 0/2] Some omap_device/hwmod/pwrdomain patches Tomi Valkeinen
2011-05-27 7:38 ` [PATCHv2 1/2] OMAP: change get_context_loss_count ret value to int Tomi Valkeinen
2011-05-27 7:38 ` [PATCHv2 2/2] OMAP: add omap_device_reset() Tomi Valkeinen
2011-05-27 12:38 ` Cousson, Benoit
2011-05-27 12:46 ` Tomi Valkeinen
2011-05-27 14:43 ` Cousson, Benoit
2011-05-27 14:51 ` Santosh Shilimkar
2011-05-27 15:00 ` Cousson, Benoit
2011-05-27 15:06 ` Santosh Shilimkar
2011-05-27 16:40 ` Tomi Valkeinen
2011-05-30 2:15 ` Paul Walmsley
2011-05-30 6:00 ` Tomi Valkeinen
2011-05-30 8:49 ` Cousson, Benoit
2011-05-30 2:24 ` Paul Walmsley
2011-05-30 5:55 ` Tomi Valkeinen [this message]
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=1306734947.2117.9.camel@deskari \
--to=tomi.valkeinen@ti.com \
--cc=b-cousson@ti.com \
--cc=khilman@ti.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-omap@vger.kernel.org \
--cc=paul@pwsan.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;
as well as URLs for NNTP newsgroup(s).