Skip to contentSkip to conversation

CPU hotplug fixes for ARM32

PATCH Superseded Oleksandr Tyshchenko 2 participants 6 messages Dec 4, 2018

v1 of 3 Superseded Latest is v3 →

lore
Share & tools
lore
#0 lore raw

cover CPU hotplug fixes for ARM32

From: Oleksandr Tyshchenko <[email protected]>

Hi, all.

This is small patch series for ARM32 which needed to be able to bring secondary CPUs up not only during the initial boot, but at runtime also. For example, during CPU hotplug.

Actually these are follow-up patches to the following series [1], which covers generic ARM and ARM64 parts.

[1] https://lists.xenproject.org/archives/html/xen-devel/2018-06/msg00039.html

Oleksandr Tyshchenko (2):
xen/link: Link proc_info_list in .data instead of .init.data xen/arm32: Remove __init prefixes from funcs that are used within CPU
up flow

 xen/arch/arm/arm32/smpboot.c |  2 +-
 xen/arch/arm/platform.c      |  2 +-
 xen/arch/arm/xen.lds.S       | 10 ++++++----
 3 files changed, 8 insertions(+), 6 deletions(-)
Signature · 7 lines
2.7.4


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
#1 lore raw

PATCH 1/2 xen/link: Link proc_info_list in .data instead of .init.data

From: Oleksandr Tyshchenko <[email protected]>

To be able to use it for the hot pluged CPUs as well.

---
 xen/arch/arm/xen.lds.S | 10 ++++++----
 1 file changed, 6 insertions(+), 4 deletions(-)
xen/arch/arm/xen.lds.S +6 -4
index 245a0e0..003301a 100644
@@ -88,6 +88,12 @@ SECTIONS
        . = ALIGN(PAGE_SIZE);
        *(.data.page_aligned)
        *(.data)
+
+       . = ALIGN(POINTER_ALIGN);
+       __proc_info_start = .;
+       *(.init.proc.info)
+       __proc_info_end = .;
+
        . = ALIGN(8);
        __start_schedulers_array = .;
        *(.data.schedulers)
@@ -151,10 +157,6 @@ SECTIONS
        *(.init.setup)
        __setup_end = .;
 
-       __proc_info_start = .;
-       *(.init.proc.info)
-       __proc_info_end = .;
-
        __initcall_start = .;
        *(.initcallpresmp.init)
        __presmp_initcall_end = .;
Signature · 7 lines
2.7.4


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
#2 lore raw

Re: [PATCH 1/2] xen/link: Link proc_info_list in .data instead of .init.data

Hi,

Title: xen/arm: link: ...

Quoted 3 lines · Oleksandr Tyshchenko

From: Oleksandr Tyshchenko <[email protected]>

To be able to use it for the hot pluged CPUs as well.

s/hot pluged/hot-plugged/

Quoted 11 lines
---
  xen/arch/arm/xen.lds.S | 10 ++++++----
  1 file changed, 6 insertions(+), 4 deletions(-)
xen/arch/arm/xen.lds.S +0 -0
index 245a0e0..003301a 100644

xen/arch/arm/xen.lds.S SECTIONS · line 94

Quoted 7 lines
xen/arch/arm/xen.lds.S +4 -0
@@ -88,6 +88,12 @@ SECTIONS
         . = ALIGN(PAGE_SIZE);
         *(.data.page_aligned)
         *(.data)
+
+       . = ALIGN(POINTER_ALIGN);
+       __proc_info_start = .;
+       *(.init.proc.info)

This is a bit odd to see .init.* section in .data. So I think we want to rename it.

Cheers,

Signature · 6 lines
Julien Grall

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
#3 lore raw

Re: [PATCH 1/2] xen/link: Link proc_info_list in .data instead of .init.data

Quoted 2 lines · Julien Grall

Hi,

Hi, Julien

Quoted 3 lines

Title: xen/arm: link: ...

ok

Quoted 8 lines · Oleksandr Tyshchenko
Quoted 3 lines

From: Oleksandr Tyshchenko <[email protected]>

