aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-realview/realview_eb.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-realview/realview_eb.c')
-rw-r--r--arch/arm/mach-realview/realview_eb.c32
1 files changed, 32 insertions, 0 deletions
diff --git a/arch/arm/mach-realview/realview_eb.c b/arch/arm/mach-realview/realview_eb.c
index 006765fd204c..422ccd70d5f5 100644
--- a/arch/arm/mach-realview/realview_eb.c
+++ b/arch/arm/mach-realview/realview_eb.c
@@ -31,6 +31,7 @@
31#include <asm/irq.h> 31#include <asm/irq.h>
32#include <asm/leds.h> 32#include <asm/leds.h>
33#include <asm/mach-types.h> 33#include <asm/mach-types.h>
34#include <asm/pmu.h>
34#include <asm/hardware/gic.h> 35#include <asm/hardware/gic.h>
35#include <asm/hardware/cache-l2x0.h> 36#include <asm/hardware/cache-l2x0.h>
36#include <asm/localtimer.h> 37#include <asm/localtimer.h>
@@ -292,6 +293,36 @@ static struct resource realview_eb_isp1761_resources[] = {
292 }, 293 },
293}; 294};
294 295
296static struct resource pmu_resources[] = {
297 [0] = {
298 .start = IRQ_EB11MP_PMU_CPU0,
299 .end = IRQ_EB11MP_PMU_CPU0,
300 .flags = IORESOURCE_IRQ,
301 },
302 [1] = {
303 .start = IRQ_EB11MP_PMU_CPU1,
304 .end = IRQ_EB11MP_PMU_CPU1,
305 .flags = IORESOURCE_IRQ,
306 },
307 [2] = {
308 .start = IRQ_EB11MP_PMU_CPU2,
309 .end = IRQ_EB11MP_PMU_CPU2,
310 .flags = IORESOURCE_IRQ,
311 },
312 [3] = {
313 .start = IRQ_EB11MP_PMU_CPU3,
314 .end = IRQ_EB11MP_PMU_CPU3,
315 .flags = IORESOURCE_IRQ,
316 },
317};
318
319static struct platform_device pmu_device = {
320 .name = "arm-pmu",
321 .id = ARM_PMU_DEVICE_CPU,
322 .num_resources = ARRAY_SIZE(pmu_resources),
323 .resource = pmu_resources,
324};
325
295static void __init gic_init_irq(void) 326static void __init gic_init_irq(void)
296{ 327{
297 if (core_tile_eb11mp() || core_tile_a9mp()) { 328 if (core_tile_eb11mp() || core_tile_a9mp()) {
@@ -405,6 +436,7 @@ static void __init realview_eb_init(void)
405 * Bits: .... ...0 0111 1001 0000 .... .... .... */ 436 * Bits: .... ...0 0111 1001 0000 .... .... .... */
406 l2x0_init(__io_address(REALVIEW_EB11MP_L220_BASE), 0x00790000, 0xfe000fff); 437 l2x0_init(__io_address(REALVIEW_EB11MP_L220_BASE), 0x00790000, 0xfe000fff);
407#endif 438#endif
439 platform_device_register(&pmu_device);
408 } 440 }
409 441
410 realview_flash_register(&realview_eb_flash_resource, 1); 442 realview_flash_register(&realview_eb_flash_resource, 1);