mirror of
https://github.com/edk2-porting/linux-next.git
synced 2024-12-22 20:23:57 +08:00
b76c8b19b0
This way the initcalls don't run on other SoCs on multiplatform kernels. Otherwise we'll get something like this when booting on vexpress: omap_hwmod: _ensure_mpu_hwmod_is_setup: MPU initiator hwmod mpu not yet registered ... WARNING: at arch/arm/mach-omap2/pm.c:82 _init_omap_device+0x74/0x94() _init_omap_device: could not find omap_hwmod for mpu ... omap-dma-engine omap-dma-engine: OMAP DMA engine driver ... Tested-by: Ezequiel Garcia <ezequiel.garcia@free-electrons.com> Signed-off-by: Tony Lindgren <tony@atomide.com>
51 lines
1.3 KiB
C
51 lines
1.3 KiB
C
/*
|
|
* emu.c
|
|
*
|
|
* ETM and ETB CoreSight components' resources as found in OMAP3xxx.
|
|
*
|
|
* Copyright (C) 2009 Nokia Corporation.
|
|
* Alexander Shishkin
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify
|
|
* it under the terms of the GNU General Public License version 2 as
|
|
* published by the Free Software Foundation.
|
|
*/
|
|
|
|
#include <linux/kernel.h>
|
|
#include <linux/init.h>
|
|
#include <linux/types.h>
|
|
#include <linux/module.h>
|
|
#include <linux/device.h>
|
|
#include <linux/amba/bus.h>
|
|
#include <linux/io.h>
|
|
#include <linux/clk.h>
|
|
#include <linux/err.h>
|
|
|
|
#include "soc.h"
|
|
#include "iomap.h"
|
|
|
|
MODULE_LICENSE("GPL");
|
|
MODULE_AUTHOR("Alexander Shishkin");
|
|
|
|
/* Cortex CoreSight components within omap3xxx EMU */
|
|
#define ETM_BASE (L4_EMU_34XX_PHYS + 0x10000)
|
|
#define DBG_BASE (L4_EMU_34XX_PHYS + 0x11000)
|
|
#define ETB_BASE (L4_EMU_34XX_PHYS + 0x1b000)
|
|
#define DAPCTL (L4_EMU_34XX_PHYS + 0x1d000)
|
|
|
|
static AMBA_APB_DEVICE(omap3_etb, "etb", 0x000bb907, ETB_BASE, { }, NULL);
|
|
static AMBA_APB_DEVICE(omap3_etm, "etm", 0x102bb921, ETM_BASE, { }, NULL);
|
|
|
|
static int __init emu_init(void)
|
|
{
|
|
if (!cpu_is_omap34xx())
|
|
return -ENODEV;
|
|
|
|
amba_device_register(&omap3_etb_device, &iomem_resource);
|
|
amba_device_register(&omap3_etm_device, &iomem_resource);
|
|
|
|
return 0;
|
|
}
|
|
|
|
omap_subsys_initcall(emu_init);
|