All of lore.kernel.org
 help / color / mirror / Atom feed
From: Scott Wood <scottwood@freescale.com>
To: Kumar Gala <galak@kernel.crashing.org>
Cc: linuxppc-dev@lists.ozlabs.org,
	Zhao Chenhui <chenhui.zhao@freescale.com>,
	linux-kernel@vger.kernel.org
Subject: Re: [PATCH v6 1/5] powerpc/85xx: implement hardware timebase sync
Date: Tue, 26 Jun 2012 16:45:55 -0500	[thread overview]
Message-ID: <4FEA2D93.3030002@freescale.com> (raw)
In-Reply-To: <AB6D43A9-FC54-40D2-A9B0-8B2E785124F9@kernel.crashing.org>

On 06/26/2012 09:03 AM, Kumar Gala wrote:
> 
> On Jun 26, 2012, at 5:25 AM, Zhao Chenhui wrote:
> 
>> Do hardware timebase sync. Firstly, stop all timebases, and transfer
>> the timebase value of the boot core to the other core. Finally,
>> start all timebases.
>>
>> Only apply to dual-core chips, such as MPC8572, P2020, etc.
>>
>> Signed-off-by: Zhao Chenhui <chenhui.zhao@freescale.com>
>> Signed-off-by: Li Yang <leoli@freescale.com>
>> ---
>> Changes for v6:
>> * added 85xx_TB_SYNC
>> * added isync() after set_tb()
>> * removed extra entries from mpc85xx_smp_guts_ids
> 
> Why only on dual-core chips?  Is this because of something related to
> 2 cores, or related to corenet vs non-corenet SoCs and how turning
> on/off the timebase works in the SOC?

Some parts are due to corenet versus non-corenet, such as the actual
register you write to to disable/enable the timebase.

There's also a two-core assumption in the synchronization code which
I've complained about multiple times -- although on closer inspection it
looks like this is done under cpu_add_remove_lock, and we can assume
that there's only one core at a time in take_timebase(), regardless of
how many cores are in the system.

-Scott

WARNING: multiple messages have this Message-ID (diff)
From: Scott Wood <scottwood@freescale.com>
To: Kumar Gala <galak@kernel.crashing.org>
Cc: Zhao Chenhui <chenhui.zhao@freescale.com>,
	<linuxppc-dev@lists.ozlabs.org>, <linux-kernel@vger.kernel.org>,
	<leoli@freescale.com>
Subject: Re: [PATCH v6 1/5] powerpc/85xx: implement hardware timebase sync
Date: Tue, 26 Jun 2012 16:45:55 -0500	[thread overview]
Message-ID: <4FEA2D93.3030002@freescale.com> (raw)
In-Reply-To: <AB6D43A9-FC54-40D2-A9B0-8B2E785124F9@kernel.crashing.org>

On 06/26/2012 09:03 AM, Kumar Gala wrote:
> 
> On Jun 26, 2012, at 5:25 AM, Zhao Chenhui wrote:
> 
>> Do hardware timebase sync. Firstly, stop all timebases, and transfer
>> the timebase value of the boot core to the other core. Finally,
>> start all timebases.
>>
>> Only apply to dual-core chips, such as MPC8572, P2020, etc.
>>
>> Signed-off-by: Zhao Chenhui <chenhui.zhao@freescale.com>
>> Signed-off-by: Li Yang <leoli@freescale.com>
>> ---
>> Changes for v6:
>> * added 85xx_TB_SYNC
>> * added isync() after set_tb()
>> * removed extra entries from mpc85xx_smp_guts_ids
> 
> Why only on dual-core chips?  Is this because of something related to
> 2 cores, or related to corenet vs non-corenet SoCs and how turning
> on/off the timebase works in the SOC?

Some parts are due to corenet versus non-corenet, such as the actual
register you write to to disable/enable the timebase.

