Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

ARM: qcom: remove unnecessary boot_lock

The boot_lock is something that was required for ARM development
platforms to ensure that the delay calibration worked properly. This
is not necessary for modern platforms that have better bus bandwidth
and do not need to calibrate the delay loop for secondary cores.
Remove the boot_lock entirely.

Signed-off-by: Russell King <rmk+kernel@armlinux.org.uk>

-26
-26
arch/arm/mach-qcom/platsmp.c
··· 46 46 47 47 extern void secondary_startup_arm(void); 48 48 49 - static DEFINE_SPINLOCK(boot_lock); 50 - 51 49 #ifdef CONFIG_HOTPLUG_CPU 52 50 static void qcom_cpu_die(unsigned int cpu) 53 51 { 54 52 wfi(); 55 53 } 56 54 #endif 57 - 58 - static void qcom_secondary_init(unsigned int cpu) 59 - { 60 - /* 61 - * Synchronise with the boot thread. 62 - */ 63 - spin_lock(&boot_lock); 64 - spin_unlock(&boot_lock); 65 - } 66 55 67 56 static int scss_release_secondary(unsigned int cpu) 68 57 { ··· 270 281 } 271 282 272 283 /* 273 - * set synchronisation state between this boot processor 274 - * and the secondary one 275 - */ 276 - spin_lock(&boot_lock); 277 - 278 - /* 279 284 * Send the secondary CPU a soft interrupt, thereby causing 280 285 * the boot monitor to read the system wide flags register, 281 286 * and branch to the address found there. 282 287 */ 283 288 arch_send_wakeup_ipi_mask(cpumask_of(cpu)); 284 - 285 - /* 286 - * now the secondary core is starting up let it run its 287 - * calibrations, then wait for it to finish 288 - */ 289 - spin_unlock(&boot_lock); 290 289 291 290 return ret; 292 291 } ··· 311 334 312 335 static const struct smp_operations smp_msm8660_ops __initconst = { 313 336 .smp_prepare_cpus = qcom_smp_prepare_cpus, 314 - .smp_secondary_init = qcom_secondary_init, 315 337 .smp_boot_secondary = msm8660_boot_secondary, 316 338 #ifdef CONFIG_HOTPLUG_CPU 317 339 .cpu_die = qcom_cpu_die, ··· 320 344 321 345 static const struct smp_operations qcom_smp_kpssv1_ops __initconst = { 322 346 .smp_prepare_cpus = qcom_smp_prepare_cpus, 323 - .smp_secondary_init = qcom_secondary_init, 324 347 .smp_boot_secondary = kpssv1_boot_secondary, 325 348 #ifdef CONFIG_HOTPLUG_CPU 326 349 .cpu_die = qcom_cpu_die, ··· 329 354 330 355 static const struct smp_operations qcom_smp_kpssv2_ops __initconst = { 331 356 .smp_prepare_cpus = qcom_smp_prepare_cpus, 332 - .smp_secondary_init = qcom_secondary_init, 333 357 .smp_boot_secondary = kpssv2_boot_secondary, 334 358 #ifdef CONFIG_HOTPLUG_CPU 335 359 .cpu_die = qcom_cpu_die,