/* * include/asm/arch/memory.h * * Copyright (C) 2012 MStar Semiconductor. * * This program is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation; either version 2 of the License, or * (at your option) any later version. * * This program is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with this program; if not, write to the Free Software Foundation, * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA */ #ifndef __ASM_ARCH_MEMORY_H #define __ASM_ARCH_MEMORY_H #include #define PHYS_OFFSET (SDRAM_BASE) #define PAGE_OFFSET 0xc0000000 #define __virt_to_phys__is_a_macro #define __phys_to_virt__is_a_macro #define __virt_to_phys__is_a_macro #define __phys_to_virt__is_a_macro #define __virt_to_phys(vpage) (vpage - PAGE_OFFSET + PHYS_OFFSET) #define __phys_to_virt(ppage) (ppage - PHYS_OFFSET + PAGE_OFFSET) #define __virt_to_bus__is_a_macro #define __bus_to_virt__is_a_macro #define __virt_to_bus(x) __virt_to_phys(x) #define __bus_to_virt(x) __phys_to_virt(x) #endif /* __ASM_ARCH_MEMORY_H */