To be able to use it for the hot pluged CPUs as well.

s/hot pluged/hot-plugged/

ok

Quoted 7 lines
Quoted 7 lines
---
  xen/arch/arm/xen.lds.S | 10 ++++++----
  1 file changed, 6 insertions(+), 4 deletions(-)
Quoted 16 lines

xen/arch/arm/xen.lds.S SECTIONS · line 94

Quoted 12 lines
xen/arch/arm/xen.lds.S +4 -0
index 245a0e0..003301a 100644
@@ -88,6 +88,12 @@ SECTIONS
         . = ALIGN(PAGE_SIZE);
         *(.data.page_aligned)
         *(.data)
+
+       . = ALIGN(POINTER_ALIGN);
+       __proc_info_start = .;
+       *(.init.proc.info)

This is a bit odd to see .init.* section in .data. So I think we want to rename it.

indeed, will rename

Quoted 6 lines

Cheers,

--
Julien Grall

Signature · 3 lines
Regards,

Oleksandr Tyshchenko

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel

#4 lore raw

PATCH 2/2 xen/arm32: Remove __init prefixes from funcs that are used within CPU up flow

In reply to Oleksandr Tyshchenko

From: Oleksandr Tyshchenko <[email protected]>

This is a follow-up patch to
commit 01a7e8ccef6e7d5718a251ad587567afbe723330 xen/arm: Remove __initdata and __init to enable CPU hotplug

---
 xen/arch/arm/arm32/smpboot.c | 2 +-
 xen/arch/arm/platform.c      | 2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)
xen/arch/arm/arm32/smpboot.c +1 -1
index 2a77f29..e736866 100644
@@ -16,7 +16,7 @@ int __init arch_cpu_init(int cpu, struct dt_device_node *dn)
     return 0;
 }
 
-int __init arch_cpu_up(int cpu)
+int arch_cpu_up(int cpu)
 {
     return platform_cpu_up(cpu);
 }
xen/arch/arm/platform.c +1 -1
index 6989e58..0ba2001 100644
@@ -95,7 +95,7 @@ int __init platform_specific_mapping(struct domain *d)
 }
 
 #ifdef CONFIG_ARM_32
-int __init platform_cpu_up(int cpu)
+int platform_cpu_up(int cpu)
 {
     if ( psci_ver )
         return call_psci_cpu_on(cpu);
Signature · 7 lines
2.7.4


_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel
Acked-by on v1 2/2
#5 lore raw

Re: [PATCH 2/2] xen/arm32: Remove __init prefixes from funcs that are used within CPU up flow

Hi Oleksandr,

Quoted 7 lines · Oleksandr Tyshchenko

From: Oleksandr Tyshchenko <[email protected]>

This is a follow-up patch to
commit 01a7e8ccef6e7d5718a251ad587567afbe723330 xen/arm: Remove __initdata and __init to enable CPU hotplug

Cheers,

Quoted 32 lines
---
  xen/arch/arm/arm32/smpboot.c | 2 +-
  xen/arch/arm/platform.c      | 2 +-
  2 files changed, 2 insertions(+), 2 deletions(-)
xen/arch/arm/arm32/smpboot.c +1 -1
index 2a77f29..e736866 100644
@@ -16,7 +16,7 @@ int __init arch_cpu_init(int cpu, struct dt_device_node *dn)
      return 0;
  }
 
-int __init arch_cpu_up(int cpu)
+int arch_cpu_up(int cpu)
  {
      return platform_cpu_up(cpu);
  }
xen/arch/arm/platform.c +1 -1
index 6989e58..0ba2001 100644
@@ -95,7 +95,7 @@ int __init platform_specific_mapping(struct domain *d)
  }
 
  #ifdef CONFIG_ARM_32
-int __init platform_cpu_up(int cpu)
+int platform_cpu_up(int cpu)
  {
      if ( psci_ver )
          return call_psci_cpu_on(cpu);
Signature · 6 lines
Julien Grall

_______________________________________________
Xen-devel mailing list
[email protected]
https://lists.xenproject.org/mailman/listinfo/xen-devel