There's also a two-core assumption in the synchronization code which
I've complained about multiple times -- although on closer inspection it
looks like this is done under cpu_add_remove_lock, and we can assume
that there's only one core at a time in take_timebase(), regardless of
how many cores are in the system.

-Scott


  reply	other threads:[~2012-06-26 21:46 UTC|newest]

Thread overview: 50+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-06-26 10:25 [PATCH v6 1/5] powerpc/85xx: implement hardware timebase sync Zhao Chenhui
2012-06-26 10:25 ` Zhao Chenhui
2012-06-26 10:25 ` [PATCH v6 2/5] powerpc/85xx: add HOTPLUG_CPU support Zhao Chenhui
2012-06-26 10:25   ` Zhao Chenhui
2012-06-26 10:25 ` [PATCH v6 3/5] powerpc/85xx: add sleep and deep sleep support Zhao Chenhui
2012-06-26 10:25   ` Zhao Chenhui
2012-07-13 12:27   ` Kumar Gala
2012-07-13 12:27     ` Kumar Gala
2012-06-26 10:25 ` [PATCH v6 4/5] fsl_pmc: Add API to enable device as wakeup event source Zhao Chenhui
2012-06-26 10:25   ` Zhao Chenhui
2012-06-26 10:25 ` [PATCH v6 5/5] powerpc/85xx: add support to JOG feature using cpufreq interface Zhao Chenhui
2012-06-26 10:25   ` Zhao Chenhui
2012-06-26 14:03 ` [PATCH v6 1/5] powerpc/85xx: implement hardware timebase sync Kumar Gala
2012-06-26 14:03   ` Kumar Gala
2012-06-26 21:45   ` Scott Wood [this message]
2012-06-26 21:45     ` Scott Wood
2012-06-26 22:10     ` Benjamin Herrenschmidt
2012-06-26 22:10       ` Benjamin Herrenschmidt
2012-06-27 10:10   ` Zhao Chenhui
2012-06-27 10:10     ` Zhao Chenhui
2012-06-26 22:10 ` Benjamin Herrenschmidt
2012-06-26 22:10   ` Benjamin Herrenschmidt
2012-06-27 10:21   ` Zhao Chenhui
2012-06-27 10:21     ` Zhao Chenhui
2012-06-27 11:48     ` Benjamin Herrenschmidt
2012-06-27 11:48       ` Benjamin Herrenschmidt
2012-06-28  3:38       ` Zhao Chenhui
2012-06-28  3:38         ` Zhao Chenhui
2012-06-28 10:50         ` Benjamin Herrenschmidt
2012-06-28 10:50           ` Benjamin Herrenschmidt
2012-06-28 18:30           ` Kumar Gala
2012-06-28 18:30             ` Kumar Gala
2012-06-29 10:33             ` Zhao Chenhui-B35336
2012-06-29 10:33               ` Zhao Chenhui-B35336
2012-07-02 10:44           ` Zhao Chenhui
2012-07-02 10:44             ` Zhao Chenhui
2012-06-29 15:39 ` Tabi Timur-B04825
2012-06-29 15:39   ` Tabi Timur-B04825
2012-06-29 15:57   ` Scott Wood
2012-06-29 15:57     ` Scott Wood
2012-06-29 16:04     ` Timur Tabi
2012-06-29 16:04       ` Timur Tabi
2012-06-29 16:10       ` Scott Wood
2012-06-29 16:10         ` Scott Wood
2012-06-29 16:12         ` Timur Tabi
2012-06-29 16:12           ` Timur Tabi
2012-06-29 17:10           ` Scott Wood
2012-06-29 17:10             ` Scott Wood
2012-07-02 10:10   ` Zhao Chenhui
2012-07-02 10:10     ` Zhao Chenhui

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=4FEA2D93.3030002@freescale.com \
    --to=scottwood@freescale.com \
    --cc=chenhui.zhao@freescale.com \
    --cc=galak@kernel.crashing.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linuxppc-dev@lists.ozlabs.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 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.