Lines Matching refs:core

22 static void sunxi_cpu_disable_power(unsigned int cluster, unsigned int core)  in sunxi_cpu_disable_power()  argument
24 if (mmio_read_32(SUNXI_CPU_POWER_CLAMP_REG(cluster, core)) == 0xff) in sunxi_cpu_disable_power()
27 VERBOSE("PSCI: Disabling power to cluster %d core %d\n", cluster, core); in sunxi_cpu_disable_power()
29 mmio_write_32(SUNXI_CPU_POWER_CLAMP_REG(cluster, core), 0xff); in sunxi_cpu_disable_power()
32 static void sunxi_cpu_enable_power(unsigned int cluster, unsigned int core) in sunxi_cpu_enable_power() argument
34 if (mmio_read_32(SUNXI_CPU_POWER_CLAMP_REG(cluster, core)) == 0) in sunxi_cpu_enable_power()
37 VERBOSE("PSCI: Enabling power to cluster %d core %d\n", cluster, core); in sunxi_cpu_enable_power()
40 mmio_write_32(SUNXI_CPU_POWER_CLAMP_REG(cluster, core), 0xfe); in sunxi_cpu_enable_power()
41 mmio_write_32(SUNXI_CPU_POWER_CLAMP_REG(cluster, core), 0xf8); in sunxi_cpu_enable_power()
42 mmio_write_32(SUNXI_CPU_POWER_CLAMP_REG(cluster, core), 0xe0); in sunxi_cpu_enable_power()
43 mmio_write_32(SUNXI_CPU_POWER_CLAMP_REG(cluster, core), 0x80); in sunxi_cpu_enable_power()
44 mmio_write_32(SUNXI_CPU_POWER_CLAMP_REG(cluster, core), 0x00); in sunxi_cpu_enable_power()
52 unsigned int core = MPIDR_AFFLVL0_VAL(mpidr); in sunxi_cpu_off() local
54 VERBOSE("PSCI: Powering off cluster %d core %d\n", cluster, core); in sunxi_cpu_off()
57 mmio_clrbits_32(SUNXI_CPUCFG_DBG_REG0, BIT(core)); in sunxi_cpu_off()
59 if (core != 0) in sunxi_cpu_off()
60 mmio_setbits_32(SUNXI_POWEROFF_GATING_REG(cluster), BIT(core)); in sunxi_cpu_off()
62 mmio_clrbits_32(SUNXI_POWERON_RST_REG(cluster), BIT(core)); in sunxi_cpu_off()
64 sunxi_cpu_disable_power(cluster, core); in sunxi_cpu_off()
70 unsigned int core = MPIDR_AFFLVL0_VAL(mpidr); in sunxi_cpu_on() local
72 VERBOSE("PSCI: Powering on cluster %d core %d\n", cluster, core); in sunxi_cpu_on()
75 mmio_clrbits_32(SUNXI_CPUCFG_RST_CTRL_REG(cluster), BIT(core)); in sunxi_cpu_on()
77 mmio_clrbits_32(SUNXI_POWERON_RST_REG(cluster), BIT(core)); in sunxi_cpu_on()
80 BIT(SUNXI_AA64nAA32_OFFSET + core)); in sunxi_cpu_on()
82 sunxi_cpu_enable_power(cluster, core); in sunxi_cpu_on()
84 mmio_clrbits_32(SUNXI_POWEROFF_GATING_REG(cluster), BIT(core)); in sunxi_cpu_on()
86 mmio_setbits_32(SUNXI_POWERON_RST_REG(cluster), BIT(core)); in sunxi_cpu_on()
88 mmio_setbits_32(SUNXI_CPUCFG_RST_CTRL_REG(cluster), BIT(core)); in sunxi_cpu_on()
90 mmio_setbits_32(SUNXI_CPUCFG_DBG_REG0, BIT(core)); in sunxi_cpu_on()
97 unsigned int core; in sunxi_cpu_power_off_others() local
100 for (core = 0; core < PLATFORM_MAX_CPUS_PER_CLUSTER; ++core) { in sunxi_cpu_power_off_others()
102 (core << MPIDR_AFF0_SHIFT) | in sunxi_cpu_power_off_others()