diff options
| author | Ingo Molnar <mingo@elte.hu> | 2009-06-07 12:22:15 +0200 |
|---|---|---|
| committer | Ingo Molnar <mingo@elte.hu> | 2009-06-07 12:22:15 +0200 |
| commit | 5f4457a4f62cc9d78e04c0eb12ff0540899aad89 (patch) | |
| tree | 0b973d527ea6b2ae31e08da0746b4965a3c5a6d8 /arch/s390/kernel/early.c | |
| parent | 9b94b3a19b13e094c10f65f24bc358f6ffe4eacd (diff) | |
| parent | b87297fb405ef13cac375f202d114323b076a56d (diff) | |
Merge branch 'linus' into x86/cpu
Diffstat (limited to 'arch/s390/kernel/early.c')
| -rw-r--r-- | arch/s390/kernel/early.c | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/arch/s390/kernel/early.c b/arch/s390/kernel/early.c index 4d221c81c849..cf09948faad6 100644 --- a/arch/s390/kernel/early.c +++ b/arch/s390/kernel/early.c @@ -34,8 +34,25 @@ char kernel_nss_name[NSS_NAME_SIZE + 1]; +static unsigned long machine_flags; + static void __init setup_boot_command_line(void); +/* + * Get the TOD clock running. + */ +static void __init reset_tod_clock(void) +{ + u64 time; + + if (store_clock(&time) == 0) + return; + /* TOD clock not running. Set the clock to Unix Epoch. */ + if (set_clock(TOD_UNIX_EPOCH) != 0 || store_clock(&time) != 0) + disabled_wait(0); + + sched_clock_base_cc = TOD_UNIX_EPOCH; +} #ifdef CONFIG_SHARED_KERNEL int __init savesys_ipl_nss(char *cmd, const int cmdlen); @@ -370,6 +387,7 @@ static void __init setup_boot_command_line(void) */ void __init startup_init(void) { + reset_tod_clock(); ipl_save_parameters(); rescue_initrd(); clear_bss_section(); @@ -391,5 +409,6 @@ void __init startup_init(void) setup_hpage(); sclp_facilities_detect(); detect_memory_layout(memory_chunk); + S390_lowcore.machine_flags = machine_flags; lockdep_on(); } |
