This source file includes following definitions.
- omap4_cpu_die
- omap4_cpu_kill
1
2
3
4
5
6
7
8
9
10
11
12
13
14 #include <linux/kernel.h>
15 #include <linux/errno.h>
16 #include <linux/smp.h>
17 #include <linux/io.h>
18
19 #include "omap-wakeupgen.h"
20 #include "common.h"
21 #include "powerdomain.h"
22
23
24
25
26
27 void omap4_cpu_die(unsigned int cpu)
28 {
29 unsigned int boot_cpu = 0;
30 void __iomem *base = omap_get_wakeupgen_base();
31
32
33
34
35 if (omap_secure_apis_support()) {
36 if (omap_modify_auxcoreboot0(0x0, 0x200) != 0x0)
37 pr_err("Secure clear status failed\n");
38 } else {
39 writel_relaxed(0, base + OMAP_AUX_CORE_BOOT_0);
40 }
41
42
43 for (;;) {
44
45
46
47 omap4_hotplug_cpu(cpu, PWRDM_POWER_OFF);
48
49 if (omap_secure_apis_support())
50 boot_cpu = omap_read_auxcoreboot0() >> 9;
51 else
52 boot_cpu =
53 readl_relaxed(base + OMAP_AUX_CORE_BOOT_0) >> 5;
54
55 if (boot_cpu == smp_processor_id()) {
56
57
58
59 break;
60 }
61 pr_debug("CPU%u: spurious wakeup call\n", cpu);
62 }
63 }
64
65
66 int omap4_cpu_kill(unsigned int cpu)
67 {
68 return 1;
69 }