From: jon-hunter@ti•com (Jon Hunter)
To: linux-arm-kernel@lists•infradead.org
Subject: [PATCH 5/5] ARM: OMAP3: Update clocksource timer selection
Date: Fri, 1 Feb 2013 03:25:31 -0600 [thread overview]
Message-ID: <510B8A0B.9000600@ti.com> (raw)
In-Reply-To: <510B83D5.1090500@ti.com>
On 02/01/2013 02:59 AM, Jon Hunter wrote:
>
> On 02/01/2013 02:41 AM, Bedia, Vaibhav wrote:
>> Hi Jon,
>>
>> On Wed, Jan 30, 2013 at 22:34:31, Hunter, Jon wrote:
>>> When booting with device-tree for OMAP3 and AM335x devices and a gptimer
>>> is used as the clocksource (which is always the case for AM335x), a
>>> gptimer located in a power domain that is not always-on is selected.
>>> Ideally we should use a gptimer located in a power domain that is always
>>> on (such as the wake-up domain) so that time can be maintained during a
>>> kernel suspend without keeping on additional power domains unnecessarily.
>>>
>>> In order to fix this so that we can select a gptimer located in a power
>>> domain that is always-on, the following changes were made ...
>>> 1. Currently, only when selecting a gptimer to use for a clockevent
>>> timer, do we pass a timer property that can be used to select a
>>> specific gptimer. Change this so that we can pass a property when
>>> selecting a gptimer to use for a clocksource timer too.
>>> 2. Currently, when selecting either a gptimer to use for a clockevent
>>> timer or a clocksource timer and no timer property is passed, then
>>> the first available timer is selected regardless of the properties
>>> it has. Change this so that if no properties are passed, then a timer
>>> that does not have additional features (such as always-on, dsp-irq,
>>> pwm, and secure) is selected.
>>>
>>> Please note that using a gptimer for both clocksource and clockevents
>>> can have a system power impact during idle. The reason being is that
>>> OMAP and AMxxx devices typically only have one gptimer in a power domain
>>> that is always-on. Therefore when the kernel is idle both the clocksource
>>> and clockevent timers will be active and this will keep additional power
>>> domains on. During kernel suspend, only the clocksource timer is active
>>> and therefore, it is better to use a gptimer in a power domain that is
>>> always-on for clocksource.
>>>
>>
>> It's always a pleasure reading the changelog in your patches :)
>
> Thanks.
>
>> [...]
>>>
>>> #if defined(CONFIG_ARCH_OMAP3) || defined(CONFIG_SOC_AM33XX)
>>> -OMAP_SYS_GP_TIMER_INIT(3, 1, "timer_sys_ck", "ti,timer-alwon",
>>> - 2, "timer_sys_ck");
>>> +OMAP_SYS_GP_TIMER_INIT(3, 2, "timer_sys_ck", NULL,
>>> + 1, "timer_sys_ck", "ti,timer-alwon");
>>> #endif
>>>
>>
>> Minor point... was the intention of changing of clkev_nr and clksrc_nr to make
>> it consistent with what happens on AM33xx which is DT-only?
>
> I don't see this as being DT specific. It is more of a policy change to
> ensure a wake-up domain timer is used for clocksource when we are using
> gptimers for both clocksource and clockevents. It was your patch for
> AM335x that made me see the need for this, if that makes sense. May be I
> should have referenced that in the changelog.
Sorry to be clear, I don't see the policy change as DT specific.
In answer to your question, yes clkev_nr and clksrc_nr are changed so
the policy it is consistent regardless of whether you use DT or not. In
other words, an OMAP3 board using a gptimer for clocksource (such as
cm-t3517) and does not use DT, would work the same as AM335x with DT.
Cheers
Jon
next prev parent reply other threads:[~2013-02-01 9:25 UTC|newest]
Thread overview: 20+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-30 17:04 [PATCH 0/5] ARM: OMAP2+: System timer updates Jon Hunter
2013-01-30 17:04 ` [PATCH 1/5] ARM: OMAP2+: Display correct system timer name Jon Hunter
2013-02-01 8:41 ` Bedia, Vaibhav
2013-02-01 8:53 ` Jon Hunter
2013-02-01 9:31 ` Bedia, Vaibhav
2013-02-01 10:34 ` Jon Hunter
2013-01-30 17:04 ` [PATCH 2/5] ARM: OMAP2+: Remove hard-coded test on timer ID Jon Hunter
2013-01-30 17:04 ` [PATCH 3/5] ARM: OMAP2+: Simplify system timer clock definitions Jon Hunter
2013-01-30 17:04 ` [PATCH 4/5] ARM: OMAP2+: Simplify system timers definitions Jon Hunter
2013-01-31 9:09 ` Igor Grinberg
2013-02-04 15:27 ` Jon Hunter
2013-01-30 17:04 ` [PATCH 5/5] ARM: OMAP3: Update clocksource timer selection Jon Hunter
2013-01-31 9:08 ` Igor Grinberg
2013-01-31 16:07 ` Jon Hunter
2013-02-01 8:41 ` Bedia, Vaibhav
2013-02-01 8:59 ` Jon Hunter
2013-02-01 9:25 ` Jon Hunter [this message]
2013-02-01 9:31 ` Bedia, Vaibhav
2013-01-31 9:40 ` [PATCH 0/5] ARM: OMAP2+: System timer updates Santosh Shilimkar
2013-02-01 8:41 ` Bedia, Vaibhav
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=510B8A0B.9000600@ti.com \
--to=jon-hunter@ti$(echo .)com \
--cc=linux-arm-kernel@lists$(echo .)infradead.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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