History

parisc: add __pdc_cpu_rendezvous()

When stopping SMP cpus send them into rendezvous, so we can start them again later (when kexec'ing a new kernel).

Sven Schnelle committed 7 years ago

Commit 507efd61 parent 08e69783 files · +15 −0Browse files

Unified · Split

3 files
  1. arch/parisc/include/asm/pdc.h +1 −0
  2. arch/parisc/kernel/firmware.c +13 −0
  3. arch/parisc/kernel/smp.c +1 −0
arch/parisc/include/asm/pdc.h+1−0
@@ -91,6 +91,7 @@ int pdc_sti_call(unsigned long func, unsigned long flags, · 90 unmodified lines
91 unsigned long inptr, unsigned long outputr,91 unsigned long inptr, unsigned long outputr,
92 unsigned long glob_cfg);92 unsigned long glob_cfg);
93 93
94int __pdc_cpu_rendezvous(void);
94static inline char * os_id_to_string(u16 os_id) {95static inline char * os_id_to_string(u16 os_id) {
95 switch(os_id) {96 switch(os_id) {
96 case OS_ID_NONE: return "No OS";97 case OS_ID_NONE: return "No OS";
arch/parisc/kernel/firmware.c+13−0
@@ -311,6 +311,19 @@ int pdc_chassis_disp(unsigned long disp) · 310 unmodified lines
311 return retval;311 return retval;
312}312}
313 313
314/**
315 * pdc_cpu_rendenzvous - Stop currently executing CPU
316 * @retval: -1 on error, 0 on success
317 */
318int __pdc_cpu_rendezvous(void)
319{
320 if (is_pdc_pat())
321 return mem_pdc_call(PDC_PAT_CPU, PDC_PAT_CPU_RENDEZVOUS);
322 else
323 return mem_pdc_call(PDC_PROC, 1, 0);
324}
325
326
314/**327/**
315 * pdc_chassis_warn - Fetches chassis warnings328 * pdc_chassis_warn - Fetches chassis warnings
316 * @retval: -1 on error, 0 on success329 * @retval: -1 on error, 0 on success
arch/parisc/kernel/smp.c+1−0
@@ -109,6 +109,7 @@ halt_processor(void) · 108 unmodified lines
109 /* REVISIT : does PM *know* this CPU isn't available? */109 /* REVISIT : does PM *know* this CPU isn't available? */
110 set_cpu_online(smp_processor_id(), false);110 set_cpu_online(smp_processor_id(), false);
111 local_irq_disable();111 local_irq_disable();
112 __pdc_cpu_rendezvous();
112 for (;;)113 for (;;)
113 ;114 ;
114}115}

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t