rk: plat: add memory.h

This commit is contained in:
黄涛
2012-07-03 10:20:19 +08:00
parent a93d6edd37
commit 333872c371
2 changed files with 17 additions and 11 deletions

View File

@@ -1,14 +1,9 @@
#ifndef __MACH_MEMORY_H
#define __MACH_MEMORY_H
#include <linux/version.h>
#include <plat/memory.h>
#include <mach/io.h>
/*
* Physical DRAM offset.
*/
#define PLAT_PHYS_OFFSET UL(0x60000000)
/*
* SRAM memory whereabouts
*/
@@ -17,9 +12,4 @@
#define SRAM_DATA_OFFSET (RK30_IMEM_BASE + 0x3000)
#define SRAM_DATA_END (RK30_IMEM_BASE + 0x3FFF)
#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

@@ -0,0 +1,16 @@
#ifndef __PLAT_MEMORY_H
#define __PLAT_MEMORY_H
#include <linux/version.h>
/*
* Physical DRAM offset.
*/
#define PLAT_PHYS_OFFSET UL(0x60000000)
#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