Commit 69e21363 authored by Stepan Moskovchenko's avatar Stepan Moskovchenko Committed by David Brown

msm: iommu: Generalize platform data for multiple targets

Make the IOMMU platform data target-independent in
preparation for adding MSM8960 IOMMU support. The IOMMU
configuration on MSM8x60 and MSM8960 is identical and the
same platform data can be used for both.
Signed-off-by: default avatarStepan Moskovchenko <stepanm@codeaurora.org>
Signed-off-by: default avatarDavid Brown <davidb@codeaurora.org>
parent 24f6173c
...@@ -4,12 +4,12 @@ obj-$(CONFIG_DEBUG_FS) += clock-debug.o ...@@ -4,12 +4,12 @@ obj-$(CONFIG_DEBUG_FS) += clock-debug.o
endif endif
obj-$(CONFIG_MSM_VIC) += irq-vic.o obj-$(CONFIG_MSM_VIC) += irq-vic.o
obj-$(CONFIG_MSM_IOMMU) += iommu.o iommu_dev.o obj-$(CONFIG_MSM_IOMMU) += iommu.o iommu_dev.o devices-iommu.o
obj-$(CONFIG_ARCH_MSM7X00A) += dma.o irq.o acpuclock-arm11.o obj-$(CONFIG_ARCH_MSM7X00A) += dma.o irq.o acpuclock-arm11.o
obj-$(CONFIG_ARCH_MSM7X30) += dma.o obj-$(CONFIG_ARCH_MSM7X30) += dma.o
obj-$(CONFIG_ARCH_QSD8X50) += dma.o sirc.o obj-$(CONFIG_ARCH_QSD8X50) += dma.o sirc.o
obj-$(CONFIG_ARCH_MSM8X60) += clock-dummy.o devices-msm8x60-iommu.o obj-$(CONFIG_ARCH_MSM8X60) += clock-dummy.o
obj-$(CONFIG_ARCH_MSM8960) += clock-dummy.o obj-$(CONFIG_ARCH_MSM8960) += clock-dummy.o
obj-$(CONFIG_MSM_PROC_COMM) += proc_comm.o clock-pcom.o vreg.o obj-$(CONFIG_MSM_PROC_COMM) += proc_comm.o clock-pcom.o vreg.o
......
/* Copyright (c) 2010, Code Aurora Forum. All rights reserved. /* Copyright (c) 2010-2011, Code Aurora Forum. All rights reserved.
* *
* This program is free software; you can redistribute it and/or modify * This program is free software; you can redistribute it and/or modify
* it under the terms of the GNU General Public License version 2 and * it under the terms of the GNU General Public License version 2 and
...@@ -18,15 +18,13 @@ ...@@ -18,15 +18,13 @@
#include <linux/kernel.h> #include <linux/kernel.h>
#include <linux/platform_device.h> #include <linux/platform_device.h>
#include <linux/bootmem.h> #include <linux/bootmem.h>
#include <mach/irqs.h>
#include <mach/msm_iomap-8x60.h>
#include <mach/irqs-8x60.h>
#include <mach/iommu.h> #include <mach/iommu.h>
static struct resource msm_iommu_jpegd_resources[] = { static struct resource msm_iommu_jpegd_resources[] = {
{ {
.start = MSM_IOMMU_JPEGD_PHYS, .start = 0x07300000,
.end = MSM_IOMMU_JPEGD_PHYS + MSM_IOMMU_JPEGD_SIZE - 1, .end = 0x07300000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -46,8 +44,8 @@ static struct resource msm_iommu_jpegd_resources[] = { ...@@ -46,8 +44,8 @@ static struct resource msm_iommu_jpegd_resources[] = {
static struct resource msm_iommu_vpe_resources[] = { static struct resource msm_iommu_vpe_resources[] = {
{ {
.start = MSM_IOMMU_VPE_PHYS, .start = 0x07400000,
.end = MSM_IOMMU_VPE_PHYS + MSM_IOMMU_VPE_SIZE - 1, .end = 0x07400000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -67,8 +65,8 @@ static struct resource msm_iommu_vpe_resources[] = { ...@@ -67,8 +65,8 @@ static struct resource msm_iommu_vpe_resources[] = {
static struct resource msm_iommu_mdp0_resources[] = { static struct resource msm_iommu_mdp0_resources[] = {
{ {
.start = MSM_IOMMU_MDP0_PHYS, .start = 0x07500000,
.end = MSM_IOMMU_MDP0_PHYS + MSM_IOMMU_MDP0_SIZE - 1, .end = 0x07500000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -88,8 +86,8 @@ static struct resource msm_iommu_mdp0_resources[] = { ...@@ -88,8 +86,8 @@ static struct resource msm_iommu_mdp0_resources[] = {
static struct resource msm_iommu_mdp1_resources[] = { static struct resource msm_iommu_mdp1_resources[] = {
{ {
.start = MSM_IOMMU_MDP1_PHYS, .start = 0x07600000,
.end = MSM_IOMMU_MDP1_PHYS + MSM_IOMMU_MDP1_SIZE - 1, .end = 0x07600000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -109,8 +107,8 @@ static struct resource msm_iommu_mdp1_resources[] = { ...@@ -109,8 +107,8 @@ static struct resource msm_iommu_mdp1_resources[] = {
static struct resource msm_iommu_rot_resources[] = { static struct resource msm_iommu_rot_resources[] = {
{ {
.start = MSM_IOMMU_ROT_PHYS, .start = 0x07700000,
.end = MSM_IOMMU_ROT_PHYS + MSM_IOMMU_ROT_SIZE - 1, .end = 0x07700000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -130,8 +128,8 @@ static struct resource msm_iommu_rot_resources[] = { ...@@ -130,8 +128,8 @@ static struct resource msm_iommu_rot_resources[] = {
static struct resource msm_iommu_ijpeg_resources[] = { static struct resource msm_iommu_ijpeg_resources[] = {
{ {
.start = MSM_IOMMU_IJPEG_PHYS, .start = 0x07800000,
.end = MSM_IOMMU_IJPEG_PHYS + MSM_IOMMU_IJPEG_SIZE - 1, .end = 0x07800000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -151,8 +149,8 @@ static struct resource msm_iommu_ijpeg_resources[] = { ...@@ -151,8 +149,8 @@ static struct resource msm_iommu_ijpeg_resources[] = {
static struct resource msm_iommu_vfe_resources[] = { static struct resource msm_iommu_vfe_resources[] = {
{ {
.start = MSM_IOMMU_VFE_PHYS, .start = 0x07900000,
.end = MSM_IOMMU_VFE_PHYS + MSM_IOMMU_VFE_SIZE - 1, .end = 0x07900000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -172,8 +170,8 @@ static struct resource msm_iommu_vfe_resources[] = { ...@@ -172,8 +170,8 @@ static struct resource msm_iommu_vfe_resources[] = {
static struct resource msm_iommu_vcodec_a_resources[] = { static struct resource msm_iommu_vcodec_a_resources[] = {
{ {
.start = MSM_IOMMU_VCODEC_A_PHYS, .start = 0x07A00000,
.end = MSM_IOMMU_VCODEC_A_PHYS + MSM_IOMMU_VCODEC_A_SIZE - 1, .end = 0x07A00000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -193,8 +191,8 @@ static struct resource msm_iommu_vcodec_a_resources[] = { ...@@ -193,8 +191,8 @@ static struct resource msm_iommu_vcodec_a_resources[] = {
static struct resource msm_iommu_vcodec_b_resources[] = { static struct resource msm_iommu_vcodec_b_resources[] = {
{ {
.start = MSM_IOMMU_VCODEC_B_PHYS, .start = 0x07B00000,
.end = MSM_IOMMU_VCODEC_B_PHYS + MSM_IOMMU_VCODEC_B_SIZE - 1, .end = 0x07B00000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -214,8 +212,8 @@ static struct resource msm_iommu_vcodec_b_resources[] = { ...@@ -214,8 +212,8 @@ static struct resource msm_iommu_vcodec_b_resources[] = {
static struct resource msm_iommu_gfx3d_resources[] = { static struct resource msm_iommu_gfx3d_resources[] = {
{ {
.start = MSM_IOMMU_GFX3D_PHYS, .start = 0x07C00000,
.end = MSM_IOMMU_GFX3D_PHYS + MSM_IOMMU_GFX3D_SIZE - 1, .end = 0x07C00000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -235,8 +233,8 @@ static struct resource msm_iommu_gfx3d_resources[] = { ...@@ -235,8 +233,8 @@ static struct resource msm_iommu_gfx3d_resources[] = {
static struct resource msm_iommu_gfx2d0_resources[] = { static struct resource msm_iommu_gfx2d0_resources[] = {
{ {
.start = MSM_IOMMU_GFX2D0_PHYS, .start = 0x07D00000,
.end = MSM_IOMMU_GFX2D0_PHYS + MSM_IOMMU_GFX2D0_SIZE - 1, .end = 0x07D00000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
...@@ -256,8 +254,8 @@ static struct resource msm_iommu_gfx2d0_resources[] = { ...@@ -256,8 +254,8 @@ static struct resource msm_iommu_gfx2d0_resources[] = {
static struct resource msm_iommu_gfx2d1_resources[] = { static struct resource msm_iommu_gfx2d1_resources[] = {
{ {
.start = MSM_IOMMU_GFX2D1_PHYS, .start = 0x07E00000,
.end = MSM_IOMMU_GFX2D1_PHYS + MSM_IOMMU_GFX2D1_SIZE - 1, .end = 0x07E00000 + SZ_1M - 1,
.name = "physbase", .name = "physbase",
.flags = IORESOURCE_MEM, .flags = IORESOURCE_MEM,
}, },
......
...@@ -62,40 +62,4 @@ ...@@ -62,40 +62,4 @@
#define MSM8X60_TMR0_PHYS 0x02040000 #define MSM8X60_TMR0_PHYS 0x02040000
#define MSM8X60_TMR0_SIZE SZ_4K #define MSM8X60_TMR0_SIZE SZ_4K
#define MSM_IOMMU_JPEGD_PHYS 0x07300000
#define MSM_IOMMU_JPEGD_SIZE SZ_1M
#define MSM_IOMMU_VPE_PHYS 0x07400000
#define MSM_IOMMU_VPE_SIZE SZ_1M
#define MSM_IOMMU_MDP0_PHYS 0x07500000
#define MSM_IOMMU_MDP0_SIZE SZ_1M
#define MSM_IOMMU_MDP1_PHYS 0x07600000
#define MSM_IOMMU_MDP1_SIZE SZ_1M
#define MSM_IOMMU_ROT_PHYS 0x07700000
#define MSM_IOMMU_ROT_SIZE SZ_1M
#define MSM_IOMMU_IJPEG_PHYS 0x07800000
#define MSM_IOMMU_IJPEG_SIZE SZ_1M
#define MSM_IOMMU_VFE_PHYS 0x07900000
#define MSM_IOMMU_VFE_SIZE SZ_1M
#define MSM_IOMMU_VCODEC_A_PHYS 0x07A00000
#define MSM_IOMMU_VCODEC_A_SIZE SZ_1M
#define MSM_IOMMU_VCODEC_B_PHYS 0x07B00000
#define MSM_IOMMU_VCODEC_B_SIZE SZ_1M
#define MSM_IOMMU_GFX3D_PHYS 0x07C00000
#define MSM_IOMMU_GFX3D_SIZE SZ_1M
#define MSM_IOMMU_GFX2D0_PHYS 0x07D00000
#define MSM_IOMMU_GFX2D0_SIZE SZ_1M
#define MSM_IOMMU_GFX2D1_PHYS 0x07E00000
#define MSM_IOMMU_GFX2D1_SIZE SZ_1M
#endif #endif
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment