forked from mirrors/linux
		
	 2874c5fd28
			
		
	
	
		2874c5fd28
		
	
	
	
	
		
			
			Based on 1 normalized pattern(s): this program is free software you can redistribute it and or modify it under the terms of the gnu general public license as published by the free software foundation either version 2 of the license or at your option any later version extracted by the scancode license scanner the SPDX license identifier GPL-2.0-or-later has been chosen to replace the boilerplate/reference in 3029 file(s). Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Reviewed-by: Allison Randal <allison@lohutok.net> Cc: linux-spdx@vger.kernel.org Link: https://lkml.kernel.org/r/20190527070032.746973796@linutronix.de Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
		
			
				
	
	
		
			47 lines
		
	
	
	
		
			1.2 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			47 lines
		
	
	
	
		
			1.2 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
| /* SPDX-License-Identifier: GPL-2.0-or-later */
 | |
| /*
 | |
|  * Support Power Management
 | |
|  *
 | |
|  * Copyright 2014-2015 Freescale Semiconductor Inc.
 | |
|  */
 | |
| #ifndef __PPC_FSL_PM_H
 | |
| #define __PPC_FSL_PM_H
 | |
| 
 | |
| #define E500_PM_PH10	1
 | |
| #define E500_PM_PH15	2
 | |
| #define E500_PM_PH20	3
 | |
| #define E500_PM_PH30	4
 | |
| #define E500_PM_DOZE	E500_PM_PH10
 | |
| #define E500_PM_NAP	E500_PM_PH15
 | |
| 
 | |
| #define PLAT_PM_SLEEP	20
 | |
| #define PLAT_PM_LPM20	30
 | |
| 
 | |
| #define FSL_PM_SLEEP		(1 << 0)
 | |
| #define FSL_PM_DEEP_SLEEP	(1 << 1)
 | |
| 
 | |
| struct fsl_pm_ops {
 | |
| 	/* mask pending interrupts to the RCPM from MPIC */
 | |
| 	void (*irq_mask)(int cpu);
 | |
| 
 | |
| 	/* unmask pending interrupts to the RCPM from MPIC */
 | |
| 	void (*irq_unmask)(int cpu);
 | |
| 	void (*cpu_enter_state)(int cpu, int state);
 | |
| 	void (*cpu_exit_state)(int cpu, int state);
 | |
| 	void (*cpu_up_prepare)(int cpu);
 | |
| 	void (*cpu_die)(int cpu);
 | |
| 	int (*plat_enter_sleep)(void);
 | |
| 	void (*freeze_time_base)(bool freeze);
 | |
| 
 | |
| 	/* keep the power of IP blocks during sleep/deep sleep */
 | |
| 	void (*set_ip_power)(bool enable, u32 mask);
 | |
| 
 | |
| 	/* get platform supported power management modes */
 | |
| 	unsigned int (*get_pm_modes)(void);
 | |
| };
 | |
| 
 | |
| extern const struct fsl_pm_ops *qoriq_pm_ops;
 | |
| 
 | |
| int __init fsl_rcpm_init(void);
 | |
| 
 | |
| #endif /* __PPC_FSL_PM_H */
 |