xref: /openbmc/linux/arch/arm/mach-dove/pm.h (revision 4f2c0a4acffbec01079c28f839422e64ddeff004)
1*0fdebc5eSThomas Gleixner /* SPDX-License-Identifier: GPL-2.0-only */
2ce78179eSArnd Bergmann 
3ce78179eSArnd Bergmann #ifndef __ASM_ARCH_PM_H
4ce78179eSArnd Bergmann #define __ASM_ARCH_PM_H
5ce78179eSArnd Bergmann 
6ce78179eSArnd Bergmann #include <asm/errno.h>
7ce78179eSArnd Bergmann #include "irqs.h"
8ce78179eSArnd Bergmann 
9ce78179eSArnd Bergmann #define CLOCK_GATING_CONTROL	(DOVE_PMU_VIRT_BASE + 0x38)
10ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_USB0		0
11ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_USB1		1
12ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_GBE		2
13ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_SATA		3
14ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_PCIE0		4
15ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_PCIE1		5
16ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_SDIO0		8
17ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_SDIO1		9
18ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_NAND		10
19ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_CAMERA	11
20ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_I2S0		12
21ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_I2S1		13
22ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_CRYPTO	15
23ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_AC97		21
24ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_PDMA		22
25ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_XOR0		23
26ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_XOR1		24
27ce78179eSArnd Bergmann #define  CLOCK_GATING_BIT_GIGA_PHY	30
28ce78179eSArnd Bergmann #define  CLOCK_GATING_USB0_MASK		(1 << CLOCK_GATING_BIT_USB0)
29ce78179eSArnd Bergmann #define  CLOCK_GATING_USB1_MASK		(1 << CLOCK_GATING_BIT_USB1)
30ce78179eSArnd Bergmann #define  CLOCK_GATING_GBE_MASK		(1 << CLOCK_GATING_BIT_GBE)
31ce78179eSArnd Bergmann #define  CLOCK_GATING_SATA_MASK		(1 << CLOCK_GATING_BIT_SATA)
32ce78179eSArnd Bergmann #define  CLOCK_GATING_PCIE0_MASK	(1 << CLOCK_GATING_BIT_PCIE0)
33ce78179eSArnd Bergmann #define  CLOCK_GATING_PCIE1_MASK	(1 << CLOCK_GATING_BIT_PCIE1)
34ce78179eSArnd Bergmann #define  CLOCK_GATING_SDIO0_MASK	(1 << CLOCK_GATING_BIT_SDIO0)
35ce78179eSArnd Bergmann #define  CLOCK_GATING_SDIO1_MASK	(1 << CLOCK_GATING_BIT_SDIO1)
36ce78179eSArnd Bergmann #define  CLOCK_GATING_NAND_MASK		(1 << CLOCK_GATING_BIT_NAND)
37ce78179eSArnd Bergmann #define  CLOCK_GATING_CAMERA_MASK	(1 << CLOCK_GATING_BIT_CAMERA)
38ce78179eSArnd Bergmann #define  CLOCK_GATING_I2S0_MASK		(1 << CLOCK_GATING_BIT_I2S0)
39ce78179eSArnd Bergmann #define  CLOCK_GATING_I2S1_MASK		(1 << CLOCK_GATING_BIT_I2S1)
40ce78179eSArnd Bergmann #define  CLOCK_GATING_CRYPTO_MASK	(1 << CLOCK_GATING_BIT_CRYPTO)
41ce78179eSArnd Bergmann #define  CLOCK_GATING_AC97_MASK		(1 << CLOCK_GATING_BIT_AC97)
42ce78179eSArnd Bergmann #define  CLOCK_GATING_PDMA_MASK		(1 << CLOCK_GATING_BIT_PDMA)
43ce78179eSArnd Bergmann #define  CLOCK_GATING_XOR0_MASK		(1 << CLOCK_GATING_BIT_XOR0)
44ce78179eSArnd Bergmann #define  CLOCK_GATING_XOR1_MASK		(1 << CLOCK_GATING_BIT_XOR1)
45ce78179eSArnd Bergmann #define  CLOCK_GATING_GIGA_PHY_MASK	(1 << CLOCK_GATING_BIT_GIGA_PHY)
46ce78179eSArnd Bergmann 
47ce78179eSArnd Bergmann #define PMU_INTERRUPT_CAUSE	(DOVE_PMU_VIRT_BASE + 0x50)
48ce78179eSArnd Bergmann 
49ce78179eSArnd Bergmann #define  PMU_SW_RST_VIDEO_MASK		BIT(16)
50ce78179eSArnd Bergmann #define  PMU_SW_RST_GPU_MASK		BIT(18)
51ce78179eSArnd Bergmann 
52ce78179eSArnd Bergmann #define  PMU_PWR_GPU_PWR_DWN_MASK	BIT(2)
53ce78179eSArnd Bergmann #define  PMU_PWR_VPU_PWR_DWN_MASK	BIT(3)
54ce78179eSArnd Bergmann 
55ce78179eSArnd Bergmann #define  PMU_ISO_VIDEO_MASK		BIT(0)
56ce78179eSArnd Bergmann #define  PMU_ISO_GPU_MASK		BIT(1)
57ce78179eSArnd Bergmann 
58ce78179eSArnd Bergmann #endif
59