All of lore.kernel.org
 help / color / mirror / Atom feed
From: Russell King - ARM Linux <linux@arm.linux.org.uk>
To: Tomasz Figa <tomasz.figa@gmail.com>
Cc: Chanwoo Choi <cw00.choi@samsung.com>,
	kgene.kim@samsung.com, t.figa@samsung.com,
	sajjan.linux@gmail.com, devicetree@vger.kernel.org,
	linux-samsung-soc@vger.kernel.org, arnd@arndb.de,
	marc.zyngier@arm.com, hyunhee.kim@samsung.com,
	sw0312.kim@samsung.com, linux-kernel@vger.kernel.org,
	yj44.cho@samsung.com, inki.dae@samsung.com,
	kyungmin.park@samsung.com, thomas.abraham@linaro.org,
	ben-linux@fluff.org, olof@lixom.net, chanho61.park@samsung.com,
	sachin.kamat@linaro.org, linux-arm-kernel@lists.infradead.org,
	tushar.behera@linaro.org
Subject: Re: [PATCHv4 4/7] ARM: EXYNOS: Enter a15 lowpower mode for Exynos3250 based on Cortex-a7
Date: Sat, 26 Apr 2014 01:30:44 +0100	[thread overview]
Message-ID: <20140426003044.GW26756@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <535AFCDF.20503@gmail.com>

On Sat, Apr 26, 2014 at 02:25:03AM +0200, Tomasz Figa wrote:
> On 25.04.2014 03:16, Chanwoo Choi wrote:
>> This patch decide proper lowpower mode of either a15 or a9 according to own ID
>> from Main ID register.
>>
>> Cc: Arnd Bergmann <arnd@arndb.de>
>> Cc: Marc Zynigier <marc.zyngier@arm.com>
>> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
>> Acked-by: Kyungmin Park <kyungmin.park@samsung.com>
>> ---
>>   arch/arm/mach-exynos/hotplug.c | 19 ++++++++++++-------
>>   1 file changed, 12 insertions(+), 7 deletions(-)
>>
>> diff --git a/arch/arm/mach-exynos/hotplug.c b/arch/arm/mach-exynos/hotplug.c
>> index 5eead53..acf3119 100644
>> --- a/arch/arm/mach-exynos/hotplug.c
>> +++ b/arch/arm/mach-exynos/hotplug.c
>> @@ -135,16 +135,21 @@ void __ref exynos_cpu_die(unsigned int cpu)
>>   	int primary_part = 0;
>>
>>   	/*
>> -	 * we're ready for shutdown now, so do it.
>> -	 * Exynos4 is A9 based while Exynos5 is A15; check the CPU part
>> -	 * number by reading the Main ID register and then perform the
>> -	 * appropriate sequence for entering low power.
>> +	 * Prepare the CPU for shutting down. The required sequence of
>> +	 * operations depends on core type. CPUID part number can be used to
>> +	 * determine the right way.
>>   	 */
>> -	asm("mrc p15, 0, %0, c0, c0, 0" : "=r"(primary_part) : : "cc");
>> -	if ((primary_part & 0xfff0) == 0xc0f0)
>> +	primary_part = read_cpuid_part_number();
>> +
>> +	switch (primary_part) {
>> +	case ARM_CPU_PART_CORTEX_A7:
>> +	case ARM_CPU_PART_CORTEX_A15:

Although I believe we're approaching the point where everyone just uses
ARM Ltd designed CPUs, it should be remembered that the part number
field is designer specific, so if we were being strict, we'd check both
the part number and the designer fields together.

-- 
FTTC broadband for 0.8mile line: now at 9.7Mbps down 460kbps up... slowly
improving, and getting towards what was expected from it.

WARNING: multiple messages have this Message-ID (diff)
From: linux@arm.linux.org.uk (Russell King - ARM Linux)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCHv4 4/7] ARM: EXYNOS: Enter a15 lowpower mode for Exynos3250 based on Cortex-a7
Date: Sat, 26 Apr 2014 01:30:44 +0100	[thread overview]
Message-ID: <20140426003044.GW26756@n2100.arm.linux.org.uk> (raw)
In-Reply-To: <535AFCDF.20503@gmail.com>

