summaryrefslogtreecommitdiffstats
path: root/arch/sh/kernel/cpu/sh4a
diff options
context:
space:
mode:
authorMagnus Damm <damm@igel.co.jp>2008-07-16 19:02:54 +0900
committerPaul Mundt <lethal@linux-sh.org>2008-07-28 18:10:35 +0900
commit1eca5c92729a83f64826d15a9ecb1652dda54bcb (patch)
tree95753726159c945deccef68d4b54de9f4d5ec756 /arch/sh/kernel/cpu/sh4a
parent714750dd5c6aef8e204d35ba28c1be9641418671 (diff)
sh: Add memory chunks to SH-Mobile UIO devices
This patch adds physically contiguous memory chunks to the UIO devices. The same strategy can be used in the future for the CEU as well. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: Paul Mundt <lethal@linux-sh.org>
Diffstat (limited to 'arch/sh/kernel/cpu/sh4a')
-rw-r--r--arch/sh/kernel/cpu/sh4a/setup-sh7343.c8
-rw-r--r--arch/sh/kernel/cpu/sh4a/setup-sh7366.c12
-rw-r--r--arch/sh/kernel/cpu/sh4a/setup-sh7722.c8
-rw-r--r--arch/sh/kernel/cpu/sh4a/setup-sh7723.c12
4 files changed, 40 insertions, 0 deletions
diff --git a/arch/sh/kernel/cpu/sh4a/setup-sh7343.c b/arch/sh/kernel/cpu/sh4a/setup-sh7343.c
index bcc4255acd8..79ce34e19a2 100644
--- a/arch/sh/kernel/cpu/sh4a/setup-sh7343.c
+++ b/arch/sh/kernel/cpu/sh4a/setup-sh7343.c
@@ -66,6 +66,9 @@ static struct resource vpu_resources[] = {
.end = 0xfe9022eb,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device vpu_device = {
@@ -91,6 +94,9 @@ static struct resource veu_resources[] = {
.end = 0xfe9200b7,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device veu_device = {
@@ -132,6 +138,8 @@ static struct platform_device *sh7343_devices[] __initdata = {
static int __init sh7343_devices_setup(void)
{
+ platform_resource_setup_memory(&vpu_device, "vpu", 1 << 20);
+ platform_resource_setup_memory(&veu_device, "veu", 2 << 20);
return platform_add_devices(sh7343_devices,
ARRAY_SIZE(sh7343_devices));
}
diff --git a/arch/sh/kernel/cpu/sh4a/setup-sh7366.c b/arch/sh/kernel/cpu/sh4a/setup-sh7366.c
index 2a0fbc3ed9c..7ee01757f3f 100644
--- a/arch/sh/kernel/cpu/sh4a/setup-sh7366.c
+++ b/arch/sh/kernel/cpu/sh4a/setup-sh7366.c
@@ -48,6 +48,9 @@ static struct resource vpu_resources[] = {
.end = 0xfe902807,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device vpu_device = {
@@ -73,6 +76,9 @@ static struct resource veu0_resources[] = {
.end = 0xfe9200b7,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device veu0_device = {
@@ -98,6 +104,9 @@ static struct resource veu1_resources[] = {
.end = 0xfe9240b7,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device veu1_device = {
@@ -139,6 +148,9 @@ static struct platform_device *sh7366_devices[] __initdata = {
static int __init sh7366_devices_setup(void)
{
+ platform_resource_setup_memory(&vpu_device, "vpu", 2 << 20);
+ platform_resource_setup_memory(&veu0_device, "veu0", 2 << 20);
+ platform_resource_setup_memory(&veu1_device, "veu1", 2 << 20);
return platform_add_devices(sh7366_devices,
ARRAY_SIZE(sh7366_devices));
}
diff --git a/arch/sh/kernel/cpu/sh4a/setup-sh7722.c b/arch/sh/kernel/cpu/sh4a/setup-sh7722.c
index 39854d9413c..6015f842eda 100644
--- a/arch/sh/kernel/cpu/sh4a/setup-sh7722.c
+++ b/arch/sh/kernel/cpu/sh4a/setup-sh7722.c
@@ -73,6 +73,9 @@ static struct resource vpu_resources[] = {
.end = 0xfe9022eb,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device vpu_device = {
@@ -98,6 +101,9 @@ static struct resource veu_resources[] = {
.end = 0xfe9200b7,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device veu_device = {
@@ -152,6 +158,8 @@ static struct platform_device *sh7722_devices[] __initdata = {
static int __init sh7722_devices_setup(void)
{
+ platform_resource_setup_memory(&vpu_device, "vpu", 1 << 20);
+ platform_resource_setup_memory(&veu_device, "veu", 2 << 20);
return platform_add_devices(sh7722_devices,
ARRAY_SIZE(sh7722_devices));
}
diff --git a/arch/sh/kernel/cpu/sh4a/setup-sh7723.c b/arch/sh/kernel/cpu/sh4a/setup-sh7723.c
index 1f3137ad013..cb5e6f822e6 100644
--- a/arch/sh/kernel/cpu/sh4a/setup-sh7723.c
+++ b/arch/sh/kernel/cpu/sh4a/setup-sh7723.c
@@ -28,6 +28,9 @@ static struct resource vpu_resources[] = {
.end = 0xfe902807,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device vpu_device = {
@@ -53,6 +56,9 @@ static struct resource veu0_resources[] = {
.end = 0xfe92027b,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device veu0_device = {
@@ -78,6 +84,9 @@ static struct resource veu1_resources[] = {
.end = 0xfe92427b,
.flags = IORESOURCE_MEM,
},
+ [1] = {
+ /* place holder for contiguous memory */
+ },
};
static struct platform_device veu1_device = {
@@ -221,6 +230,9 @@ static struct platform_device *sh7723_devices[] __initdata = {
static int __init sh7723_devices_setup(void)
{
+ platform_resource_setup_memory(&vpu_device, "vpu", 2 << 20);
+ platform_resource_setup_memory(&veu0_device, "veu0", 2 << 20);
+ platform_resource_setup_memory(&veu1_device, "veu1", 2 << 20);
return platform_add_devices(sh7723_devices,
ARRAY_SIZE(sh7723_devices));
}