All of lore.kernel.org
 help / color / mirror / Atom feed
From: Peter Korsgaard <jacmet@sunsite.dk>
To: Paul Walmsley <paul@pwsan.com>
Cc: linux-omap@vger.kernel.org
Subject: Re: reset handling in am335x hwmod data
Date: Thu, 10 Jan 2013 08:50:01 +0100	[thread overview]
Message-ID: <87d2xda34m.fsf@dell.be.48ers.dk> (raw)
In-Reply-To: <alpine.DEB.2.00.1212232033030.8937@utopia.booyaka.com> (Paul Walmsley's message of "Sun, 23 Dec 2012 20:58:13 +0000 (UTC)")

>>>>> "Paul" == Paul Walmsley <paul@pwsan.com> writes:

Hi Paul,

Thanks for the detailed explanaition, and sorry for the slow response -
I've been away on holidays.

 >> Now the question is why is this configured like this?

 Paul> This behavior is intended to decouple the kernel from the
 Paul> bootloader, or previously-booted operating system (e.g., the
 Paul> kexec case).  The original goal was to place the system in an
 Paul> known safe state as soon as possible after the kernel starts.
 Paul> This is to prevent misconfigured or previously-configured devices
 Paul> from trashing memory or chip power management in the
 Paul> currently-booted kernel.  It also avoids adding inadvertent
 Paul> bootloader dependencies in driver code.

 Paul> N.B., the plan is to change this behavior over the next few
 Paul> releases.  Devices that have drivers associated with them will be
 Paul> reset when the driver loads.  Driverless devices will be reset
 Paul> after drivers load, late in boot.

 >> Should E.G. the gpio controllers be changed to not reset or should it be 
 >> configurable in the dts?

 Paul> Probably the DTS is the right place, since this is a board- and
 Paul> bootloader-specific quirk.  The original intention was to allow
 Paul> board files to set this HWMOD_INIT_NO_RESET flag themselves - see
 Paul> mach-omap2/ omap_hwmod.c:omap_hwmod_no_setup_reset().  But since
 Paul> we've deprecated the board files, the DT data seems like the
 Paul> right place.

 Paul> It probably shouldn't be a GPIO-specific property.  Other devices
 Paul> like DSS will also need some kind of 'no-init-reset' property,
 Paul> since on many commercial devices, it's expected that some kind of
 Paul> splash screen will be presented by the bootloader and stay on
 Paul> during the boot process.

I tried changing omap_device_build_from_dt() to call
omap_hwmod_no_setup_reset() on the corresponding hwmod if a
ti,no-init-reset was present, but that doesn't work as the hwmod reset
happens quite a bit earlier (in omap_hwmod_setup_all()). Do you have
idea how I could work around this or is that the future reset change you
referred to above?


 Paul> However, it is probably safest in the long run if you can change
 Paul> the board design to require the SoC to actively reset the FPGA,
 Paul> rather than making reset the default state.  That way, if there's
 Paul> some hardware bug that requires the GPIO block to be reset, or if
 Paul> there's some GPIO glitch during power management, the FPGA won't
 Paul> be inadvertently reset.

Yes, I'll try to get that done for the next board spin.

Thanks!

-- 
Bye, Peter Korsgaard

  reply	other threads:[~2013-01-10  7:50 UTC|newest]

Thread overview: 19+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-12-21 15:32 reset handling in am335x hwmod data Peter Korsgaard
2012-12-23 20:58 ` Paul Walmsley
2013-01-10  7:50   ` Peter Korsgaard [this message]
2013-01-18 14:18     ` Peter Korsgaard
2013-01-22  2:53     ` Paul Walmsley
2013-05-17 13:50   ` Felipe Balbi
2013-05-17 13:53     ` Peter Korsgaard
2013-05-17 17:08     ` Kevin Hilman
2013-05-17 18:10       ` Peter Korsgaard
2013-05-17 18:19         ` Nishanth Menon
2013-05-20  6:38           ` Hiremath, Vaibhav
2013-05-20  6:55             ` Hiremath, Vaibhav
2013-05-20 15:06               ` Nishanth Menon
2013-05-20 17:47                 ` Hiremath, Vaibhav
2013-05-20 18:03                   ` Nishanth Menon
2013-05-20 18:20                     ` Hiremath, Vaibhav
2013-06-28 10:54                       ` Felipe Balbi
2013-07-02  4:37                         ` Hiremath, Vaibhav
2013-07-02 13:57                           ` Nishanth Menon

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=87d2xda34m.fsf@dell.be.48ers.dk \
    --to=jacmet@sunsite.dk \
    --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 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.