All of lore.kernel.org
 help / color / mirror / Atom feed
From: robherring2@gmail.com (Rob Herring)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH v9 09/13] ARM: SoC: convert highbank to SoC descriptor
Date: Wed, 12 Sep 2012 10:23:37 -0500	[thread overview]
Message-ID: <5050A8F9.1060503@gmail.com> (raw)
In-Reply-To: <1347461906-13527-10-git-send-email-arnd@arndb.de>

On 09/12/2012 09:58 AM, Arnd Bergmann wrote:
> From: Marc Zyngier <marc.zyngier@arm.com>
> 
> Convert the highbank platform to use the SoC descriptor to provide
> its SMP and CPU hotplug operations.
> 
> Cc: Rob Herring <rob.herring@calxeda.com>
> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---

Thanks for picking this up.

Acked-by: Rob Herring <rob.herring@calxeda.com>

Rob

>  arch/arm/mach-highbank/core.h     |    3 +++
>  arch/arm/mach-highbank/highbank.c |    1 +
>  arch/arm/mach-highbank/hotplug.c  |   16 +---------------
>  arch/arm/mach-highbank/platsmp.c  |   18 ++++++++++++++----
>  4 files changed, 19 insertions(+), 19 deletions(-)
> 
> diff --git a/arch/arm/mach-highbank/core.h b/arch/arm/mach-highbank/core.h
> index 141ed51..598ee78 100644
> --- a/arch/arm/mach-highbank/core.h
> +++ b/arch/arm/mach-highbank/core.h
> @@ -9,3 +9,6 @@ static inline void highbank_lluart_map_io(void) {}
>  #endif
>  
>  extern void highbank_smc1(int fn, int arg);
> +extern void highbank_cpu_die(unsigned int cpu);
> +
> +extern struct smp_operations highbank_smp_ops;
> diff --git a/arch/arm/mach-highbank/highbank.c b/arch/arm/mach-highbank/highbank.c
> index d75b0a7..709bd72 100644
> --- a/arch/arm/mach-highbank/highbank.c
> +++ b/arch/arm/mach-highbank/highbank.c
> @@ -162,6 +162,7 @@ static const char *highbank_match[] __initconst = {
>  };
>  
>  DT_MACHINE_START(HIGHBANK, "Highbank")
> +	.smp		= smp_ops(highbank_smp_ops),
>  	.map_io		= highbank_map_io,
>  	.init_irq	= highbank_init_irq,
>  	.timer		= &highbank_timer,
> diff --git a/arch/arm/mach-highbank/hotplug.c b/arch/arm/mach-highbank/hotplug.c
> index 977cebb..1277da3 100644
> --- a/arch/arm/mach-highbank/hotplug.c
> +++ b/arch/arm/mach-highbank/hotplug.c
> @@ -24,16 +24,11 @@
>  
>  extern void secondary_startup(void);
>  
> -int platform_cpu_kill(unsigned int cpu)
> -{
> -	return 1;
> -}
> -
>  /*
>   * platform-specific code to shutdown a CPU
>   *
>   */
> -void platform_cpu_die(unsigned int cpu)
> +void highbank_cpu_die(unsigned int cpu)
>  {
>  	flush_cache_all();
>  
> @@ -45,12 +40,3 @@ void platform_cpu_die(unsigned int cpu)
>  	/* We should never return from idle */
>  	panic("highbank: cpu %d unexpectedly exit from shutdown\n", cpu);
>  }
> -
> -int platform_cpu_disable(unsigned int cpu)
> -{
> -	/*
> -	 * CPU0 should not be shut down via hotplug.  cpu_idle can WFI
> -	 * or a proper shutdown or hibernate should be used.
> -	 */
> -	return cpu == 0 ? -EPERM : 0;
> -}
> diff --git a/arch/arm/mach-highbank/platsmp.c b/arch/arm/mach-highbank/platsmp.c
> index d01364c..fa9560e 100644
> --- a/arch/arm/mach-highbank/platsmp.c
> +++ b/arch/arm/mach-highbank/platsmp.c
> @@ -25,12 +25,12 @@
>  
>  extern void secondary_startup(void);
>  
> -void __cpuinit platform_secondary_init(unsigned int cpu)
> +static void __cpuinit highbank_secondary_init(unsigned int cpu)
>  {
>  	gic_secondary_init(0);
>  }
>  
> -int __cpuinit boot_secondary(unsigned int cpu, struct task_struct *idle)
> +static int __cpuinit highbank_boot_secondary(unsigned int cpu, struct task_struct *idle)
>  {
>  	gic_raise_softirq(cpumask_of(cpu), 0);
>  	return 0;
> @@ -40,7 +40,7 @@ int __cpuinit boot_secondary(unsigned int cpu, struct task_struct *idle)
>   * Initialise the CPU possible map early - this describes the CPUs
>   * which may be present or become present in the system.
>   */
> -void __init smp_init_cpus(void)
> +static void __init highbank_smp_init_cpus(void)
>  {
>  	unsigned int i, ncores;
>  
> @@ -61,7 +61,7 @@ void __init smp_init_cpus(void)
>  	set_smp_cross_call(gic_raise_softirq);
>  }
>  
> -void __init platform_smp_prepare_cpus(unsigned int max_cpus)
> +static void __init highbank_smp_prepare_cpus(unsigned int max_cpus)
>  {
>  	int i;
>  
> @@ -76,3 +76,13 @@ void __init platform_smp_prepare_cpus(unsigned int max_cpus)
>  	for (i = 1; i < max_cpus; i++)
>  		highbank_set_cpu_jump(i, secondary_startup);
>  }
> +
> +struct smp_operations highbank_smp_ops __initdata = {
> +	.smp_init_cpus		= highbank_smp_init_cpus,
> +	.smp_prepare_cpus	= highbank_smp_prepare_cpus,
> +	.smp_secondary_init	= highbank_secondary_init,
> +	.smp_boot_secondary	= highbank_boot_secondary,
> +#ifdef CONFIG_HOTPLUG_CPU
> +	.cpu_die		= highbank_cpu_die,
> +#endif
> +};
> 

WARNING: multiple messages have this Message-ID (diff)
From: Rob Herring <robherring2@gmail.com>
To: Arnd Bergmann <arnd@arndb.de>
Cc: Marc Zyngier <marc.zyngier@arm.com>,
	linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org
Subject: Re: [PATCH v9 09/13] ARM: SoC: convert highbank to SoC descriptor
Date: Wed, 12 Sep 2012 10:23:37 -0500	[thread overview]
Message-ID: <5050A8F9.1060503@gmail.com> (raw)
In-Reply-To: <1347461906-13527-10-git-send-email-arnd@arndb.de>

On 09/12/2012 09:58 AM, Arnd Bergmann wrote:
> From: Marc Zyngier <marc.zyngier@arm.com>
> 
> Convert the highbank platform to use the SoC descriptor to provide
> its SMP and CPU hotplug operations.
> 
> Cc: Rob Herring <rob.herring@calxeda.com>
> Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
> Signed-off-by: Arnd Bergmann <arnd@arndb.de>
> ---

Thanks for picking this up.

Acked-by: Rob Herring <rob.herring@calxeda.com>

Rob

>  arch/arm/mach-highbank/core.h     |    3 +++
>  arch/arm/mach-highbank/highbank.c |    1 +
>  arch/arm/mach-highbank/hotplug.c  |   16 +---------------
>  arch/arm/mach-highbank/platsmp.c  |   18 ++++++++++++++----
>  4 files changed, 19 insertions(+), 19 deletions(-)
> 
> diff --git a/arch/arm/mach-highbank/core.h b/arch/arm/mach-highbank/core.h
> index 141ed51..598ee78 100644
> --- a/arch/arm/mach-highbank/core.h
> +++ b/arch/arm/mach-highbank/core.h
> @@ -9,3 +9,6 @@ static inline void highbank_lluart_map_io(void) {}
>  #endif
>  
>  extern void highbank_smc1(int fn, int arg);
> +extern void highbank_cpu_die(unsigned int cpu);
> +
> +extern struct smp_operations highbank_smp_ops;
> diff --git a/arch/arm/mach-highbank/highbank.c b/arch/arm/mach-highbank/highbank.c
> index d75b0a7..709bd72 100644
> --- a/arch/arm/mach-highbank/highbank.c
> +++ b/arch/arm/mach-highbank/highbank.c
> @@ -162,6 +162,7 @@ static const char *highbank_match[] __initconst = {
>  };
>  
>  DT_MACHINE_START(HIGHBANK, "Highbank")
> +	.smp		= smp_ops(highbank_smp_ops),
>  	.map_io		= highbank_map_io,
>  	.init_irq	= highbank_init_irq,
>  	.timer		= &highbank_timer,
> diff --git a/arch/arm/mach-highbank/hotplug.c b/arch/arm/mach-highbank/hotplug.c
> index 977cebb..1277da3 100644
> --- a/arch/arm/mach-highbank/hotplug.c
> +++ b/arch/arm/mach-highbank/hotplug.c
> @@ -24,16 +24,11 @@
>  
>  extern void secondary_startup(void);
>  
> -int platform_cpu_kill(unsigned int cpu)
> -{
> -	return 1;
> -}
> -
>  /*
>   * platform-specific code to shutdown a CPU
>   *
>   */
> -void platform_cpu_die(unsigned int cpu)
> +void highbank_cpu_die(unsigned int cpu)
>  {
>  	flush_cache_all();
>  
> @@ -45,12 +40,3 @@ void platform_cpu_die(unsigned int cpu)
>  	/* We should never return from idle */
>  	panic("highbank: cpu %d unexpectedly exit from shutdown\n", cpu);
>  }
> -
> -int platform_cpu_disable(unsigned int cpu)
> -{
> -	/*
> -	 * CPU0 should not be shut down via hotplug.  cpu_idle can WFI
> -	 * or a proper shutdown or hibernate should be used.
> -	 */
> -	return cpu == 0 ? -EPERM : 0;
> -}
> diff --git a/arch/arm/mach-highbank/platsmp.c b/arch/arm/mach-highbank/platsmp.c
> index d01364c..fa9560e 100644
> --- a/arch/arm/mach-highbank/platsmp.c
> +++ b/arch/arm/mach-highbank/platsmp.c
> @@ -25,12 +25,12 @@
>  
>  extern void secondary_startup(void);
>  
> -void __cpuinit platform_secondary_init(unsigned int cpu)
> +static void __cpuinit highbank_secondary_init(unsigned int cpu)
>  {
>  	gic_secondary_init(0);
>  }
>  
> -int __cpuinit boot_secondary(unsigned int cpu, struct task_struct *idle)
> +static int __cpuinit highbank_boot_secondary(unsigned int cpu, struct task_struct *idle)
>  {
>  	gic_raise_softirq(cpumask_of(cpu), 0);
>  	return 0;
> @@ -40,7 +40,7 @@ int __cpuinit boot_secondary(unsigned int cpu, struct task_struct *idle)
>   * Initialise the CPU possible map early - this describes the CPUs
>   * which may be present or become present in the system.
>   */
> -void __init smp_init_cpus(void)
> +static void __init highbank_smp_init_cpus(void)
>  {
>  	unsigned int i, ncores;
>  
> @@ -61,7 +61,7 @@ void __init smp_init_cpus(void)
>  	set_smp_cross_call(gic_raise_softirq);
>  }
>  
> -void __init platform_smp_prepare_cpus(unsigned int max_cpus)
> +static void __init highbank_smp_prepare_cpus(unsigned int max_cpus)
>  {
>  	int i;
>  
> @@ -76,3 +76,13 @@ void __init platform_smp_prepare_cpus(unsigned int max_cpus)
>  	for (i = 1; i < max_cpus; i++)
>  		highbank_set_cpu_jump(i, secondary_startup);
>  }
> +
> +struct smp_operations highbank_smp_ops __initdata = {
> +	.smp_init_cpus		= highbank_smp_init_cpus,
> +	.smp_prepare_cpus	= highbank_smp_prepare_cpus,
> +	.smp_secondary_init	= highbank_secondary_init,
> +	.smp_boot_secondary	= highbank_boot_secondary,
> +#ifdef CONFIG_HOTPLUG_CPU
> +	.cpu_die		= highbank_cpu_die,
> +#endif
> +};
> 


  reply	other threads:[~2012-09-12 15:23 UTC|newest]

Thread overview: 62+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-09-12 14:58 [PATCH v9 00/13] Per sub-architecture SMP operations Arnd Bergmann
2012-09-12 14:58 ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 01/13] ARM: SoC: add per-platform " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 02/13] ARM: SoC: convert VExpress/RealView to SoC descriptor Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 03/13] ARM: SoC: convert OMAP4 " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 04/13] ARM: SoC: convert Tegra " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 05/13] ARM: SoC: convert Exynos4 " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-13  5:10   ` Kyungmin Park
2012-09-13  5:10     ` Kyungmin Park
2012-09-14  4:33   ` Kukjin Kim
2012-09-14  4:33     ` Kukjin Kim
2012-09-12 14:58 ` [PATCH v9 06/13] ARM: SoC: convert MSM SMP " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 16:26   ` David Brown
2012-09-12 16:26     ` David Brown
2012-09-12 20:32     ` Stephen Boyd
2012-09-12 20:32       ` Stephen Boyd
2012-09-12 23:01   ` [PATCH 1/2] " David Brown
2012-09-12 23:01     ` David Brown
2012-09-12 23:01     ` [PATCH 2/2] ARM: msm: Move core.h contents into common.h David Brown
2012-09-12 23:01       ` David Brown
2012-09-13  8:47     ` [PATCH 1/2] ARM: SoC: convert MSM SMP to SoC descriptor Arnd Bergmann
2012-09-13  8:47       ` Arnd Bergmann
2012-09-13 16:15       ` David Brown
2012-09-13 16:15         ` David Brown
2012-09-14  7:57         ` Arnd Bergmann
2012-09-14  7:57           ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 07/13] ARM: SoC: convert ux500 " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
     [not found]   ` <CAE2-_9o5gEpEddGLvRRA=pe=vroTnBXmGmoBO1Ojos-hOJXQAQ@mail.gmail.com>
2012-09-12 16:30     ` Fwd: " Srinidhi Kasagar
2012-09-12 16:30       ` Srinidhi Kasagar
2012-09-12 14:58 ` [PATCH v9 08/13] ARM: SoC: convert shmobile SMP " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 09/13] ARM: SoC: convert highbank " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 15:23   ` Rob Herring [this message]
2012-09-12 15:23     ` Rob Herring
2012-09-12 14:58 ` [PATCH v9 10/13] ARM: SoC: convert imx6q " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-13  1:17   ` Shawn Guo
2012-09-13  1:17     ` Shawn Guo
2012-09-13  8:44     ` Arnd Bergmann
2012-09-13  8:44       ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 11/13] ARM: SoC: convert spear13xx " Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-13 11:18   ` viresh kumar
2012-09-13 11:18     ` viresh kumar
2012-09-12 14:58 ` [PATCH v9 12/13] ARM: smp: Make SoC descriptor mandatory for SMP platforms Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 14:58 ` [PATCH v9 13/13] ARM: consolidate pen_release instead of having per platform definitions Arnd Bergmann
2012-09-12 14:58   ` Arnd Bergmann
2012-09-12 19:54   ` Nicolas Pitre
2012-09-12 19:54     ` Nicolas Pitre
2012-09-12 20:42 ` [PATCH v9 00/13] Per sub-architecture SMP operations Nicolas Pitre
2012-09-12 20:42   ` Nicolas Pitre
2012-09-13 11:11 ` Marc Zyngier
2012-09-13 11:11   ` Marc Zyngier

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=5050A8F9.1060503@gmail.com \
    --to=robherring2@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 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.