Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

powerpc/pseries/hibernation: remove prepare_late() callback

The pseries hibernate code no longer calls into the original
join/suspend code in kernel/rtas.c, so pseries_prepare_late() and
related code don't accomplish anything now.

Signed-off-by: Nathan Lynch <nathanl@linux.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
Link: https://lore.kernel.org/r/20201207215200.1785968-27-nathanl@linux.ibm.com

authored by

Nathan Lynch and committed by
Michael Ellerman
d102f831 fa53bcdb

-25
-25
arch/powerpc/platforms/pseries/suspend.c
··· 15 15 #include <asm/topology.h> 16 16 17 17 static struct device suspend_dev; 18 - static DECLARE_COMPLETION(suspend_work); 19 - static struct rtas_suspend_me_data suspend_data; 20 - static atomic_t suspending; 21 18 22 19 /** 23 20 * pseries_suspend_begin - First phase of hibernation ··· 56 59 static int pseries_suspend_enter(suspend_state_t state) 57 60 { 58 61 return rtas_ibm_suspend_me(NULL); 59 - } 60 - 61 - /** 62 - * pseries_prepare_late - Prepare to suspend all other CPUs 63 - * 64 - * Return value: 65 - * 0 on success / other on failure 66 - **/ 67 - static int pseries_prepare_late(void) 68 - { 69 - atomic_set(&suspending, 1); 70 - atomic_set(&suspend_data.working, 0); 71 - atomic_set(&suspend_data.done, 0); 72 - atomic_set(&suspend_data.error, 0); 73 - suspend_data.complete = &suspend_work; 74 - reinit_completion(&suspend_work); 75 - return 0; 76 62 } 77 63 78 64 /** ··· 132 152 133 153 static const struct platform_suspend_ops pseries_suspend_ops = { 134 154 .valid = suspend_valid_only_mem, 135 - .prepare_late = pseries_prepare_late, 136 155 .enter = pseries_suspend_enter, 137 156 }; 138 157 ··· 172 193 int rc; 173 194 174 195 if (!firmware_has_feature(FW_FEATURE_LPAR)) 175 - return 0; 176 - 177 - suspend_data.token = rtas_token("ibm,suspend-me"); 178 - if (suspend_data.token == RTAS_UNKNOWN_SERVICE) 179 196 return 0; 180 197 181 198 if ((rc = pseries_suspend_sysfs_register(&suspend_dev)))