Home
last modified time | relevance | path

Searched refs:mpidr (Results 1 – 33 of 33) sorted by relevance

/linux-4.1.27/arch/arm/common/
Dmcpm_platsmp.c25 unsigned int mpidr; in cpu_to_pcpu() local
27 mpidr = cpu_logical_map(cpu); in cpu_to_pcpu()
28 *pcpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in cpu_to_pcpu()
29 *pcluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in cpu_to_pcpu()
80 unsigned int mpidr, pcpu, pcluster; in mcpm_cpu_die() local
81 mpidr = read_cpuid_mpidr(); in mcpm_cpu_die()
82 pcpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in mcpm_cpu_die()
83 pcluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in mcpm_cpu_die()
Dmcpm_entry.c127 unsigned int mpidr, cpu, cluster; in mcpm_cpu_power_down() local
147 mpidr = read_cpuid_mpidr(); in mcpm_cpu_power_down()
148 cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in mcpm_cpu_power_down()
149 cluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in mcpm_cpu_power_down()
240 unsigned int mpidr = read_cpuid_mpidr(); in mcpm_cpu_suspend() local
241 unsigned int cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in mcpm_cpu_suspend()
242 unsigned int cluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in mcpm_cpu_suspend()
252 unsigned int mpidr, cpu, cluster; in mcpm_cpu_powered_up() local
265 mpidr = read_cpuid_mpidr(); in mcpm_cpu_powered_up()
266 cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in mcpm_cpu_powered_up()
[all …]
DbL_switcher.c126 unsigned int mpidr = read_mpidr(); in bL_switchpoint() local
127 unsigned int clusterid = MPIDR_AFFINITY_LEVEL(mpidr, 1); in bL_switchpoint()
151 unsigned int mpidr, this_cpu, that_cpu; in bL_switch_to() local
238 mpidr = read_mpidr(); in bL_switch_to()
239 pr_debug("after switch: CPU %d MPIDR %#x\n", this_cpu, mpidr); in bL_switch_to()
240 BUG_ON(mpidr != ib_mpidr); in bL_switch_to()
518 int bL_switcher_get_logical_index(u32 mpidr) in bL_switcher_get_logical_index() argument
525 mpidr &= MPIDR_HWID_BITMASK; in bL_switcher_get_logical_index()
530 if ((mpidr == cpu_logical_map(cpu)) || in bL_switcher_get_logical_index()
531 (mpidr == cpu_logical_map(pairing))) in bL_switcher_get_logical_index()
/linux-4.1.27/arch/arm64/kernel/
Dtopology.c242 u64 mpidr; in store_cpu_topology() local
247 mpidr = read_cpuid_mpidr(); in store_cpu_topology()
250 if (mpidr & MPIDR_UP_BITMASK) in store_cpu_topology()
254 if (mpidr & MPIDR_MT_BITMASK) { in store_cpu_topology()
256 cpuid_topo->thread_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in store_cpu_topology()
257 cpuid_topo->core_id = MPIDR_AFFINITY_LEVEL(mpidr, 1); in store_cpu_topology()
258 cpuid_topo->cluster_id = MPIDR_AFFINITY_LEVEL(mpidr, 2) | in store_cpu_topology()
259 MPIDR_AFFINITY_LEVEL(mpidr, 3) << 8; in store_cpu_topology()
263 cpuid_topo->core_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in store_cpu_topology()
264 cpuid_topo->cluster_id = MPIDR_AFFINITY_LEVEL(mpidr, 1) | in store_cpu_topology()
[all …]
Dacpi.c106 u64 mpidr = processor->arm_mpidr & MPIDR_HWID_BITMASK; in acpi_map_gic_cpu_interface() local
109 if (mpidr == INVALID_HWID) { in acpi_map_gic_cpu_interface()
120 NR_CPUS, total_cpus, mpidr); in acpi_map_gic_cpu_interface()
125 if (cpu_logical_map(0) == mpidr) { in acpi_map_gic_cpu_interface()
128 mpidr); in acpi_map_gic_cpu_interface()
141 if (cpu_logical_map(i) == mpidr) { in acpi_map_gic_cpu_interface()
143 mpidr); in acpi_map_gic_cpu_interface()
161 cpu_logical_map(enabled_cpus) = mpidr; in acpi_map_gic_cpu_interface()
Dsleep.S37 .macro compute_mpidr_hash dst, rs0, rs1, rs2, rs3, mpidr, mask
38 and \mpidr, \mpidr, \mask // mask out MPIDR bits
39 and \dst, \mpidr, #0xff // mask=aff0
41 and \mask, \mpidr, #0xff00 // mask = aff1
44 and \mask, \mpidr, #0xff0000 // mask = aff2
47 and \mask, \mpidr, #0xff00000000 // mask = aff3
Dsetup.c127 u64 mpidr = read_cpuid_mpidr() & MPIDR_HWID_BITMASK; in smp_setup_processor_id() local
128 cpu_logical_map(0) = mpidr; in smp_setup_processor_id()
136 pr_info("Booting Linux on physical CPU 0x%lx\n", (unsigned long)mpidr); in smp_setup_processor_id()
/linux-4.1.27/arch/arm/kernel/
Dtopology.c231 unsigned int mpidr; in store_cpu_topology() local
237 mpidr = read_cpuid_mpidr(); in store_cpu_topology()
240 if ((mpidr & MPIDR_SMP_BITMASK) == MPIDR_SMP_VALUE) { in store_cpu_topology()
246 if (mpidr & MPIDR_MT_BITMASK) { in store_cpu_topology()
248 cpuid_topo->thread_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in store_cpu_topology()
249 cpuid_topo->core_id = MPIDR_AFFINITY_LEVEL(mpidr, 1); in store_cpu_topology()
250 cpuid_topo->socket_id = MPIDR_AFFINITY_LEVEL(mpidr, 2); in store_cpu_topology()
254 cpuid_topo->core_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in store_cpu_topology()
255 cpuid_topo->socket_id = MPIDR_AFFINITY_LEVEL(mpidr, 1); in store_cpu_topology()
275 cpu_topology[cpuid].socket_id, mpidr); in store_cpu_topology()
Dsleep.S37 .macro compute_mpidr_hash dst, rs0, rs1, rs2, mpidr, mask
38 and \mpidr, \mpidr, \mask @ mask out MPIDR bits
39 and \dst, \mpidr, #0xff @ mask=aff0
42 and \mask, \mpidr, #0xff00 @ mask = aff1
46 and \mask, \mpidr, #0xff0000 @ mask = aff2
77 ldmia r0, {r1, r6-r8} @ r1 = mpidr mask (r6,r7,r8) = l[0,1,2] shifts
137 ldmia r2, { r3-r6 } @ r3 = mpidr mask (r4,r5,r6) = l[0,1,2] shifts
Ddevtree.c80 u32 mpidr = is_smp() ? read_cpuid_mpidr() & MPIDR_HWID_BITMASK : 0; in arm_dt_init_cpu_maps() local
135 if (hwid == mpidr) { in arm_dt_init_cpu_maps()
Dsetup.c514 u32 mpidr = is_smp() ? read_cpuid_mpidr() & MPIDR_HWID_BITMASK : 0; in smp_setup_processor_id() local
515 u32 cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in smp_setup_processor_id()
528 pr_info("Booting Linux on physical CPU 0x%x\n", mpidr); in smp_setup_processor_id()
/linux-4.1.27/virt/kvm/arm/
Dvgic-v3-emul.c217 static u32 compress_mpidr(unsigned long mpidr) in compress_mpidr() argument
221 ret = MPIDR_AFFINITY_LEVEL(mpidr, 0); in compress_mpidr()
222 ret |= MPIDR_AFFINITY_LEVEL(mpidr, 1) << 8; in compress_mpidr()
223 ret |= MPIDR_AFFINITY_LEVEL(mpidr, 2) << 16; in compress_mpidr()
224 ret |= MPIDR_AFFINITY_LEVEL(mpidr, 3) << 24; in compress_mpidr()
231 unsigned long mpidr; in uncompress_mpidr() local
233 mpidr = ((value >> 0) & 0xFF) << MPIDR_LEVEL_SHIFT(0); in uncompress_mpidr()
234 mpidr |= ((value >> 8) & 0xFF) << MPIDR_LEVEL_SHIFT(1); in uncompress_mpidr()
235 mpidr |= ((value >> 16) & 0xFF) << MPIDR_LEVEL_SHIFT(2); in uncompress_mpidr()
236 mpidr |= (u64)((value >> 24) & 0xFF) << MPIDR_LEVEL_SHIFT(3); in uncompress_mpidr()
[all …]
/linux-4.1.27/arch/arm/mach-hisi/
Dplatmcpm.c143 unsigned int mpidr, cpu, cluster; in hip04_mcpm_power_down() local
146 mpidr = read_cpuid_mpidr(); in hip04_mcpm_power_down()
147 cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in hip04_mcpm_power_down()
148 cluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in hip04_mcpm_power_down()
232 unsigned int mpidr, cpu, cluster; in hip04_mcpm_powered_up() local
234 mpidr = read_cpuid_mpidr(); in hip04_mcpm_powered_up()
235 cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in hip04_mcpm_powered_up()
236 cluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in hip04_mcpm_powered_up()
285 unsigned int mpidr, cpu, cluster; in hip04_cpu_table_init() local
287 mpidr = read_cpuid_mpidr(); in hip04_cpu_table_init()
[all …]
/linux-4.1.27/arch/arm/mach-exynos/
Dplatsmp.c56 u32 mpidr = cpu_logical_map(cpu); in platform_do_lowpower() local
57 u32 core_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in platform_do_lowpower()
254 u32 mpidr = cpu_logical_map(cpu); in exynos_boot_secondary() local
255 u32 core_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in exynos_boot_secondary()
402 u32 mpidr; in exynos_smp_prepare_cpus() local
406 mpidr = cpu_logical_map(i); in exynos_smp_prepare_cpus()
407 core_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in exynos_smp_prepare_cpus()
432 u32 mpidr = cpu_logical_map(cpu); in exynos_cpu_die() local
433 u32 core_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in exynos_cpu_die()
Dregs-pmu.h490 static inline unsigned int exynos_pmu_cpunr(unsigned int mpidr) in exynos_pmu_cpunr() argument
492 return ((MPIDR_AFFINITY_LEVEL(mpidr, 1) * MAX_CPUS_IN_CLUSTER) in exynos_pmu_cpunr()
493 + MPIDR_AFFINITY_LEVEL(mpidr, 0)); in exynos_pmu_cpunr()
Dsuspend.c306 unsigned int mpidr = read_cpuid_mpidr(); in exynos5420_cpu_suspend() local
307 unsigned int cluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in exynos5420_cpu_suspend()
308 unsigned int cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in exynos5420_cpu_suspend()
/linux-4.1.27/drivers/irqchip/
Dirq-gic-v3.c325 static u64 gic_mpidr_to_affinity(u64 mpidr) in gic_mpidr_to_affinity() argument
329 aff = (MPIDR_AFFINITY_LEVEL(mpidr, 3) << 32 | in gic_mpidr_to_affinity()
330 MPIDR_AFFINITY_LEVEL(mpidr, 2) << 16 | in gic_mpidr_to_affinity()
331 MPIDR_AFFINITY_LEVEL(mpidr, 1) << 8 | in gic_mpidr_to_affinity()
332 MPIDR_AFFINITY_LEVEL(mpidr, 0)); in gic_mpidr_to_affinity()
408 u64 mpidr = cpu_logical_map(smp_processor_id()); in gic_populate_rdist() local
417 aff = (MPIDR_AFFINITY_LEVEL(mpidr, 3) << 24 | in gic_populate_rdist()
418 MPIDR_AFFINITY_LEVEL(mpidr, 2) << 16 | in gic_populate_rdist()
419 MPIDR_AFFINITY_LEVEL(mpidr, 1) << 8 | in gic_populate_rdist()
420 MPIDR_AFFINITY_LEVEL(mpidr, 0)); in gic_populate_rdist()
[all …]
Dirq-gic.c920 u32 mpidr = cpu_logical_map(cpu); in gic_init_bases() local
921 u32 core_id = MPIDR_AFFINITY_LEVEL(mpidr, 0); in gic_init_bases()
/linux-4.1.27/arch/arm/mach-vexpress/
Dtc2_pm.c207 unsigned int mpidr, cpu, cluster; in tc2_pm_init() local
247 mpidr = read_cpuid_mpidr(); in tc2_pm_init()
248 cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in tc2_pm_init()
249 cluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in tc2_pm_init()
/linux-4.1.27/drivers/cpuidle/
Dcpuidle-big_little.c106 unsigned int mpidr = read_cpuid_mpidr(); in bl_powerdown_finisher() local
107 unsigned int cluster = MPIDR_AFFINITY_LEVEL(mpidr, 1); in bl_powerdown_finisher()
108 unsigned int cpu = MPIDR_AFFINITY_LEVEL(mpidr, 0); in bl_powerdown_finisher()
/linux-4.1.27/arch/arm/include/asm/
DbL_switcher.h58 int bL_switcher_get_logical_index(u32 mpidr);
74 static inline int bL_switcher_get_logical_index(u32 mpidr) { return -EUNATCH; } in bL_switcher_get_logical_index() argument
Dsmp_plat.h79 static inline int get_logical_index(u32 mpidr) in get_logical_index() argument
83 if (cpu_logical_map(cpu) == mpidr) in get_logical_index()
Dcputype.h59 #define MPIDR_AFFINITY_LEVEL(mpidr, level) \ argument
60 ((mpidr >> (MPIDR_LEVEL_BITS * level)) & MPIDR_LEVEL_MASK)
Dkvm_host.h231 struct kvm_vcpu *kvm_mpidr_to_vcpu(struct kvm *kvm, unsigned long mpidr);
/linux-4.1.27/include/linux/
Darm-cci.h39 extern int cci_disable_port_by_cpu(u64 mpidr);
47 static inline int cci_disable_port_by_cpu(u64 mpidr) { return -ENODEV; } in cci_disable_port_by_cpu() argument
/linux-4.1.27/arch/arm/kvm/
Dpsci.c128 unsigned long mpidr; in kvm_psci_vcpu_affinity_info() local
151 mpidr = kvm_vcpu_get_mpidr_aff(tmp); in kvm_psci_vcpu_affinity_info()
152 if (((mpidr & target_affinity_mask) == target_affinity) && in kvm_psci_vcpu_affinity_info()
Darm.c1085 struct kvm_vcpu *kvm_mpidr_to_vcpu(struct kvm *kvm, unsigned long mpidr) in kvm_mpidr_to_vcpu() argument
1090 mpidr &= MPIDR_HWID_BITMASK; in kvm_mpidr_to_vcpu()
1092 if (mpidr == kvm_vcpu_get_mpidr_aff(vcpu)) in kvm_mpidr_to_vcpu()
/linux-4.1.27/arch/arm64/include/asm/
Dcputype.h32 #define MPIDR_AFFINITY_LEVEL(mpidr, level) \ argument
33 ((mpidr >> MPIDR_LEVEL_SHIFT(level)) & MPIDR_LEVEL_MASK)
Dkvm_host.h204 struct kvm_vcpu *kvm_mpidr_to_vcpu(struct kvm *kvm, unsigned long mpidr);
/linux-4.1.27/drivers/bus/
Darm-cci.c1070 u64 mpidr; member
1085 static inline void init_cpu_port(struct cpu_port *port, u32 index, u64 mpidr) in init_cpu_port() argument
1088 port->mpidr = mpidr; in init_cpu_port()
1096 static inline bool cpu_port_match(struct cpu_port *port, u64 mpidr) in cpu_port_match() argument
1098 return port->mpidr == (mpidr & MPIDR_HWID_BITMASK); in cpu_port_match()
1218 int notrace cci_disable_port_by_cpu(u64 mpidr) in cci_disable_port_by_cpu() argument
1224 if (is_valid && cpu_port_match(&cpu_port[cpu], mpidr)) { in cci_disable_port_by_cpu()
1319 [offsetof_cpu_port_mpidr_lsb] "i" (offsetof(struct cpu_port, mpidr)), in cci_enable_port_for_self()
1321 [offsetof_cpu_port_mpidr_lsb] "i" (offsetof(struct cpu_port, mpidr)+4), in cci_enable_port_for_self()
/linux-4.1.27/arch/arm/mach-shmobile/
Dheadsmp.S53 adr r5, 1f @ array of per-cpu mpidr values
/linux-4.1.27/drivers/acpi/
Dprocessor_core.c90 int device_declaration, u32 acpi_id, phys_cpuid_t *mpidr) in map_gicc_mpidr() argument
104 *mpidr = gicc->arm_mpidr; in map_gicc_mpidr()
/linux-4.1.27/arch/arm64/kvm/
Dsys_regs.c224 u64 mpidr; in reset_mpidr() local
233 mpidr = (vcpu->vcpu_id & 0x0f) << MPIDR_LEVEL_SHIFT(0); in reset_mpidr()
234 mpidr |= ((vcpu->vcpu_id >> 4) & 0xff) << MPIDR_LEVEL_SHIFT(1); in reset_mpidr()
235 mpidr |= ((vcpu->vcpu_id >> 12) & 0xff) << MPIDR_LEVEL_SHIFT(2); in reset_mpidr()
236 vcpu_sys_reg(vcpu, MPIDR_EL1) = (1ULL << 31) | mpidr; in reset_mpidr()