diff options
Diffstat (limited to 'arch/arm/mach-omap2/pm34xx.c')
| -rw-r--r-- | arch/arm/mach-omap2/pm34xx.c | 13 | 
1 files changed, 4 insertions, 9 deletions
diff --git a/arch/arm/mach-omap2/pm34xx.c b/arch/arm/mach-omap2/pm34xx.c index 841ba19d64a6..36c55547137c 100644 --- a/arch/arm/mach-omap2/pm34xx.c +++ b/arch/arm/mach-omap2/pm34xx.c @@ -48,6 +48,7 @@  #include "prm3xxx.h"  #include "pm.h"  #include "sdrc.h" +#include "omap-secure.h"  #include "sram.h"  #include "control.h"  #include "vc.h" @@ -66,7 +67,6 @@ struct power_state {  static LIST_HEAD(pwrst_list); -static int (*_omap_save_secure_sram)(u32 *addr);  void (*omap3_do_wfi_sram)(void);  static struct powerdomain *mpu_pwrdm, *neon_pwrdm; @@ -121,8 +121,8 @@ static void omap3_save_secure_ram_context(void)  		 * will hang the system.  		 */  		pwrdm_set_next_pwrst(mpu_pwrdm, PWRDM_POWER_ON); -		ret = _omap_save_secure_sram((u32 *)(unsigned long) -				__pa(omap3_secure_ram_storage)); +		ret = omap3_save_secure_ram(omap3_secure_ram_storage, +					    OMAP3_SAVE_SECURE_RAM_SZ);  		pwrdm_set_next_pwrst(mpu_pwrdm, mpu_next_state);  		/* Following is for error tracking, it should not happen */  		if (ret) { @@ -434,15 +434,10 @@ static int __init pwrdms_setup(struct powerdomain *pwrdm, void *unused)   *   * The minimum set of functions is pushed to SRAM for execution:   * - omap3_do_wfi for erratum i581 WA, - * - save_secure_ram_context for security extensions.   */  void omap_push_sram_idle(void)  {  	omap3_do_wfi_sram = omap_sram_push(omap3_do_wfi, omap3_do_wfi_sz); - -	if (omap_type() != OMAP2_DEVICE_TYPE_GP) -		_omap_save_secure_sram = omap_sram_push(save_secure_ram_context, -				save_secure_ram_context_sz);  }  static void __init pm_errata_configure(void) @@ -553,7 +548,7 @@ int __init omap3_pm_init(void)  	clkdm_add_wkdep(neon_clkdm, mpu_clkdm);  	if (omap_type() != OMAP2_DEVICE_TYPE_GP) {  		omap3_secure_ram_storage = -			kmalloc(0x803F, GFP_KERNEL); +			kmalloc(OMAP3_SAVE_SECURE_RAM_SZ, GFP_KERNEL);  		if (!omap3_secure_ram_storage)  			pr_err("Memory allocation failed when allocating for secure sram context\n");  | 

