diff --git a/arch/arm64/kernel/cpuinfo.c b/arch/arm64/kernel/cpuinfo.c index a326ce7ecc8e..51515fb07679 100644 --- a/arch/arm64/kernel/cpuinfo.c +++ b/arch/arm64/kernel/cpuinfo.c @@ -205,6 +205,9 @@ static int c_show(struct seq_file *m, void *v) } } #endif + else { + seq_printf(m, "model name\t: %s\n", midr_to_desc(midr)); + } seq_printf(m, "BogoMIPS\t: %lu.%02lu\n", loops_per_jiffy / (500000UL/HZ), loops_per_jiffy / (5000UL/HZ) % 100); diff --git a/arch/arm64/kernel/topology.c b/arch/arm64/kernel/topology.c index 543c67cae02f..d208a55ae785 100644 --- a/arch/arm64/kernel/topology.c +++ b/arch/arm64/kernel/topology.c @@ -17,10 +17,12 @@ #include #include #include +#include #include #include #include +#include void store_cpu_topology(unsigned int cpuid) { @@ -51,15 +53,26 @@ void store_cpu_topology(unsigned int cpuid) * need to entirely ignore MPIDR for any topology deduction. */ cpuid_topo->thread_id = -1; - cpuid_topo->core_id = cpuid; - cpuid_topo->package_id = cpu_to_node(cpuid); - + pr_info("Q cpu_name %s\n", get_cpu_name()); + if(cpu_is_ft2004()) { + cpuid_topo->core_id = cpuid%2; + cpuid_topo->package_id = cpuid/2; + } else { + cpuid_topo->core_id = cpuid; + cpuid_topo->package_id = cpu_to_node(cpuid); + } pr_debug("CPU%u: cluster %d core %d thread %d mpidr %#016llx\n", cpuid, cpuid_topo->package_id, cpuid_topo->core_id, cpuid_topo->thread_id, mpidr); topology_populated: + pr_info("x CPU%u: cluster %d core %d thread %d mpidr %#016llx\n", + cpuid, cpuid_topo->package_id, cpuid_topo->core_id, + cpuid_topo->thread_id, mpidr); update_siblings_masks(cpuid); + pr_info("y CPU%u: cluster %d core %d thread %d mpidr %#016llx\n", + cpuid, cpuid_topo->package_id, cpuid_topo->core_id, + cpuid_topo->thread_id, mpidr); } #ifdef CONFIG_ACPI