linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: magnus.damm@gmail.com (Magnus Damm)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] clkdev: add support to lookup for early platform device
Date: Thu, 28 Apr 2011 14:47:31 +0900	[thread overview]
Message-ID: <BANLkTiksMmAddsnpo9+jHTxE3jBDv0Y71g@mail.gmail.com> (raw)
In-Reply-To: <20110428051203.GB3852@game.jcrosoft.org>

On Thu, Apr 28, 2011 at 2:12 PM, Jean-Christophe PLAGNIOL-VILLARD
<plagnioj@jcrosoft.com> wrote:
> On 12:38 Thu 28 Apr ? ? , Paul Mundt wrote:
>> On Thu, Apr 28, 2011 at 05:17:04AM +0200, Jean-Christophe PLAGNIOL-VILLARD wrote:
>> > On 12:08 Thu 28 Apr ? ? , Paul Mundt wrote:
>> > > This is a non-argument until you demonstrate a use case where we have a
>> > > reasonable expectation for the clock framework to be available and the
>> > > slab allocator not.
>> > >
>> > > If you're thinking about the SH earlyprintk case then I suggest you look
>> > > at the sh-sci driver to see how we presently deal with the situation
>> > > there.
>> > the sh-sci driver expect the clock will enable for him
>> > which did IIRC Magnus on sh-mobile
>> > I do not want to do so
>> >
>> > I've unfortunatly on at91 I use the early device during the map_io
>> >
>> > so the slab is available and bootmem either
>> >
>> Yes, on sh-sci we assume that the clock is supplied to the port that we
>> are using for earlyprintk and we simply take over management of it via
>> the clock framework when the rest of the driver core comes online.
>>
>> Oddly enough, 100% of the time that we've wanted to have a serial console
>> it's been on the same port as the boot loader, which has to do the
>> initialization anyways. If you're using JTAG or something else for
>> loading, you've already got to do register writes for setting up bus
>> timings and the like, so it's not obvious why you can't set up some
>> sensible defaults for the clock registers supplying your serial port,
>> either.
>>
>> On top of that, ARM also has its own earlyprintk and eartly uart debug
>> macros available to you. If you're trying to bring more driver core stuff
>> online before either of slab or bootmem are available to you outside of
>> the context of the existing functionality: too bad. It's not worth the
>> world of pain for a corner case of a corner case.
>>
>> Again, until you explain concretely why you have this as a real use case
>> that needs to be solved generically instead of some pointless theoretical
>> wanking it's simply not possible to take this requirement seriously. This
>> was the conclusion we came to when modelling the earlytimer and
>> earlyprintk code for SH in the first place, and the burden of proof is on
>> you to demonstrate why any of these things are insufficient for your
>> platform.
> How did you manage to get the clock for the earlytimer?

As you can see in the upstream SH-Mobile ARM code, the timer setup is
happening after the clocks have been initialized in the ->timer
callback in MACHINE_START()/MACHINE_END.

/ magnus

  reply	other threads:[~2011-04-28  5:47 UTC|newest]

Thread overview: 26+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-20 14:05 [PATCH] clkdev: add support to lookup for early platform device Jean-Christophe PLAGNIOL-VILLARD
2011-04-27  8:42 ` Russell King - ARM Linux
2011-04-27 10:31   ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-27 10:47     ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-27 15:00       ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-27 22:12         ` Greg KH
2011-04-28  2:09         ` Paul Mundt
2011-04-28  2:45           ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28  3:08             ` Paul Mundt
2011-04-28  3:17               ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28  3:20                 ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28  3:35                   ` Magnus Damm
2011-04-28  3:29                     ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28  3:44                       ` Magnus Damm
2011-04-28  8:33                       ` Russell King - ARM Linux
2011-04-28  9:28                         ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28  3:38                 ` Paul Mundt
2011-04-28  4:31                   ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28  4:46                     ` Saravana Kannan
2011-04-28  4:50                       ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28  5:12                   ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28  5:47                     ` Magnus Damm [this message]
2011-04-28  8:35                     ` Russell King - ARM Linux
2011-04-28  9:26                       ` Jean-Christophe PLAGNIOL-VILLARD
2011-04-28 10:07                         ` Russell King - ARM Linux
2011-04-28 11:19                           ` Jean-Christophe PLAGNIOL-VILLARD

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=BANLkTiksMmAddsnpo9+jHTxE3jBDv0Y71g@mail.gmail.com \
    --to=magnus.damm@gmail.com \
    --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).