patch-2.4.0-test3 linux/include/asm-arm/memory.h

Next file: linux/include/asm-arm/proc-armo/system.h
Previous file: linux/include/asm-arm/io.h
Back to the patch index
Back to the overall index

diff -u --recursive --new-file v2.4.0-test2/linux/include/asm-arm/memory.h linux/include/asm-arm/memory.h
@@ -0,0 +1,31 @@
+/*
+ * linux/include/asm-arm/memory.h
+ *
+ * Copyright (C) 2000 Russell King
+ *
+ * Note: this file should not be included by non-asm/.h files
+ *
+ * Modifications:
+ */
+#ifndef __ASM_ARM_MEMORY_H
+#define __ASM_ARM_MEMORY_H
+
+#include <asm/arch/memory.h>
+
+extern __inline__ unsigned long virt_to_phys(volatile void *x)
+{
+	return __virt_to_phys((unsigned long)(x));
+}
+
+extern __inline__ void *phys_to_virt(unsigned long x)
+{
+	return (void *)(__phys_to_virt((unsigned long)(x)));
+}
+
+/*
+ * Virtual <-> DMA view memory address translations
+ */
+#define virt_to_bus(x)		(__virt_to_bus((unsigned long)(x)))
+#define bus_to_virt(x)		((void *)(__bus_to_virt((unsigned long)(x))))
+
+#endif

FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)