Module Name: src
Committed By: skrll
Date: Wed Sep 25 18:05:39 UTC 2019
Modified Files:
src/sys/arch/arm/broadcom: bcm2835reg.h
Log Message:
Add BCM2838_{PERIPHERALS,ARM_LOCAL}_BASE and support macros
To generate a diff of this commit:
cvs rdiff -u -r1.24 -r1.25 src/sys/arch/arm/broadcom/bcm2835reg.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/sys/arch/arm/broadcom/bcm2835reg.h
diff -u src/sys/arch/arm/broadcom/bcm2835reg.h:1.24 src/sys/arch/arm/broadcom/bcm2835reg.h:1.25
--- src/sys/arch/arm/broadcom/bcm2835reg.h:1.24 Wed Sep 25 18:01:03 2019
+++ src/sys/arch/arm/broadcom/bcm2835reg.h Wed Sep 25 18:05:39 2019
@@ -1,4 +1,4 @@
-/* $NetBSD: bcm2835reg.h,v 1.24 2019/09/25 18:01:03 skrll Exp $ */
+/* $NetBSD: bcm2835reg.h,v 1.25 2019/09/25 18:05:39 skrll Exp $ */
/*-
* Copyright (c) 2012 The NetBSD Foundation, Inc.
@@ -44,11 +44,17 @@
#error Must define SOC_BCM2835 or SOC_BCM2836, and not both
#endif
+#define BCM2838_PERIPHERALS_BASE 0xfe000000
#define BCM2836_PERIPHERALS_BASE 0x3f000000
#define BCM2835_PERIPHERALS_BASE 0x20000000
#define BCM283X_PERIPHERALS_SIZE 0x01000000 /* 16MBytes */
#define BCM283X_PERIPHERALS_BASE_BUS 0x7e000000
+#define BCM2838_PERIPHERALS_PHYS_TO_BUS(a) \
+ ((a) - BCM2838_PERIPHERALS_BASE + BCM283X_PERIPHERALS_BASE_BUS)
+#define BCM2838_PERIPHERALS_BUS_TO_PHYS(a) \
+ ((a) - BCM283X_PERIPHERALS_BASE_BUS + BCM2838_PERIPHERALS_BASE)
+
#define BCM2836_PERIPHERALS_PHYS_TO_BUS(a) \
((a) - BCM2836_PERIPHERALS_BASE + BCM283X_PERIPHERALS_BASE_BUS)
#define BCM2836_PERIPHERALS_BUS_TO_PHYS(a) \
@@ -206,6 +212,9 @@
#define BCM2835_UART0_CLK 3000000
+#define BCM2838_ARM_LOCAL_BASE 0xff800000
+#define BCM2838_ARM_LOCAL_SIZE 0x00100000 /* 1MByte */
+
#define BCM2836_ARM_LOCAL_BASE 0x40000000
#define BCM2836_ARM_LOCAL_SIZE 0x00001000 /* 4KBytes */