public inbox for u-boot@lists.denx.de
 help / color / mirror / Atom feed
From: Igor Grinberg <grinberg@compulab.co.il>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH V4 1/2] ehci-omap: driver for EHCI host on OMAP3
Date: Thu, 22 Dec 2011 13:18:58 +0200	[thread overview]
Message-ID: <4EF31222.7030605@compulab.co.il> (raw)
In-Reply-To: <CAAL8m4wfEMcOj0KwU5zFZP6RA22yeyeRVQ97DK3ezThBNLCF3Q@mail.gmail.com>

On 12/22/11 12:49, Govindraj wrote:
> On Thu, Dec 22, 2011 at 3:29 PM, Igor Grinberg <grinberg@compulab.co.il> wrote:
>> On 12/22/11 11:26, Govindraj wrote:
>>> Hi Igor,
>>>
> 
> [...]
> 
>>>
>>> probably the right method to do is as we did for panda,
>>>
>>> Add to armv7/omap3/clock.c (soc specific code) to enable usb-host clocks.
>>>
>>> as done in below patch for omap4 socs.
>>>
>>> http://patchwork.ozlabs.org/patch/131365/
>>
>> Hmmm... I don't like that patch - this is the right method...
>> but only for panda!
>> For panda it makes sense to enable the USB related clocks by default
>> because it has many of its boot important peripherals wired to USB.
>> That is not the case with majority of OMAP3 (and I bet with many
>> other OMAP4) boards.
>> Therefore, I think the USB clocks need to be turned on
>> only if the board requests them to be turned on and not as a part
>> of the default clock initialization by the PRCM subsystem
>> (unless it is configurable in the board config file).
>>
> 
> okay, I thought nothing wrong in keeping them enabled by default.
> since all un-used clocks will be gated once kernel is loaded.
> Am I missing some thing here?

May be there is nothing *too* wrong except for power consumption or
may be some other things I can't think of right now...
But, you should not rely on what will happen when kernel is loaded.
Also, you should not assume, that the Linux kernel will be loaded at all...
There are other OSes around that can also use U-Boot as a boot loader.
Also, there are stand alone applications that do not use any OS at all...
We are in the embedded world also, not just mobile...
(And if we are talking about mobile, then power consumption is important).

> 
> so as discussed earlier we can add ehci_omap3_clock_init
> into ehci-omap.c that can be used from all omap3 socs.

This is a bit confusing...
Let's try it that way:
1) ehci-omap.c should have common OMAP (OMAP3/4/5...) settings
2) ehci-omap.c should call ehci_clk_{enable|disable}() which should
   be implemented in a SoC *dependent* way (e.g. armv7/omap{3|4}/clock.c)
3) board specific stuff (e.g. PHY reset GPIO) should be passed
   to the common code to avoid code duplication.
4) probably, some other things that I've forgotten...


-- 
Regards,
Igor.

  reply	other threads:[~2011-12-22 11:18 UTC|newest]

Thread overview: 41+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-12-12 23:15 [U-Boot] [PATCH V4 0/2] Support for HTKW mcx board Ilya Yanok
2011-12-12 23:15 ` [U-Boot] [PATCH V4 1/2] ehci-omap: driver for EHCI host on OMAP3 Ilya Yanok
2011-12-19 23:17   ` Ilya Yanok
2011-12-22  6:55   ` Govindraj
2011-12-22  8:14     ` Igor Grinberg
2011-12-22  9:26       ` Govindraj
2011-12-22  9:59         ` Igor Grinberg
2011-12-22 10:49           ` Govindraj
2011-12-22 11:18             ` Igor Grinberg [this message]
2011-12-22 11:42               ` Govindraj
2011-12-22 13:24     ` Ilya Yanok
2012-01-15 20:40       ` Remy Bohmer
2012-01-15 22:04         ` Tom Rini
2012-01-16  7:58           ` Govindraj
2012-01-16  9:57             ` Stefano Babic
2012-01-17  6:14               ` Govindraj
2012-01-25 10:32                 ` Stefano Babic
2012-01-25 20:49                   ` Tom Rini
2012-01-27  9:07                     ` Govindraj
2012-01-27  9:12                       ` Stefano Babic
2011-12-12 23:15 ` [U-Boot] [PATCH V4 2/2] mcx: support for HTKW mcx board Ilya Yanok
2011-12-13 18:52   ` Tom Rini
2011-12-13 18:57     ` Ilya Yanok
2011-12-13 19:13     ` Ilya Yanok
2011-12-13 19:30       ` Tom Rini
2011-12-13 19:44         ` Ilya Yanok
2011-12-13 21:47           ` Tom Rini
2011-12-14  0:06             ` Ilya Yanok
2011-12-14  2:48               ` Tom Rini
2011-12-14 16:09                 ` Ilya Yanok
2011-12-13 23:54     ` [U-Boot] [PATCH V5 " Ilya Yanok
2011-12-14 16:05       ` [U-Boot] [PATCH V6 " Ilya Yanok
2011-12-19 22:55         ` Ilya Yanok
2011-12-19 22:56           ` Tom Rini
2011-12-19 23:07             ` Ilya Yanok
2011-12-19 23:12             ` Anatolij Gustschin
2011-12-19 23:16               ` Ilya Yanok
2012-02-05 14:57         ` [U-Boot] [PATCH V7] " Stefano Babic
2012-02-06 12:42           ` Igor Grinberg
2012-02-08  9:30         ` [U-Boot] [PATCH V8] " Stefano Babic
2012-02-08 10:07           ` Igor Grinberg

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=4EF31222.7030605@compulab.co.il \
    --to=grinberg@compulab.co.il \
    --cc=u-boot@lists.denx.de \
    /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