aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorSebastian Ott <sebott@linux.vnet.ibm.com>2013-08-29 13:36:49 -0400
committerMartin Schwidefsky <schwidefsky@de.ibm.com>2013-08-30 02:57:15 -0400
commit77e844b9644026c11c5883144540155de39af767 (patch)
tree704f30cb7e9a30ade37e20c0f0bc9688f05ac0b0
parent0ff70ec88ba61f72b05b365a21fbd8aa60436254 (diff)
s390/hibernate: add early resume function
Some functions that do arch specific resume actions are called directly from swsusp_asm64.S . Before we add another function call provide a generic s390_early_resume function which can be used for this purpose. Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com> Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
-rw-r--r--arch/s390/include/asm/cio.h1
-rw-r--r--arch/s390/kernel/suspend.c9
-rw-r--r--arch/s390/kernel/swsusp_asm64.S7
-rw-r--r--drivers/s390/cio/css.h2
4 files changed, 12 insertions, 7 deletions
diff --git a/arch/s390/include/asm/cio.h b/arch/s390/include/asm/cio.h
index ffb898961c8d..d42625053c37 100644
--- a/arch/s390/include/asm/cio.h
+++ b/arch/s390/include/asm/cio.h
@@ -296,6 +296,7 @@ static inline int ccw_dev_id_is_equal(struct ccw_dev_id *dev_id1,
296 return 0; 296 return 0;
297} 297}
298 298
299void channel_subsystem_reinit(void);
299extern void css_schedule_reprobe(void); 300extern void css_schedule_reprobe(void);
300 301
301extern void reipl_ccw_dev(struct ccw_dev_id *id); 302extern void reipl_ccw_dev(struct ccw_dev_id *id);
diff --git a/arch/s390/kernel/suspend.c b/arch/s390/kernel/suspend.c
index c479d2f9605b..eebab9f83f1d 100644
--- a/arch/s390/kernel/suspend.c
+++ b/arch/s390/kernel/suspend.c
@@ -10,6 +10,8 @@
10#include <linux/suspend.h> 10#include <linux/suspend.h>
11#include <linux/mm.h> 11#include <linux/mm.h>
12#include <asm/ctl_reg.h> 12#include <asm/ctl_reg.h>
13#include <asm/ipl.h>
14#include <asm/cio.h>
13 15
14/* 16/*
15 * References to section boundaries 17 * References to section boundaries
@@ -211,3 +213,10 @@ void restore_processor_state(void)
211 __ctl_set_bit(0,28); 213 __ctl_set_bit(0,28);
212 local_mcck_enable(); 214 local_mcck_enable();
213} 215}
216
217/* Called at the end of swsusp_arch_resume */
218void s390_early_resume(void)
219{
220 lgr_info_log();
221 channel_subsystem_reinit();
222}
diff --git a/arch/s390/kernel/swsusp_asm64.S b/arch/s390/kernel/swsusp_asm64.S
index c487be4cfc81..6b09fdffbd2f 100644
--- a/arch/s390/kernel/swsusp_asm64.S
+++ b/arch/s390/kernel/swsusp_asm64.S
@@ -281,11 +281,8 @@ restore_registers:
281 lghi %r2,0 281 lghi %r2,0
282 brasl %r14,arch_set_page_states 282 brasl %r14,arch_set_page_states
283 283
284 /* Log potential guest relocation */ 284 /* Call arch specific early resume code */
285 brasl %r14,lgr_info_log 285 brasl %r14,s390_early_resume
286
287 /* Reinitialize the channel subsystem */
288 brasl %r14,channel_subsystem_reinit
289 286
290 /* Return 0 */ 287 /* Return 0 */
291 lmg %r6,%r15,STACK_FRAME_OVERHEAD + __SF_GPRS(%r15) 288 lmg %r6,%r15,STACK_FRAME_OVERHEAD + __SF_GPRS(%r15)
diff --git a/drivers/s390/cio/css.h b/drivers/s390/cio/css.h
index b1de60335238..29351321bad6 100644
--- a/drivers/s390/cio/css.h
+++ b/drivers/s390/cio/css.h
@@ -130,8 +130,6 @@ struct channel_subsystem {
130 130
131extern struct channel_subsystem *channel_subsystems[]; 131extern struct channel_subsystem *channel_subsystems[];
132 132
133void channel_subsystem_reinit(void);
134
135/* Helper functions to build lists for the slow path. */ 133/* Helper functions to build lists for the slow path. */
136void css_schedule_eval(struct subchannel_id schid); 134void css_schedule_eval(struct subchannel_id schid);
137void css_schedule_eval_all(void); 135void css_schedule_eval_all(void);