18c2ecf20Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0-only */
28c2ecf20Sopenharmony_ci/*
38c2ecf20Sopenharmony_ci *   Common address map definitions
48c2ecf20Sopenharmony_ci */
58c2ecf20Sopenharmony_ci
68c2ecf20Sopenharmony_ci#ifndef __ASM_MACH_ADDR_MAP_H
78c2ecf20Sopenharmony_ci#define __ASM_MACH_ADDR_MAP_H
88c2ecf20Sopenharmony_ci
98c2ecf20Sopenharmony_ci/* APB - Application Subsystem Peripheral Bus
108c2ecf20Sopenharmony_ci *
118c2ecf20Sopenharmony_ci * NOTE: the DMA controller registers are actually on the AXI fabric #1
128c2ecf20Sopenharmony_ci * slave port to AHB/APB bridge, due to its close relationship to those
138c2ecf20Sopenharmony_ci * peripherals on APB, let's count it into the ABP mapping area.
148c2ecf20Sopenharmony_ci */
158c2ecf20Sopenharmony_ci#define APB_PHYS_BASE		0xd4000000
168c2ecf20Sopenharmony_ci#define APB_VIRT_BASE		IOMEM(0xfe000000)
178c2ecf20Sopenharmony_ci#define APB_PHYS_SIZE		0x00200000
188c2ecf20Sopenharmony_ci
198c2ecf20Sopenharmony_ci#define AXI_PHYS_BASE		0xd4200000
208c2ecf20Sopenharmony_ci#define AXI_VIRT_BASE		IOMEM(0xfe200000)
218c2ecf20Sopenharmony_ci#define AXI_PHYS_SIZE		0x00200000
228c2ecf20Sopenharmony_ci
238c2ecf20Sopenharmony_ci#define PGU_PHYS_BASE		0xe0000000
248c2ecf20Sopenharmony_ci#define PGU_VIRT_BASE		IOMEM(0xfe400000)
258c2ecf20Sopenharmony_ci#define PGU_PHYS_SIZE		0x00100000
268c2ecf20Sopenharmony_ci
278c2ecf20Sopenharmony_ci/* Static Memory Controller - Chip Select 0 and 1 */
288c2ecf20Sopenharmony_ci#define SMC_CS0_PHYS_BASE	0x80000000
298c2ecf20Sopenharmony_ci#define SMC_CS0_PHYS_SIZE	0x10000000
308c2ecf20Sopenharmony_ci#define SMC_CS1_PHYS_BASE	0x90000000
318c2ecf20Sopenharmony_ci#define SMC_CS1_PHYS_SIZE	0x10000000
328c2ecf20Sopenharmony_ci
338c2ecf20Sopenharmony_ci#define APMU_VIRT_BASE		(AXI_VIRT_BASE + 0x82800)
348c2ecf20Sopenharmony_ci#define APMU_REG(x)		(APMU_VIRT_BASE + (x))
358c2ecf20Sopenharmony_ci
368c2ecf20Sopenharmony_ci#define APBC_VIRT_BASE		(APB_VIRT_BASE + 0x015000)
378c2ecf20Sopenharmony_ci#define APBC_REG(x)		(APBC_VIRT_BASE + (x))
388c2ecf20Sopenharmony_ci
398c2ecf20Sopenharmony_ci#define MPMU_VIRT_BASE		(APB_VIRT_BASE + 0x50000)
408c2ecf20Sopenharmony_ci#define MPMU_REG(x)		(MPMU_VIRT_BASE + (x))
418c2ecf20Sopenharmony_ci
428c2ecf20Sopenharmony_ci#define CIU_VIRT_BASE		(AXI_VIRT_BASE + 0x82c00)
438c2ecf20Sopenharmony_ci#define CIU_REG(x)		(CIU_VIRT_BASE + (x))
448c2ecf20Sopenharmony_ci
458c2ecf20Sopenharmony_ci#define SCU_VIRT_BASE		(PGU_VIRT_BASE)
468c2ecf20Sopenharmony_ci#define SCU_REG(x)		(SCU_VIRT_BASE + (x))
478c2ecf20Sopenharmony_ci
488c2ecf20Sopenharmony_ci#endif /* __ASM_MACH_ADDR_MAP_H */
49