topology.c (a02001086bbfb4da35d1228bebc2f1b442db455f) topology.c (4ed89f2228061422ce5f62545fd0b6f6648bd2cc)
1/*
2 * arch/arm/kernel/topology.c
3 *
4 * Copyright (C) 2011 Linaro Limited.
5 * Written by: Vincent Guittot
6 *
7 * based on arch/sh/kernel/topology.c
8 *

--- 151 unchanged lines hidden (view full) ---

160 */
161static void update_cpu_capacity(unsigned int cpu)
162{
163 if (!cpu_capacity(cpu))
164 return;
165
166 set_capacity_scale(cpu, cpu_capacity(cpu) / middle_capacity);
167
1/*
2 * arch/arm/kernel/topology.c
3 *
4 * Copyright (C) 2011 Linaro Limited.
5 * Written by: Vincent Guittot
6 *
7 * based on arch/sh/kernel/topology.c
8 *

--- 151 unchanged lines hidden (view full) ---

160 */
161static void update_cpu_capacity(unsigned int cpu)
162{
163 if (!cpu_capacity(cpu))
164 return;
165
166 set_capacity_scale(cpu, cpu_capacity(cpu) / middle_capacity);
167
168 printk(KERN_INFO "CPU%u: update cpu_capacity %lu\n",
168 pr_info("CPU%u: update cpu_capacity %lu\n",
169 cpu, arch_scale_cpu_capacity(NULL, cpu));
170}
171
172#else
173static inline void parse_dt_topology(void) {}
174static inline void update_cpu_capacity(unsigned int cpuid) {}
175#endif
176

--- 87 unchanged lines hidden (view full) ---

264 cpuid_topo->core_id = 0;
265 cpuid_topo->socket_id = -1;
266 }
267
268 update_siblings_masks(cpuid);
269
270 update_cpu_capacity(cpuid);
271
169 cpu, arch_scale_cpu_capacity(NULL, cpu));
170}
171
172#else
173static inline void parse_dt_topology(void) {}
174static inline void update_cpu_capacity(unsigned int cpuid) {}
175#endif
176

--- 87 unchanged lines hidden (view full) ---

264 cpuid_topo->core_id = 0;
265 cpuid_topo->socket_id = -1;
266 }
267
268 update_siblings_masks(cpuid);
269
270 update_cpu_capacity(cpuid);
271
272 printk(KERN_INFO "CPU%u: thread %d, cpu %d, socket %d, mpidr %x\n",
272 pr_info("CPU%u: thread %d, cpu %d, socket %d, mpidr %x\n",
273 cpuid, cpu_topology[cpuid].thread_id,
274 cpu_topology[cpuid].core_id,
275 cpu_topology[cpuid].socket_id, mpidr);
276}
277
278static inline int cpu_corepower_flags(void)
279{
280 return SD_SHARE_PKG_RESOURCES | SD_SHARE_POWERDOMAIN;

--- 38 unchanged lines hidden ---
273 cpuid, cpu_topology[cpuid].thread_id,
274 cpu_topology[cpuid].core_id,
275 cpu_topology[cpuid].socket_id, mpidr);
276}
277
278static inline int cpu_corepower_flags(void)
279{
280 return SD_SHARE_PKG_RESOURCES | SD_SHARE_POWERDOMAIN;

--- 38 unchanged lines hidden ---