On Sat, Apr 26, 2014 at 02:25:03AM +0200, Tomasz Figa wrote:
> On 25.04.2014 03:16, Chanwoo Choi wrote:
>> This patch decide proper lowpower mode of either a15 or a9 according to own ID
>> from Main ID register.
>>
>> Cc: Arnd Bergmann <arnd@arndb.de>
>> Cc: Marc Zynigier <marc.zyngier@arm.com>
>> Signed-off-by: Chanwoo Choi <cw00.choi@samsung.com>
>> Acked-by: Kyungmin Park <kyungmin.park@samsung.com>
>> ---
>>   arch/arm/mach-exynos/hotplug.c | 19 ++++++++++++-------
>>   1 file changed, 12 insertions(+), 7 deletions(-)
>>
>> diff --git a/arch/arm/mach-exynos/hotplug.c b/arch/arm/mach-exynos/hotplug.c
>> index 5eead53..acf3119 100644
>> --- a/arch/arm/mach-exynos/hotplug.c
>> +++ b/arch/arm/mach-exynos/hotplug.c
>> @@ -135,16 +135,21 @@ void __ref exynos_cpu_die(unsigned int cpu)
>>   	int primary_part = 0;
>>
>>   	/*
>> -	 * we're ready for shutdown now, so do it.
>> -	 * Exynos4 is A9 based while Exynos5 is A15; check the CPU part
>> -	 * number by reading the Main ID register and then perform the
>> -	 * appropriate sequence for entering low power.
>> +	 * Prepare the CPU for shutting down. The required sequence of
>> +	 * operations depends on core type. CPUID part number can be used to
>> +	 * determine the right way.
>>   	 */
>> -	asm("mrc p15, 0, %0, c0, c0, 0" : "=r"(primary_part) : : "cc");
>> -	if ((primary_part & 0xfff0) == 0xc0f0)
>> +	primary_part = read_cpuid_part_number();
>> +
>> +	switch (primary_part) {
>> +	case ARM_CPU_PART_CORTEX_A7:
>> +	case ARM_CPU_PART_CORTEX_A15:

Although I believe we're approaching the point where everyone just uses
ARM Ltd designed CPUs, it should be remembered that the part number
field is designer specific, so if we were being strict, we'd check both
the part number and the designer fields together.

-- 
FTTC broadband for 0.8mile line: now at 9.7Mbps down 460kbps up... slowly
improving, and getting towards what was expected from it.

  reply	other threads:[~2014-04-26  0:31 UTC|newest]

Thread overview: 80+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-25  1:16 [PATCHv4 0/7] Support new Exynos3250 SoC based on Cortex-A7 dual core Chanwoo Choi
2014-04-25  1:16 ` Chanwoo Choi
2014-04-25  1:16 ` [PATCHv4 1/7] ARM: EXYNOS: Add Exynos3250 SoC ID Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-26  0:40   ` Tomasz Figa
2014-04-26  0:40     ` Tomasz Figa
2014-04-25  1:16 ` [PATCHv4 2/7] ARM: EXYNOS: Support secondary CPU boot of Exynos4212 Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-26  0:42   ` Tomasz Figa
2014-04-26  0:42     ` Tomasz Figa
2014-04-26 10:49     ` Kukjin Kim
2014-04-26 10:49       ` Kukjin Kim
2014-04-26 10:49       ` Kukjin Kim
2014-04-25  1:16 ` [PATCHv4 3/7] ARM: EXYNOS: Support secondary CPU boot of Exynos3250 Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-25  4:30   ` Tushar Behera
2014-04-25  4:30     ` Tushar Behera
2014-04-25  5:43     ` Chanwoo Choi
2014-04-25  5:43       ` Chanwoo Choi
2014-04-25  5:54       ` Tushar Behera
2014-04-25  5:54         ` Tushar Behera
2014-04-25  5:56         ` Chanwoo Choi
2014-04-25  5:56           ` Chanwoo Choi
2014-04-25  1:16 ` [PATCHv4 4/7] ARM: EXYNOS: Enter a15 lowpower mode for Exynos3250 based on Cortex-a7 Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-26  0:25   ` Tomasz Figa
2014-04-26  0:25     ` Tomasz Figa
2014-04-26  0:25     ` Tomasz Figa
2014-04-26  0:30     ` Russell King - ARM Linux [this message]
2014-04-26  0:30       ` Russell King - ARM Linux
2014-04-30  8:00     ` Chanwoo Choi
2014-04-30  8:00       ` Chanwoo Choi
2014-04-25  1:16 ` [PATCHv4 5/7] clk: samsung: exynos3250: Add clocks using common clock framework Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-26  0:39   ` Tomasz Figa
2014-04-26  0:39     ` Tomasz Figa
2014-04-26  0:39     ` Tomasz Figa
2014-05-13 11:49     ` Chanwoo Choi
2014-05-13 11:49       ` Chanwoo Choi
2014-05-13 16:28       ` Tomasz Figa
2014-05-13 16:28         ` Tomasz Figa
2014-05-13 16:28         ` Tomasz Figa
2014-05-14  6:57         ` Chanwoo Choi
2014-05-14  6:57           ` Chanwoo Choi
2014-05-14  6:57           ` Chanwoo Choi
2014-05-14 13:45           ` Tomasz Figa
2014-05-14 13:45             ` Tomasz Figa
2014-05-14 13:45             ` Tomasz Figa
2014-04-25  1:16 ` [PATCHv4 6/7] dt-bindings: add documentation for Exynos3250 clock controller Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-25  1:16 ` [PATCHv4 7/7] ARM: dts: Add device tree sources for Exynos3250 Chanwoo Choi
2014-04-25  1:16   ` Chanwoo Choi
2014-04-25  4:38   ` Tushar Behera
2014-04-25  4:38     ` Tushar Behera
2014-04-25  5:03     ` Chanwoo Choi
2014-04-25  5:03       ` Chanwoo Choi
2014-04-26  0:51   ` Tomasz Figa
2014-04-26  0:51     ` Tomasz Figa
2014-04-26 11:38     ` Tomasz Figa
2014-04-26 11:38       ` Tomasz Figa
2014-04-26 11:38       ` Tomasz Figa
2014-05-09  6:49       ` Chanwoo Choi
2014-05-09  6:49         ` Chanwoo Choi
2014-05-09  8:01         ` Tomasz Figa
2014-05-09  8:01           ` Tomasz Figa
2014-05-09  8:15           ` Chanwoo Choi
2014-05-09  8:15             ` Chanwoo Choi
2014-05-09  1:06     ` Chanwoo Choi
2014-05-09  1:06       ` Chanwoo Choi
2014-05-09  5:02       ` Tomasz Figa
2014-05-09  5:02         ` Tomasz Figa
2014-05-09  7:10         ` Chanwoo Choi
2014-05-09  7:10           ` Chanwoo Choi
2014-05-09  8:01           ` Tomasz Figa
2014-05-09  8:01             ` Tomasz Figa
2014-05-09  8:01             ` Tomasz Figa

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=20140426003044.GW26756@n2100.arm.linux.org.uk \
    --to=linux@arm.linux.org.uk \
    --cc=arnd@arndb.de \
    --cc=ben-linux@fluff.org \
    --cc=chanho61.park@samsung.com \
    --cc=cw00.choi@samsung.com \
    --cc=devicetree@vger.kernel.org \
    --cc=hyunhee.kim@samsung.com \
    --cc=inki.dae@samsung.com \
    --cc=kgene.kim@samsung.com \
    --cc=kyungmin.park@samsung.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-samsung-soc@vger.kernel.org \
    --cc=marc.zyngier@arm.com \
    --cc=olof@lixom.net \
    --cc=sachin.kamat@linaro.org \
    --cc=sajjan.linux@gmail.com \
    --cc=sw0312.kim@samsung.com \
    --cc=t.figa@samsung.com \
    --cc=thomas.abraham@linaro.org \
    --cc=tomasz.figa@gmail.com \
    --cc=tushar.behera@linaro.org \
    --cc=yj44.cho@samsung.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.