rk: plat: add memory.h
author黄涛 <huangtao@rock-chips.com>
Tue, 3 Jul 2012 02:20:19 +0000 (10:20 +0800)
committer黄涛 <huangtao@rock-chips.com>
Tue, 3 Jul 2012 02:20:28 +0000 (10:20 +0800)
arch/arm/mach-rk30/include/mach/memory.h
arch/arm/plat-rk/include/plat/memory.h [new file with mode: 0644]

index ab0b7fc032b26c463ad3d467afefa256d621a7fb..01d8387e106ad609226b3fc90c625ca3a46af895 100644 (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
diff --git a/arch/arm/plat-rk/include/plat/memory.h b/arch/arm/plat-rk/include/plat/memory.h
new file mode 100644 (file)
index 0000000..be59d3b
--- /dev/null
@@ -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