rk30: port ipp

This commit is contained in:
黄涛
2012-02-23 16:57:25 +08:00
parent 53549aa4a1
commit 88db6073b8
4 changed files with 35 additions and 2 deletions

View File

@@ -0,0 +1 @@
#include <plat/ipp.h>

View File

@@ -745,6 +745,28 @@ static struct platform_device device_rga = {
};
#endif
#ifdef CONFIG_RK29_IPP
static struct resource resource_ipp[] = {
[0] = {
.start = RK30_IPP_PHYS,
.end = RK30_IPP_PHYS + RK30_IPP_SIZE - 1,
.flags = IORESOURCE_MEM,
},
[1] = {
.start = IRQ_IPP,
.end = IRQ_IPP,
.flags = IORESOURCE_IRQ,
},
};
static struct platform_device device_ipp = {
.name = "rk29-ipp",
.id = -1,
.num_resources = ARRAY_SIZE(resource_ipp),
.resource = resource_ipp,
};
#endif
#ifdef CONFIG_KEYS_RK29
extern struct rk29_keys_platform_data rk29_keys_pdata;
static struct platform_device device_keys = {
@@ -771,6 +793,9 @@ static int __init rk30_init_devices(void)
#ifdef CONFIG_RGA_RK30
platform_device_register(&device_rga);
#endif
#ifdef CONFIG_RK29_IPP
platform_device_register(&device_ipp);
#endif
#ifdef CONFIG_LCDC_RK30
platform_device_register(&device_lcdc);
#endif

View File

@@ -1,6 +1,8 @@
#ifndef __MACH_MEMORY_H
#define __MACH_MEMORY_H
#include <linux/version.h>
/*
* Physical DRAM offset.
*/
@@ -14,4 +16,9 @@
#define SRAM_DATA_OFFSET 0xFEF03000
#define SRAM_DATA_END 0xFEF03FFF
#if (LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 34))
#define dmac_clean_range(start, end) dmac_map_area(start, end - start, DMA_TO_DEVICE)
#define dmac_inv_range(start, end) dmac_unmap_area(start, end - start, DMA_FROM_DEVICE)
#endif
#endif

View File

@@ -27,7 +27,7 @@
#include <asm/io.h>
#include <linux/irq.h>
#include <linux/interrupt.h>
#include <mach/rk29_iomap.h>
#include <mach/io.h>
#include <mach/irqs.h>
#include <linux/fs.h>
#include <asm/uaccess.h>
@@ -38,7 +38,7 @@
#include <linux/wait.h>
#include <linux/syscalls.h>
#include <linux/timer.h>
#include <mach/rk29-ipp.h>
#include <plat/ipp.h>
#include <linux/time.h>
#include <asm/cacheflush.h>
#include <linux/slab.h>