Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 187796
b: refs/heads/master
c: 8dbce53
h: refs/heads/master
v: v3
  • Loading branch information
Vaidyanathan Srinivasan authored and Benjamin Herrenschmidt committed Mar 9, 2010
1 parent d37f3bc commit df6f2b5
Show file tree
Hide file tree
Showing 4 changed files with 17 additions and 6 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: de0b632ba05bc88949e67d33d1c313fcf922ae2e
refs/heads/master: 8dbce53cc249a76e9450708d291fce5a7e29c6a1
11 changes: 11 additions & 0 deletions trunk/arch/powerpc/kernel/head_64.S
Original file line number Diff line number Diff line change
Expand Up @@ -617,6 +617,17 @@ _GLOBAL(start_secondary_prolog)
std r3,0(r1) /* Zero the stack frame pointer */
bl .start_secondary
b .
/*
* Reset stack pointer and call start_secondary
* to continue with online operation when woken up
* from cede in cpu offline.
*/
_GLOBAL(start_secondary_resume)
ld r1,PACAKSAVE(r13) /* Reload kernel stack pointer */
li r3,0
std r3,0(r1) /* Zero the stack frame pointer */
bl .start_secondary
b .
#endif

/*
Expand Down
9 changes: 4 additions & 5 deletions trunk/arch/powerpc/platforms/pseries/hotplug-cpu.c
Original file line number Diff line number Diff line change
Expand Up @@ -146,12 +146,11 @@ static void pseries_mach_cpu_die(void)
unregister_slb_shadow(hwcpu, __pa(get_slb_shadow()));

/*
* NOTE: Calling start_secondary() here for now to
* start new context.
* However, need to do it cleanly by resetting the
* stack pointer.
* Call to start_secondary_resume() will not return.
* Kernel stack will be reset and start_secondary()
* will be called to continue the online operation.
*/
start_secondary();
start_secondary_resume();

} else if (get_preferred_offline_state(cpu) == CPU_STATE_OFFLINE) {

Expand Down
1 change: 1 addition & 0 deletions trunk/arch/powerpc/platforms/pseries/offline_states.h
Original file line number Diff line number Diff line change
Expand Up @@ -35,4 +35,5 @@ static inline void set_default_offline_state(int cpu)

extern enum cpu_state_vals get_preferred_offline_state(int cpu);
extern int start_secondary(void);
extern void start_secondary_resume(void);
#endif

0 comments on commit df6f2b5

Please sign in to comment.