s/2835/283X/ in BCM2835_PERIPHERALS_BASE_BUS and BCM2835_PERIPHERALS_SIZE
to show they cover all of 283[5678] NFCI
This commit is contained in:
parent
9047d4ec1f
commit
586dde2b6f
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: bcm2835reg.h,v 1.23 2018/09/10 11:05:12 ryo Exp $ */
|
||||
/* $NetBSD: bcm2835reg.h,v 1.24 2019/09/25 18:01:03 skrll Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2012 The NetBSD Foundation, Inc.
|
||||
|
@ -46,40 +46,40 @@
|
|||
|
||||
#define BCM2836_PERIPHERALS_BASE 0x3f000000
|
||||
#define BCM2835_PERIPHERALS_BASE 0x20000000
|
||||
#define BCM2835_PERIPHERALS_SIZE 0x01000000 /* 16MBytes */
|
||||
#define BCM2835_PERIPHERALS_BASE_BUS 0x7e000000
|
||||
#define BCM283X_PERIPHERALS_SIZE 0x01000000 /* 16MBytes */
|
||||
#define BCM283X_PERIPHERALS_BASE_BUS 0x7e000000
|
||||
|
||||
#define BCM2836_PERIPHERALS_PHYS_TO_BUS(a) \
|
||||
((a) - BCM2836_PERIPHERALS_BASE + BCM2835_PERIPHERALS_BASE_BUS)
|
||||
((a) - BCM2836_PERIPHERALS_BASE + BCM283X_PERIPHERALS_BASE_BUS)
|
||||
#define BCM2836_PERIPHERALS_BUS_TO_PHYS(a) \
|
||||
((a) - BCM2835_PERIPHERALS_BASE_BUS + BCM2836_PERIPHERALS_BASE)
|
||||
((a) - BCM283X_PERIPHERALS_BASE_BUS + BCM2836_PERIPHERALS_BASE)
|
||||
|
||||
#define BCM2835_PERIPHERALS_PHYS_TO_BUS(a) \
|
||||
((a) - BCM2835_PERIPHERALS_BASE + BCM2835_PERIPHERALS_BASE_BUS)
|
||||
((a) - BCM2835_PERIPHERALS_BASE + BCM283X_PERIPHERALS_BASE_BUS)
|
||||
#define BCM2835_PERIPHERALS_BUS_TO_PHYS(a) \
|
||||
((a) - BCM2835_PERIPHERALS_BASE_BUS + BCM2835_PERIPHERALS_BASE)
|
||||
((a) - BCM283X_PERIPHERALS_BASE_BUS + BCM2835_PERIPHERALS_BASE)
|
||||
|
||||
#define BCM2835_STIMER_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00003000)
|
||||
#define BCM2835_DMA0_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00007000)
|
||||
#define BCM2835_ARM_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x0000B000)
|
||||
#define BCM2835_PM_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00100000)
|
||||
#define BCM2835_CM_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00101000)
|
||||
#define BCM2835_RNG_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00104000)
|
||||
#define BCM2835_GPIO_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00200000)
|
||||
#define BCM2835_UART0_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00201000)
|
||||
#define BCM2835_SDHOST_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00202000)
|
||||
#define BCM2835_PCM_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00203000)
|
||||
#define BCM2835_SPI0_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00204000)
|
||||
#define BCM2835_BSC0_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00205000)
|
||||
#define BCM2835_PWM_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x0020C000)
|
||||
#define BCM2835_BSCSPISLV_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00214000)
|
||||
#define BCM2835_AUX_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00215000)
|
||||
#define BCM2835_AUX_UART_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00215040)
|
||||
#define BCM2835_EMMC_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00300000)
|
||||
#define BCM2835_BSC1_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00804000)
|
||||
#define BCM2835_BSC2_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00805000)
|
||||
#define BCM2835_USB_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00980000)
|
||||
#define BCM2835_DMA15_BASE (BCM2835_PERIPHERALS_BASE_BUS + 0x00E05000)
|
||||
#define BCM2835_STIMER_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00003000)
|
||||
#define BCM2835_DMA0_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00007000)
|
||||
#define BCM2835_ARM_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x0000B000)
|
||||
#define BCM2835_PM_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00100000)
|
||||
#define BCM2835_CM_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00101000)
|
||||
#define BCM2835_RNG_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00104000)
|
||||
#define BCM2835_GPIO_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00200000)
|
||||
#define BCM2835_UART0_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00201000)
|
||||
#define BCM2835_SDHOST_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00202000)
|
||||
#define BCM2835_PCM_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00203000)
|
||||
#define BCM2835_SPI0_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00204000)
|
||||
#define BCM2835_BSC0_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00205000)
|
||||
#define BCM2835_PWM_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x0020C000)
|
||||
#define BCM2835_BSCSPISLV_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00214000)
|
||||
#define BCM2835_AUX_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00215000)
|
||||
#define BCM2835_AUX_UART_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00215040)
|
||||
#define BCM2835_EMMC_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00300000)
|
||||
#define BCM2835_BSC1_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00804000)
|
||||
#define BCM2835_BSC2_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00805000)
|
||||
#define BCM2835_USB_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00980000)
|
||||
#define BCM2835_DMA15_BASE (BCM283X_PERIPHERALS_BASE_BUS + 0x00E05000)
|
||||
|
||||
#define BCM2835_STIMER_SIZE 0x1c
|
||||
#define BCM2835_DMA0_SIZE 0x1000
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
/* $NetBSD: bcm283x_platform.c,v 1.23 2019/01/03 12:52:40 jmcneill Exp $ */
|
||||
/* $NetBSD: bcm283x_platform.c,v 1.24 2019/09/25 18:01:03 skrll Exp $ */
|
||||
|
||||
/*-
|
||||
* Copyright (c) 2017 Jared D. McNeill <jmcneill@invisible.ca>
|
||||
|
@ -27,7 +27,7 @@
|
|||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: bcm283x_platform.c,v 1.23 2019/01/03 12:52:40 jmcneill Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: bcm283x_platform.c,v 1.24 2019/09/25 18:01:03 skrll Exp $");
|
||||
|
||||
#include "opt_arm_debug.h"
|
||||
#include "opt_bcm283x.h"
|
||||
|
@ -149,8 +149,8 @@ bcm2835_bus_to_phys(bus_addr_t ba)
|
|||
{
|
||||
|
||||
/* Attempt to find the PA device mapping */
|
||||
if (ba >= BCM2835_PERIPHERALS_BASE_BUS &&
|
||||
ba < BCM2835_PERIPHERALS_BASE_BUS + BCM2835_PERIPHERALS_SIZE)
|
||||
if (ba >= BCM283X_PERIPHERALS_BASE_BUS &&
|
||||
ba < BCM283X_PERIPHERALS_BASE_BUS + BCM283X_PERIPHERALS_SIZE)
|
||||
return BCM2835_PERIPHERALS_BUS_TO_PHYS(ba);
|
||||
|
||||
return ba & ~BCM2835_BUSADDR_CACHE_MASK;
|
||||
|
@ -161,8 +161,8 @@ bcm2836_bus_to_phys(bus_addr_t ba)
|
|||
{
|
||||
|
||||
/* Attempt to find the PA device mapping */
|
||||
if (ba >= BCM2835_PERIPHERALS_BASE_BUS &&
|
||||
ba < BCM2835_PERIPHERALS_BASE_BUS + BCM2835_PERIPHERALS_SIZE)
|
||||
if (ba >= BCM283X_PERIPHERALS_BASE_BUS &&
|
||||
ba < BCM283X_PERIPHERALS_BASE_BUS + BCM283X_PERIPHERALS_SIZE)
|
||||
return BCM2836_PERIPHERALS_BUS_TO_PHYS(ba);
|
||||
|
||||
if (ba >= BCM2836_ARM_LOCAL_BASE &&
|
||||
|
@ -241,7 +241,7 @@ bcm2835_platform_devmap(void)
|
|||
{
|
||||
static const struct pmap_devmap devmap[] = {
|
||||
DEVMAP_ENTRY(BCM2835_PERIPHERALS_VBASE, BCM2835_PERIPHERALS_BASE,
|
||||
BCM2835_PERIPHERALS_SIZE), /* 16Mb */
|
||||
BCM283X_PERIPHERALS_SIZE), /* 16Mb */
|
||||
|
||||
DEVMAP_ENTRY_END
|
||||
};
|
||||
|
@ -256,7 +256,7 @@ bcm2836_platform_devmap(void)
|
|||
{
|
||||
static const struct pmap_devmap devmap[] = {
|
||||
DEVMAP_ENTRY(BCM2836_PERIPHERALS_VBASE, BCM2836_PERIPHERALS_BASE,
|
||||
BCM2835_PERIPHERALS_SIZE), /* 16Mb */
|
||||
BCM283X_PERIPHERALS_SIZE), /* 16Mb */
|
||||
|
||||
DEVMAP_ENTRY(BCM2836_ARM_LOCAL_VBASE, BCM2836_ARM_LOCAL_BASE,
|
||||
BCM2836_ARM_LOCAL_SIZE),
|
||||
|
|
Loading…
Reference in New Issue