mirror of
https://github.com/u-boot/u-boot.git
synced 2025-01-24 03:33:28 +08:00
Merge git://git.denx.de/u-boot-dm
This commit is contained in:
commit
757566d156
22
Kconfig
22
Kconfig
@ -56,6 +56,25 @@ config CC_OPTIMIZE_FOR_SIZE
|
||||
|
||||
This option is enabled by default for U-Boot.
|
||||
|
||||
config SYS_MALLOC_F
|
||||
bool "Enable malloc() pool before relocation"
|
||||
default 0x400
|
||||
help
|
||||
Before relocation memory is very limited on many platforms. Still,
|
||||
we can provide a small malloc() pool if needed. Driver model in
|
||||
particular needs this to operate, so that it can allocate the
|
||||
initial serial device and any others that are needed.
|
||||
|
||||
config SYS_MALLOC_F_LEN
|
||||
hex "Size of malloc() pool before relocation"
|
||||
depends on SYS_MALLOC_F
|
||||
default 0x400
|
||||
help
|
||||
Before relocation memory is very limited on many platforms. Still,
|
||||
we can provide a small malloc() pool if needed. Driver model in
|
||||
particular needs this to operate, so that it can allocate the
|
||||
initial serial device and any others that are needed.
|
||||
|
||||
menuconfig EXPERT
|
||||
bool "Configure standard U-Boot features (expert users)"
|
||||
help
|
||||
@ -118,6 +137,7 @@ config FIT_VERBOSE
|
||||
config FIT_SIGNATURE
|
||||
bool "Enable signature verification of FIT uImages"
|
||||
depends on FIT
|
||||
depends on DM
|
||||
select RSA
|
||||
help
|
||||
This option enables signature verification of FIT uImages,
|
||||
@ -165,3 +185,5 @@ source "drivers/Kconfig"
|
||||
source "fs/Kconfig"
|
||||
|
||||
source "lib/Kconfig"
|
||||
|
||||
source "test/Kconfig"
|
||||
|
@ -40,6 +40,7 @@ config OPENRISC
|
||||
config PPC
|
||||
bool "PowerPC architecture"
|
||||
select HAVE_PRIVATE_LIBGCC
|
||||
select SUPPORT_OF_CONTROL
|
||||
|
||||
config SANDBOX
|
||||
bool "Sandbox"
|
||||
|
@ -839,6 +839,8 @@ endchoice
|
||||
|
||||
source "arch/arm/cpu/arm926ejs/davinci/Kconfig"
|
||||
|
||||
source "arch/arm/cpu/arm1176/bcm2835/Kconfig"
|
||||
|
||||
source "arch/arm/cpu/armv7/exynos/Kconfig"
|
||||
|
||||
source "arch/arm/cpu/armv7/highbank/Kconfig"
|
||||
|
12
arch/arm/cpu/arm1176/bcm2835/Kconfig
Normal file
12
arch/arm/cpu/arm1176/bcm2835/Kconfig
Normal file
@ -0,0 +1,12 @@
|
||||
if TARGET_RPI
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
endif
|
@ -65,6 +65,27 @@ endchoice
|
||||
config SYS_SOC
|
||||
default "exynos"
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SPI
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SPI_FLASH
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config SYS_MALLOC_F
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config SYS_MALLOC_F_LEN
|
||||
default 0x400 if !SPL_BUILD
|
||||
|
||||
source "board/samsung/smdkv310/Kconfig"
|
||||
source "board/samsung/trats/Kconfig"
|
||||
source "board/samsung/universal_c210/Kconfig"
|
||||
|
@ -93,6 +93,21 @@ config TARGET_TWISTER
|
||||
|
||||
endchoice
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if DM && !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if DM && !SPL_BUILD
|
||||
|
||||
config SYS_MALLOC_F
|
||||
default y if DM && !SPL_BUILD
|
||||
|
||||
config SYS_MALLOC_F_LEN
|
||||
default 0x400 if DM && !SPL_BUILD
|
||||
|
||||
config SYS_SOC
|
||||
default "omap3"
|
||||
|
||||
|
@ -17,9 +17,33 @@ config TEGRA124
|
||||
|
||||
endchoice
|
||||
|
||||
config SYS_MALLOC_F
|
||||
default y
|
||||
|
||||
config SYS_MALLOC_F_LEN
|
||||
default 0x1800
|
||||
|
||||
config USE_PRIVATE_LIBGCC
|
||||
default y if SPL_BUILD
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SPI
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SPI_FLASH
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_I2C
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
source "arch/arm/cpu/armv7/tegra20/Kconfig"
|
||||
source "arch/arm/cpu/armv7/tegra30/Kconfig"
|
||||
source "arch/arm/cpu/armv7/tegra114/Kconfig"
|
||||
|
@ -48,6 +48,12 @@ config DCC_MICRO_SUPPORT_CARD
|
||||
|
||||
endchoice
|
||||
|
||||
config SYS_MALLOC_F
|
||||
default y
|
||||
|
||||
config SYS_MALLOC_F_LEN
|
||||
default 0x2000
|
||||
|
||||
config CMD_PINMON
|
||||
bool "Enable boot mode pins monitor command"
|
||||
default y
|
||||
|
@ -114,14 +114,10 @@ typedef union at91_pio {
|
||||
at91_port_t pioa;
|
||||
at91_port_t piob;
|
||||
at91_port_t pioc;
|
||||
#if (ATMEL_PIO_PORTS > 3)
|
||||
at91_port_t piod;
|
||||
#endif
|
||||
#if (ATMEL_PIO_PORTS > 4)
|
||||
at91_port_t pioe;
|
||||
#endif
|
||||
} ;
|
||||
at91_port_t port[ATMEL_PIO_PORTS];
|
||||
at91_port_t piod; /* not present in all hardware */
|
||||
at91_port_t pioe;/* not present in all hardware */
|
||||
};
|
||||
at91_port_t port[5];
|
||||
} at91_pio_t;
|
||||
|
||||
#ifdef CONFIG_AT91_GPIO
|
||||
|
@ -424,6 +424,14 @@ phys_size_t initdram(int board_type)
|
||||
int write_recovery;
|
||||
phys_size_t dram_size = 0;
|
||||
|
||||
if (IS_ENABLED(CONFIG_SYS_RAMBOOT)) {
|
||||
/*
|
||||
* Reduce RAM size to avoid overwriting memory used by
|
||||
* current stack? Not sure what is happening.
|
||||
*/
|
||||
return sdram_memsize() / 2;
|
||||
}
|
||||
|
||||
num_dimm_banks = sizeof(iic0_dimm_addr);
|
||||
|
||||
/*------------------------------------------------------------------
|
||||
|
@ -7,10 +7,7 @@
|
||||
|
||||
PLATFORM_CPPFLAGS += -mstring -msoft-float
|
||||
|
||||
cfg=$(srctree)/include/configs/$(CONFIG_SYS_CONFIG_NAME:"%"=%).h
|
||||
is440:=$(shell grep CONFIG_440 $(cfg))
|
||||
|
||||
ifneq (,$(findstring CONFIG_440,$(is440)))
|
||||
ifneq (,$(CONFIG_440))
|
||||
PLATFORM_CPPFLAGS += -Wa,-m440 -mcpu=440
|
||||
else
|
||||
PLATFORM_CPPFLAGS += -Wa,-m405 -mcpu=405
|
||||
|
@ -450,10 +450,12 @@ cpu_init_f (void)
|
||||
PLB4Ax_ACR_RDP_4DEEP);
|
||||
#endif /* CONFIG_440SP/SPE || CONFIG_460EX/GT || CONFIG_405EX */
|
||||
|
||||
#ifndef CONFIG_SYS_GENERIC_BOARD
|
||||
gd = (gd_t *)(CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_GBL_DATA_OFFSET);
|
||||
|
||||
/* Clear initial global data */
|
||||
memset((void *)gd, 0, sizeof(gd_t));
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -760,6 +760,15 @@ _start:
|
||||
#endif
|
||||
|
||||
bl cpu_init_f /* run low-level CPU init code (from Flash) */
|
||||
#ifdef CONFIG_SYS_GENERIC_BOARD
|
||||
mr r3, r1
|
||||
bl board_init_f_mem
|
||||
mr r1, r3
|
||||
li r0,0
|
||||
stwu r0, -4(r1)
|
||||
stwu r0, -4(r1)
|
||||
#endif
|
||||
li r3, 0
|
||||
bl board_init_f
|
||||
/* NOTREACHED - board_init_f() does not return */
|
||||
|
||||
@ -1027,7 +1036,14 @@ _start:
|
||||
GET_GOT /* initialize GOT access */
|
||||
|
||||
bl cpu_init_f /* run low-level CPU init code (from Flash) */
|
||||
|
||||
#ifdef CONFIG_SYS_GENERIC_BOARD
|
||||
mr r3, r1
|
||||
bl board_init_f_mem
|
||||
mr r1, r3
|
||||
stwu r0, -4(r1)
|
||||
stwu r0, -4(r1)
|
||||
#endif
|
||||
li r3, 0
|
||||
bl board_init_f /* run first part of init code (from Flash) */
|
||||
/* NOTREACHED - board_init_f() does not return */
|
||||
|
||||
|
@ -76,9 +76,13 @@ SECTIONS
|
||||
. = ALIGN(256);
|
||||
__init_begin = .;
|
||||
.text.init : { *(.text.init) }
|
||||
.data.init : { *(.data.init) }
|
||||
. = ALIGN(256);
|
||||
.data.init : {
|
||||
*(.data.init)
|
||||
. = ALIGN(256);
|
||||
LONG(0) LONG(0) /* Extend u-boot.bin to here */
|
||||
}
|
||||
__init_end = .;
|
||||
_end = .;
|
||||
|
||||
#ifndef CONFIG_SPL
|
||||
#ifdef CONFIG_440
|
||||
|
11
arch/powerpc/dts/Makefile
Normal file
11
arch/powerpc/dts/Makefile
Normal file
@ -0,0 +1,11 @@
|
||||
dtb-$(CONFIG_TARGET_CANYONLANDS) += arches.dtb canyonlands.dtb glacier.dtb
|
||||
|
||||
targets += $(dtb-y)
|
||||
|
||||
DTC_FLAGS += -R 4 -p 0x1000
|
||||
|
||||
PHONY += dtbs
|
||||
dtbs: $(addprefix $(obj)/, $(dtb-y))
|
||||
@:
|
||||
|
||||
clean-files := *.dtb
|
339
arch/powerpc/dts/arches.dts
Normal file
339
arch/powerpc/dts/arches.dts
Normal file
@ -0,0 +1,339 @@
|
||||
/*
|
||||
* Device Tree Source for AMCC Arches (dual 460GT board)
|
||||
*
|
||||
* (C) Copyright 2008 Applied Micro Circuits Corporation
|
||||
* Victor Gallardo <vgallardo@amcc.com>
|
||||
* Adam Graham <agraham@amcc.com>
|
||||
*
|
||||
* Based on the glacier.dts file
|
||||
* Stefan Roese <sr@denx.de>
|
||||
* Copyright 2008 DENX Software Engineering
|
||||
*
|
||||
* SPDX-License-Identifier: GPL-2.0+
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
/ {
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
model = "amcc,arches";
|
||||
compatible = "amcc,arches";
|
||||
dcr-parent = <&{/cpus/cpu@0}>;
|
||||
|
||||
aliases {
|
||||
ethernet0 = &EMAC0;
|
||||
ethernet1 = &EMAC1;
|
||||
ethernet2 = &EMAC2;
|
||||
serial0 = &UART0;
|
||||
};
|
||||
|
||||
cpus {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
cpu@0 {
|
||||
device_type = "cpu";
|
||||
model = "PowerPC,460GT";
|
||||
reg = <0x00000000>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
timebase-frequency = <0>; /* Filled in by U-Boot */
|
||||
i-cache-line-size = <32>;
|
||||
d-cache-line-size = <32>;
|
||||
i-cache-size = <32768>;
|
||||
d-cache-size = <32768>;
|
||||
dcr-controller;
|
||||
dcr-access-method = "native";
|
||||
next-level-cache = <&L2C0>;
|
||||
};
|
||||
};
|
||||
|
||||
memory {
|
||||
device_type = "memory";
|
||||
reg = <0x00000000 0x00000000 0x00000000>; /* Filled in by U-Boot */
|
||||
};
|
||||
|
||||
UIC0: interrupt-controller0 {
|
||||
compatible = "ibm,uic-460gt","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <0>;
|
||||
dcr-reg = <0x0c0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
};
|
||||
|
||||
UIC1: interrupt-controller1 {
|
||||
compatible = "ibm,uic-460gt","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <1>;
|
||||
dcr-reg = <0x0d0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0x1e 0x4 0x1f 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
UIC2: interrupt-controller2 {
|
||||
compatible = "ibm,uic-460gt","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <2>;
|
||||
dcr-reg = <0x0e0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0xa 0x4 0xb 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
UIC3: interrupt-controller3 {
|
||||
compatible = "ibm,uic-460gt","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <3>;
|
||||
dcr-reg = <0x0f0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0x10 0x4 0x11 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
SDR0: sdr {
|
||||
compatible = "ibm,sdr-460gt";
|
||||
dcr-reg = <0x00e 0x002>;
|
||||
};
|
||||
|
||||
CPR0: cpr {
|
||||
compatible = "ibm,cpr-460gt";
|
||||
dcr-reg = <0x00c 0x002>;
|
||||
};
|
||||
|
||||
L2C0: l2c {
|
||||
compatible = "ibm,l2-cache-460gt", "ibm,l2-cache";
|
||||
dcr-reg = <0x020 0x008 /* Internal SRAM DCR's */
|
||||
0x030 0x008>; /* L2 cache DCR's */
|
||||
cache-line-size = <32>; /* 32 bytes */
|
||||
cache-size = <262144>; /* L2, 256K */
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <11 1>;
|
||||
};
|
||||
|
||||
plb {
|
||||
compatible = "ibm,plb-460gt", "ibm,plb4";
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
ranges;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
|
||||
SDRAM0: sdram {
|
||||
compatible = "ibm,sdram-460gt", "ibm,sdram-405gp";
|
||||
dcr-reg = <0x010 0x002>;
|
||||
};
|
||||
|
||||
CRYPTO: crypto@180000 {
|
||||
compatible = "amcc,ppc460gt-crypto", "amcc,ppc4xx-crypto";
|
||||
reg = <4 0x00180000 0x80400>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x1d 0x4>;
|
||||
};
|
||||
|
||||
MAL0: mcmal {
|
||||
compatible = "ibm,mcmal-460gt", "ibm,mcmal2";
|
||||
dcr-reg = <0x180 0x062>;
|
||||
num-tx-chans = <3>;
|
||||
num-rx-chans = <24>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-parent = <&UIC2>;
|
||||
interrupts = < /*TXEOB*/ 0x6 0x4
|
||||
/*RXEOB*/ 0x7 0x4
|
||||
/*SERR*/ 0x3 0x4
|
||||
/*TXDE*/ 0x4 0x4
|
||||
/*RXDE*/ 0x5 0x4>;
|
||||
desc-base-addr-high = <0x8>;
|
||||
};
|
||||
|
||||
POB0: opb {
|
||||
compatible = "ibm,opb-460gt", "ibm,opb";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
ranges = <0xb0000000 0x00000004 0xb0000000 0x50000000>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
|
||||
EBC0: ebc {
|
||||
compatible = "ibm,ebc-460gt", "ibm,ebc";
|
||||
dcr-reg = <0x012 0x002>;
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
/* ranges property is supplied by U-Boot */
|
||||
interrupts = <0x6 0x4>;
|
||||
interrupt-parent = <&UIC1>;
|
||||
|
||||
nor_flash@0,0 {
|
||||
compatible = "amd,s29gl256n", "cfi-flash";
|
||||
bank-width = <2>;
|
||||
reg = <0x00000000 0x00000000 0x02000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
partition@0 {
|
||||
label = "kernel";
|
||||
reg = <0x00000000 0x001e0000>;
|
||||
};
|
||||
partition@1e0000 {
|
||||
label = "dtb";
|
||||
reg = <0x001e0000 0x00020000>;
|
||||
};
|
||||
partition@200000 {
|
||||
label = "root";
|
||||
reg = <0x00200000 0x00200000>;
|
||||
};
|
||||
partition@400000 {
|
||||
label = "user";
|
||||
reg = <0x00400000 0x01b60000>;
|
||||
};
|
||||
partition@1f60000 {
|
||||
label = "env";
|
||||
reg = <0x01f60000 0x00040000>;
|
||||
};
|
||||
partition@1fa0000 {
|
||||
label = "u-boot";
|
||||
reg = <0x01fa0000 0x00060000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
UART0: serial@ef600300 {
|
||||
device_type = "serial";
|
||||
compatible = "ns16550";
|
||||
reg = <0xef600300 0x00000008>;
|
||||
virtual-reg = <0xef600300>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
current-speed = <0>; /* Filled in by U-Boot */
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <0x1 0x4>;
|
||||
};
|
||||
|
||||
IIC0: i2c@ef600700 {
|
||||
compatible = "ibm,iic-460gt", "ibm,iic";
|
||||
reg = <0xef600700 0x00000014>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x2 0x4>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
sttm@4a {
|
||||
compatible = "ad,ad7414";
|
||||
reg = <0x4a>;
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <0x0 0x8>;
|
||||
};
|
||||
};
|
||||
|
||||
IIC1: i2c@ef600800 {
|
||||
compatible = "ibm,iic-460gt", "ibm,iic";
|
||||
reg = <0xef600800 0x00000014>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x3 0x4>;
|
||||
};
|
||||
|
||||
TAH0: emac-tah@ef601350 {
|
||||
compatible = "ibm,tah-460gt", "ibm,tah";
|
||||
reg = <0xef601350 0x00000030>;
|
||||
};
|
||||
|
||||
TAH1: emac-tah@ef601450 {
|
||||
compatible = "ibm,tah-460gt", "ibm,tah";
|
||||
reg = <0xef601450 0x00000030>;
|
||||
};
|
||||
|
||||
EMAC0: ethernet@ef600e00 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460gt", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC0>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x10 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x14 0x4>;
|
||||
reg = <0xef600e00 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <0>;
|
||||
mal-rx-channel = <0>;
|
||||
cell-index = <0>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
phy-mode = "sgmii";
|
||||
phy-map = <0xffffffff>;
|
||||
gpcs-address = <0x0000000a>;
|
||||
tah-device = <&TAH0>;
|
||||
tah-channel = <0>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
};
|
||||
|
||||
EMAC1: ethernet@ef600f00 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460gt", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC1>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x11 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x15 0x4>;
|
||||
reg = <0xef600f00 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <1>;
|
||||
mal-rx-channel = <8>;
|
||||
cell-index = <1>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
phy-mode = "sgmii";
|
||||
phy-map = <0x00000000>;
|
||||
gpcs-address = <0x0000000b>;
|
||||
tah-device = <&TAH1>;
|
||||
tah-channel = <1>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
mdio-device = <&EMAC0>;
|
||||
};
|
||||
|
||||
EMAC2: ethernet@ef601100 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460gt", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC2>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x12 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x16 0x4>;
|
||||
reg = <0xef601100 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <2>;
|
||||
mal-rx-channel = <16>;
|
||||
cell-index = <2>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
tx-fifo-size-gige = <16384>; /* emac2&3 only */
|
||||
phy-mode = "sgmii";
|
||||
phy-map = <0x00000001>;
|
||||
gpcs-address = <0x0000000C>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
mdio-device = <&EMAC0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
561
arch/powerpc/dts/canyonlands.dts
Normal file
561
arch/powerpc/dts/canyonlands.dts
Normal file
@ -0,0 +1,561 @@
|
||||
/*
|
||||
* Device Tree Source for AMCC Canyonlands (460EX)
|
||||
*
|
||||
* Copyright 2008-2009 DENX Software Engineering, Stefan Roese <sr@denx.de>
|
||||
*
|
||||
* SPDX-License-Identifier: GPL-2.0
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
/ {
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
model = "amcc,canyonlands";
|
||||
compatible = "amcc,canyonlands";
|
||||
dcr-parent = <&{/cpus/cpu@0}>;
|
||||
|
||||
aliases {
|
||||
ethernet0 = &EMAC0;
|
||||
ethernet1 = &EMAC1;
|
||||
serial0 = &UART0;
|
||||
serial1 = &UART1;
|
||||
};
|
||||
|
||||
chosen {
|
||||
stdout-path = &UART0;
|
||||
};
|
||||
|
||||
cpus {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
cpu@0 {
|
||||
device_type = "cpu";
|
||||
model = "PowerPC,460EX";
|
||||
reg = <0x00000000>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
timebase-frequency = <0>; /* Filled in by U-Boot */
|
||||
i-cache-line-size = <32>;
|
||||
d-cache-line-size = <32>;
|
||||
i-cache-size = <32768>;
|
||||
d-cache-size = <32768>;
|
||||
dcr-controller;
|
||||
dcr-access-method = "native";
|
||||
next-level-cache = <&L2C0>;
|
||||
};
|
||||
};
|
||||
|
||||
memory {
|
||||
device_type = "memory";
|
||||
reg = <0x00000000 0x00000000 0x00000000>; /* Filled in by U-Boot */
|
||||
};
|
||||
|
||||
UIC0: interrupt-controller0 {
|
||||
compatible = "ibm,uic-460ex","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <0>;
|
||||
dcr-reg = <0x0c0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
};
|
||||
|
||||
UIC1: interrupt-controller1 {
|
||||
compatible = "ibm,uic-460ex","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <1>;
|
||||
dcr-reg = <0x0d0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0x1e 0x4 0x1f 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
UIC2: interrupt-controller2 {
|
||||
compatible = "ibm,uic-460ex","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <2>;
|
||||
dcr-reg = <0x0e0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0xa 0x4 0xb 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
UIC3: interrupt-controller3 {
|
||||
compatible = "ibm,uic-460ex","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <3>;
|
||||
dcr-reg = <0x0f0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0x10 0x4 0x11 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
SDR0: sdr {
|
||||
compatible = "ibm,sdr-460ex";
|
||||
dcr-reg = <0x00e 0x002>;
|
||||
};
|
||||
|
||||
CPR0: cpr {
|
||||
compatible = "ibm,cpr-460ex";
|
||||
dcr-reg = <0x00c 0x002>;
|
||||
};
|
||||
|
||||
CPM0: cpm {
|
||||
compatible = "ibm,cpm";
|
||||
dcr-access-method = "native";
|
||||
dcr-reg = <0x160 0x003>;
|
||||
unused-units = <0x00000100>;
|
||||
idle-doze = <0x02000000>;
|
||||
standby = <0xfeff791d>;
|
||||
};
|
||||
|
||||
L2C0: l2c {
|
||||
compatible = "ibm,l2-cache-460ex", "ibm,l2-cache";
|
||||
dcr-reg = <0x020 0x008 /* Internal SRAM DCR's */
|
||||
0x030 0x008>; /* L2 cache DCR's */
|
||||
cache-line-size = <32>; /* 32 bytes */
|
||||
cache-size = <262144>; /* L2, 256K */
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <11 1>;
|
||||
};
|
||||
|
||||
plb {
|
||||
compatible = "ibm,plb-460ex", "ibm,plb4";
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
ranges;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
|
||||
SDRAM0: sdram {
|
||||
compatible = "ibm,sdram-460ex", "ibm,sdram-405gp";
|
||||
dcr-reg = <0x010 0x002>;
|
||||
};
|
||||
|
||||
CRYPTO: crypto@180000 {
|
||||
compatible = "amcc,ppc460ex-crypto", "amcc,ppc4xx-crypto";
|
||||
reg = <4 0x00180000 0x80400>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x1d 0x4>;
|
||||
};
|
||||
|
||||
HWRNG: hwrng@110000 {
|
||||
compatible = "amcc,ppc460ex-rng", "ppc4xx-rng";
|
||||
reg = <4 0x00110000 0x50>;
|
||||
};
|
||||
|
||||
MAL0: mcmal {
|
||||
compatible = "ibm,mcmal-460ex", "ibm,mcmal2";
|
||||
dcr-reg = <0x180 0x062>;
|
||||
num-tx-chans = <2>;
|
||||
num-rx-chans = <16>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-parent = <&UIC2>;
|
||||
interrupts = < /*TXEOB*/ 0x6 0x4
|
||||
/*RXEOB*/ 0x7 0x4
|
||||
/*SERR*/ 0x3 0x4
|
||||
/*TXDE*/ 0x4 0x4
|
||||
/*RXDE*/ 0x5 0x4>;
|
||||
};
|
||||
|
||||
USB0: ehci@bffd0400 {
|
||||
compatible = "ibm,usb-ehci-460ex", "usb-ehci";
|
||||
interrupt-parent = <&UIC2>;
|
||||
interrupts = <0x1d 4>;
|
||||
reg = <4 0xbffd0400 0x90 4 0xbffd0490 0x70>;
|
||||
};
|
||||
|
||||
USB1: usb@bffd0000 {
|
||||
compatible = "ohci-le";
|
||||
reg = <4 0xbffd0000 0x60>;
|
||||
interrupt-parent = <&UIC2>;
|
||||
interrupts = <0x1e 4>;
|
||||
};
|
||||
|
||||
USBOTG0: usbotg@bff80000 {
|
||||
compatible = "amcc,dwc-otg";
|
||||
reg = <0x4 0xbff80000 0x10000>;
|
||||
interrupt-parent = <&USBOTG0>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupts = <0x0 0x1 0x2>;
|
||||
interrupt-map = </* USB-OTG */ 0x0 &UIC2 0x1c 0x4
|
||||
/* HIGH-POWER */ 0x1 &UIC1 0x1a 0x8
|
||||
/* DMA */ 0x2 &UIC0 0xc 0x4>;
|
||||
};
|
||||
|
||||
SATA0: sata@bffd1000 {
|
||||
compatible = "amcc,sata-460ex";
|
||||
reg = <4 0xbffd1000 0x800 4 0xbffd0800 0x400>;
|
||||
interrupt-parent = <&UIC3>;
|
||||
interrupts = <0x0 0x4 /* SATA */
|
||||
0x5 0x4>; /* AHBDMA */
|
||||
};
|
||||
|
||||
POB0: opb {
|
||||
compatible = "ibm,opb-460ex", "ibm,opb";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
ranges = <0xb0000000 0x00000004 0xb0000000 0x50000000>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
|
||||
EBC0: ebc {
|
||||
compatible = "ibm,ebc-460ex", "ibm,ebc";
|
||||
dcr-reg = <0x012 0x002>;
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
/* ranges property is supplied by U-Boot */
|
||||
interrupts = <0x6 0x4>;
|
||||
interrupt-parent = <&UIC1>;
|
||||
|
||||
nor_flash@0,0 {
|
||||
compatible = "amd,s29gl512n", "cfi-flash";
|
||||
bank-width = <2>;
|
||||
reg = <0x00000000 0x00000000 0x04000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
partition@0 {
|
||||
label = "kernel";
|
||||
reg = <0x00000000 0x001e0000>;
|
||||
};
|
||||
partition@1e0000 {
|
||||
label = "dtb";
|
||||
reg = <0x001e0000 0x00020000>;
|
||||
};
|
||||
partition@200000 {
|
||||
label = "ramdisk";
|
||||
reg = <0x00200000 0x01400000>;
|
||||
};
|
||||
partition@1600000 {
|
||||
label = "jffs2";
|
||||
reg = <0x01600000 0x00400000>;
|
||||
};
|
||||
partition@1a00000 {
|
||||
label = "user";
|
||||
reg = <0x01a00000 0x02560000>;
|
||||
};
|
||||
partition@3f60000 {
|
||||
label = "env";
|
||||
reg = <0x03f60000 0x00040000>;
|
||||
};
|
||||
partition@3fa0000 {
|
||||
label = "u-boot";
|
||||
reg = <0x03fa0000 0x00060000>;
|
||||
};
|
||||
};
|
||||
|
||||
cpld@2,0 {
|
||||
compatible = "amcc,ppc460ex-bcsr";
|
||||
reg = <2 0x0 0x9>;
|
||||
};
|
||||
|
||||
ndfc@3,0 {
|
||||
compatible = "ibm,ndfc";
|
||||
reg = <0x00000003 0x00000000 0x00002000>;
|
||||
ccr = <0x00001000>;
|
||||
bank-settings = <0x80002222>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
nand {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
partition@0 {
|
||||
label = "u-boot";
|
||||
reg = <0x00000000 0x00100000>;
|
||||
};
|
||||
partition@100000 {
|
||||
label = "user";
|
||||
reg = <0x00000000 0x03f00000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
UART0: serial@ef600300 {
|
||||
device_type = "serial";
|
||||
reg-shift = <0>;
|
||||
compatible = "ns16550";
|
||||
reg = <0xef600300 0x00000008>;
|
||||
virtual-reg = <0xef600300>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
current-speed = <0>; /* Filled in by U-Boot */
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <0x1 0x4>;
|
||||
};
|
||||
|
||||
UART1: serial@ef600400 {
|
||||
device_type = "serial";
|
||||
reg-shift = <0>;
|
||||
compatible = "ns16550";
|
||||
reg = <0xef600400 0x00000008>;
|
||||
virtual-reg = <0xef600400>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
current-speed = <0>; /* Filled in by U-Boot */
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x1 0x4>;
|
||||
};
|
||||
|
||||
IIC0: i2c@ef600700 {
|
||||
compatible = "ibm,iic-460ex", "ibm,iic";
|
||||
reg = <0xef600700 0x00000014>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x2 0x4>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
rtc@68 {
|
||||
compatible = "stm,m41t80";
|
||||
reg = <0x68>;
|
||||
interrupt-parent = <&UIC2>;
|
||||
interrupts = <0x19 0x8>;
|
||||
};
|
||||
sttm@48 {
|
||||
compatible = "ad,ad7414";
|
||||
reg = <0x48>;
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <0x14 0x8>;
|
||||
};
|
||||
};
|
||||
|
||||
IIC1: i2c@ef600800 {
|
||||
compatible = "ibm,iic-460ex", "ibm,iic";
|
||||
reg = <0xef600800 0x00000014>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x3 0x4>;
|
||||
};
|
||||
|
||||
GPIO0: gpio@ef600b00 {
|
||||
compatible = "ibm,ppc4xx-gpio";
|
||||
reg = <0xef600b00 0x00000048>;
|
||||
gpio-controller;
|
||||
};
|
||||
|
||||
ZMII0: emac-zmii@ef600d00 {
|
||||
compatible = "ibm,zmii-460ex", "ibm,zmii";
|
||||
reg = <0xef600d00 0x0000000c>;
|
||||
};
|
||||
|
||||
RGMII0: emac-rgmii@ef601500 {
|
||||
compatible = "ibm,rgmii-460ex", "ibm,rgmii";
|
||||
reg = <0xef601500 0x00000008>;
|
||||
has-mdio;
|
||||
};
|
||||
|
||||
TAH0: emac-tah@ef601350 {
|
||||
compatible = "ibm,tah-460ex", "ibm,tah";
|
||||
reg = <0xef601350 0x00000030>;
|
||||
};
|
||||
|
||||
TAH1: emac-tah@ef601450 {
|
||||
compatible = "ibm,tah-460ex", "ibm,tah";
|
||||
reg = <0xef601450 0x00000030>;
|
||||
};
|
||||
|
||||
EMAC0: ethernet@ef600e00 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460ex", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC0>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x10 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x14 0x4>;
|
||||
reg = <0xef600e00 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <0>;
|
||||
mal-rx-channel = <0>;
|
||||
cell-index = <0>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
phy-mode = "rgmii";
|
||||
phy-map = <0x00000000>;
|
||||
rgmii-device = <&RGMII0>;
|
||||
rgmii-channel = <0>;
|
||||
tah-device = <&TAH0>;
|
||||
tah-channel = <0>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
};
|
||||
|
||||
EMAC1: ethernet@ef600f00 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460ex", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC1>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x11 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x15 0x4>;
|
||||
reg = <0xef600f00 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <1>;
|
||||
mal-rx-channel = <8>;
|
||||
cell-index = <1>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
phy-mode = "rgmii";
|
||||
phy-map = <0x00000000>;
|
||||
rgmii-device = <&RGMII0>;
|
||||
rgmii-channel = <1>;
|
||||
tah-device = <&TAH1>;
|
||||
tah-channel = <1>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
mdio-device = <&EMAC0>;
|
||||
};
|
||||
};
|
||||
|
||||
PCIX0: pci@c0ec00000 {
|
||||
device_type = "pci";
|
||||
#interrupt-cells = <1>;
|
||||
#size-cells = <2>;
|
||||
#address-cells = <3>;
|
||||
compatible = "ibm,plb-pcix-460ex", "ibm,plb-pcix";
|
||||
primary;
|
||||
large-inbound-windows;
|
||||
enable-msi-hole;
|
||||
reg = <0x0000000c 0x0ec00000 0x00000008 /* Config space access */
|
||||
0x00000000 0x00000000 0x00000000 /* no IACK cycles */
|
||||
0x0000000c 0x0ed00000 0x00000004 /* Special cycles */
|
||||
0x0000000c 0x0ec80000 0x00000100 /* Internal registers */
|
||||
0x0000000c 0x0ec80100 0x000000fc>; /* Internal messaging registers */
|
||||
|
||||
/* Outbound ranges, one memory and one IO,
|
||||
* later cannot be changed
|
||||
*/
|
||||
ranges = <0x02000000 0x00000000 0x80000000 0x0000000d 0x80000000 0x00000000 0x80000000
|
||||
0x02000000 0x00000000 0x00000000 0x0000000c 0x0ee00000 0x00000000 0x00100000
|
||||
0x01000000 0x00000000 0x00000000 0x0000000c 0x08000000 0x00000000 0x00010000>;
|
||||
|
||||
/* Inbound 2GB range starting at 0 */
|
||||
dma-ranges = <0x42000000 0x0 0x0 0x0 0x0 0x0 0x80000000>;
|
||||
|
||||
/* This drives busses 0 to 0x3f */
|
||||
bus-range = <0x0 0x3f>;
|
||||
|
||||
/* All PCI interrupts are routed to ext IRQ 2 -> UIC1-0 */
|
||||
interrupt-map-mask = <0x0 0x0 0x0 0x0>;
|
||||
interrupt-map = < 0x0 0x0 0x0 0x0 &UIC1 0x0 0x8 >;
|
||||
};
|
||||
|
||||
PCIE0: pciex@d00000000 {
|
||||
device_type = "pci";
|
||||
#interrupt-cells = <1>;
|
||||
#size-cells = <2>;
|
||||
#address-cells = <3>;
|
||||
compatible = "ibm,plb-pciex-460ex", "ibm,plb-pciex";
|
||||
primary;
|
||||
port = <0x0>; /* port number */
|
||||
reg = <0x0000000d 0x00000000 0x20000000 /* Config space access */
|
||||
0x0000000c 0x08010000 0x00001000>; /* Registers */
|
||||
dcr-reg = <0x100 0x020>;
|
||||
sdr-base = <0x300>;
|
||||
|
||||
/* Outbound ranges, one memory and one IO,
|
||||
* later cannot be changed
|
||||
*/
|
||||
ranges = <0x02000000 0x00000000 0x80000000 0x0000000e 0x00000000 0x00000000 0x80000000
|
||||
0x02000000 0x00000000 0x00000000 0x0000000f 0x00000000 0x00000000 0x00100000
|
||||
0x01000000 0x00000000 0x00000000 0x0000000f 0x80000000 0x00000000 0x00010000>;
|
||||
|
||||
/* Inbound 2GB range starting at 0 */
|
||||
dma-ranges = <0x42000000 0x0 0x0 0x0 0x0 0x0 0x80000000>;
|
||||
|
||||
/* This drives busses 40 to 0x7f */
|
||||
bus-range = <0x40 0x7f>;
|
||||
|
||||
/* Legacy interrupts (note the weird polarity, the bridge seems
|
||||
* to invert PCIe legacy interrupts).
|
||||
* We are de-swizzling here because the numbers are actually for
|
||||
* port of the root complex virtual P2P bridge. But I want
|
||||
* to avoid putting a node for it in the tree, so the numbers
|
||||
* below are basically de-swizzled numbers.
|
||||
* The real slot is on idsel 0, so the swizzling is 1:1
|
||||
*/
|
||||
interrupt-map-mask = <0x0 0x0 0x0 0x7>;
|
||||
interrupt-map = <
|
||||
0x0 0x0 0x0 0x1 &UIC3 0xc 0x4 /* swizzled int A */
|
||||
0x0 0x0 0x0 0x2 &UIC3 0xd 0x4 /* swizzled int B */
|
||||
0x0 0x0 0x0 0x3 &UIC3 0xe 0x4 /* swizzled int C */
|
||||
0x0 0x0 0x0 0x4 &UIC3 0xf 0x4 /* swizzled int D */>;
|
||||
};
|
||||
|
||||
PCIE1: pciex@d20000000 {
|
||||
device_type = "pci";
|
||||
#interrupt-cells = <1>;
|
||||
#size-cells = <2>;
|
||||
#address-cells = <3>;
|
||||
compatible = "ibm,plb-pciex-460ex", "ibm,plb-pciex";
|
||||
primary;
|
||||
port = <0x1>; /* port number */
|
||||
reg = <0x0000000d 0x20000000 0x20000000 /* Config space access */
|
||||
0x0000000c 0x08011000 0x00001000>; /* Registers */
|
||||
dcr-reg = <0x120 0x020>;
|
||||
sdr-base = <0x340>;
|
||||
|
||||
/* Outbound ranges, one memory and one IO,
|
||||
* later cannot be changed
|
||||
*/
|
||||
ranges = <0x02000000 0x00000000 0x80000000 0x0000000e 0x80000000 0x00000000 0x80000000
|
||||
0x02000000 0x00000000 0x00000000 0x0000000f 0x00100000 0x00000000 0x00100000
|
||||
0x01000000 0x00000000 0x00000000 0x0000000f 0x80010000 0x00000000 0x00010000>;
|
||||
|
||||
/* Inbound 2GB range starting at 0 */
|
||||
dma-ranges = <0x42000000 0x0 0x0 0x0 0x0 0x0 0x80000000>;
|
||||
|
||||
/* This drives busses 80 to 0xbf */
|
||||
bus-range = <0x80 0xbf>;
|
||||
|
||||
/* Legacy interrupts (note the weird polarity, the bridge seems
|
||||
* to invert PCIe legacy interrupts).
|
||||
* We are de-swizzling here because the numbers are actually for
|
||||
* port of the root complex virtual P2P bridge. But I want
|
||||
* to avoid putting a node for it in the tree, so the numbers
|
||||
* below are basically de-swizzled numbers.
|
||||
* The real slot is on idsel 0, so the swizzling is 1:1
|
||||
*/
|
||||
interrupt-map-mask = <0x0 0x0 0x0 0x7>;
|
||||
interrupt-map = <
|
||||
0x0 0x0 0x0 0x1 &UIC3 0x10 0x4 /* swizzled int A */
|
||||
0x0 0x0 0x0 0x2 &UIC3 0x11 0x4 /* swizzled int B */
|
||||
0x0 0x0 0x0 0x3 &UIC3 0x12 0x4 /* swizzled int C */
|
||||
0x0 0x0 0x0 0x4 &UIC3 0x13 0x4 /* swizzled int D */>;
|
||||
};
|
||||
|
||||
MSI: ppc4xx-msi@C10000000 {
|
||||
compatible = "amcc,ppc4xx-msi", "ppc4xx-msi";
|
||||
reg = < 0xC 0x10000000 0x100>;
|
||||
sdr-base = <0x36C>;
|
||||
msi-data = <0x00000000>;
|
||||
msi-mask = <0x44440000>;
|
||||
interrupt-count = <3>;
|
||||
interrupts = <0 1 2 3>;
|
||||
interrupt-parent = <&UIC3>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = <0 &UIC3 0x18 1
|
||||
1 &UIC3 0x19 1
|
||||
2 &UIC3 0x1A 1
|
||||
3 &UIC3 0x1B 1>;
|
||||
};
|
||||
};
|
||||
};
|
582
arch/powerpc/dts/glacier.dts
Normal file
582
arch/powerpc/dts/glacier.dts
Normal file
@ -0,0 +1,582 @@
|
||||
/*
|
||||
* Device Tree Source for AMCC Glacier (460GT)
|
||||
*
|
||||
* Copyright 2008-2010 DENX Software Engineering, Stefan Roese <sr@denx.de>
|
||||
*
|
||||
* SPDX-License-Identifier: GPL-2.0
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
/ {
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
model = "amcc,glacier";
|
||||
compatible = "amcc,glacier";
|
||||
dcr-parent = <&{/cpus/cpu@0}>;
|
||||
|
||||
aliases {
|
||||
ethernet0 = &EMAC0;
|
||||
ethernet1 = &EMAC1;
|
||||
ethernet2 = &EMAC2;
|
||||
ethernet3 = &EMAC3;
|
||||
serial0 = &UART0;
|
||||
serial1 = &UART1;
|
||||
};
|
||||
|
||||
chosen {
|
||||
stdout-path = &UART0;
|
||||
};
|
||||
|
||||
cpus {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
cpu@0 {
|
||||
device_type = "cpu";
|
||||
model = "PowerPC,460GT";
|
||||
reg = <0x00000000>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
timebase-frequency = <0>; /* Filled in by U-Boot */
|
||||
i-cache-line-size = <32>;
|
||||
d-cache-line-size = <32>;
|
||||
i-cache-size = <32768>;
|
||||
d-cache-size = <32768>;
|
||||
dcr-controller;
|
||||
dcr-access-method = "native";
|
||||
next-level-cache = <&L2C0>;
|
||||
};
|
||||
};
|
||||
|
||||
memory {
|
||||
device_type = "memory";
|
||||
reg = <0x00000000 0x00000000 0x00000000>; /* Filled in by U-Boot */
|
||||
};
|
||||
|
||||
UIC0: interrupt-controller0 {
|
||||
compatible = "ibm,uic-460gt","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <0>;
|
||||
dcr-reg = <0x0c0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
};
|
||||
|
||||
UIC1: interrupt-controller1 {
|
||||
compatible = "ibm,uic-460gt","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <1>;
|
||||
dcr-reg = <0x0d0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0x1e 0x4 0x1f 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
UIC2: interrupt-controller2 {
|
||||
compatible = "ibm,uic-460gt","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <2>;
|
||||
dcr-reg = <0x0e0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0xa 0x4 0xb 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
UIC3: interrupt-controller3 {
|
||||
compatible = "ibm,uic-460gt","ibm,uic";
|
||||
interrupt-controller;
|
||||
cell-index = <3>;
|
||||
dcr-reg = <0x0f0 0x009>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
#interrupt-cells = <2>;
|
||||
interrupts = <0x10 0x4 0x11 0x4>; /* cascade */
|
||||
interrupt-parent = <&UIC0>;
|
||||
};
|
||||
|
||||
SDR0: sdr {
|
||||
compatible = "ibm,sdr-460gt";
|
||||
dcr-reg = <0x00e 0x002>;
|
||||
};
|
||||
|
||||
CPR0: cpr {
|
||||
compatible = "ibm,cpr-460gt";
|
||||
dcr-reg = <0x00c 0x002>;
|
||||
};
|
||||
|
||||
L2C0: l2c {
|
||||
compatible = "ibm,l2-cache-460gt", "ibm,l2-cache";
|
||||
dcr-reg = <0x020 0x008 /* Internal SRAM DCR's */
|
||||
0x030 0x008>; /* L2 cache DCR's */
|
||||
cache-line-size = <32>; /* 32 bytes */
|
||||
cache-size = <262144>; /* L2, 256K */
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <11 1>;
|
||||
};
|
||||
|
||||
plb {
|
||||
compatible = "ibm,plb-460gt", "ibm,plb4";
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
ranges;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
|
||||
SDRAM0: sdram {
|
||||
compatible = "ibm,sdram-460gt", "ibm,sdram-405gp";
|
||||
dcr-reg = <0x010 0x002>;
|
||||
};
|
||||
|
||||
CRYPTO: crypto@180000 {
|
||||
compatible = "amcc,ppc460gt-crypto", "amcc,ppc460ex-crypto",
|
||||
"amcc,ppc4xx-crypto";
|
||||
reg = <4 0x00180000 0x80400>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x1d 0x4>;
|
||||
};
|
||||
|
||||
HWRNG: hwrng@110000 {
|
||||
compatible = "amcc,ppc460ex-rng", "ppc4xx-rng";
|
||||
reg = <4 0x00110000 0x50>;
|
||||
};
|
||||
|
||||
MAL0: mcmal {
|
||||
compatible = "ibm,mcmal-460gt", "ibm,mcmal2";
|
||||
dcr-reg = <0x180 0x062>;
|
||||
num-tx-chans = <4>;
|
||||
num-rx-chans = <32>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-parent = <&UIC2>;
|
||||
interrupts = < /*TXEOB*/ 0x6 0x4
|
||||
/*RXEOB*/ 0x7 0x4
|
||||
/*SERR*/ 0x3 0x4
|
||||
/*TXDE*/ 0x4 0x4
|
||||
/*RXDE*/ 0x5 0x4>;
|
||||
desc-base-addr-high = <0x8>;
|
||||
};
|
||||
|
||||
POB0: opb {
|
||||
compatible = "ibm,opb-460gt", "ibm,opb";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
ranges = <0xb0000000 0x00000004 0xb0000000 0x50000000>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
|
||||
EBC0: ebc {
|
||||
compatible = "ibm,ebc-460gt", "ibm,ebc";
|
||||
dcr-reg = <0x012 0x002>;
|
||||
#address-cells = <2>;
|
||||
#size-cells = <1>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
/* ranges property is supplied by U-Boot */
|
||||
interrupts = <0x6 0x4>;
|
||||
interrupt-parent = <&UIC1>;
|
||||
|
||||
nor_flash@0,0 {
|
||||
compatible = "amd,s29gl512n", "cfi-flash";
|
||||
bank-width = <2>;
|
||||
reg = <0x00000000 0x00000000 0x04000000>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
partition@0 {
|
||||
label = "kernel";
|
||||
reg = <0x00000000 0x001e0000>;
|
||||
};
|
||||
partition@1e0000 {
|
||||
label = "dtb";
|
||||
reg = <0x001e0000 0x00020000>;
|
||||
};
|
||||
partition@200000 {
|
||||
label = "ramdisk";
|
||||
reg = <0x00200000 0x01400000>;
|
||||
};
|
||||
partition@1600000 {
|
||||
label = "jffs2";
|
||||
reg = <0x01600000 0x00400000>;
|
||||
};
|
||||
partition@1a00000 {
|
||||
label = "user";
|
||||
reg = <0x01a00000 0x02560000>;
|
||||
};
|
||||
partition@3f60000 {
|
||||
label = "env";
|
||||
reg = <0x03f60000 0x00040000>;
|
||||
};
|
||||
partition@3fa0000 {
|
||||
label = "u-boot";
|
||||
reg = <0x03fa0000 0x00060000>;
|
||||
};
|
||||
};
|
||||
|
||||
ndfc@3,0 {
|
||||
compatible = "ibm,ndfc";
|
||||
reg = <0x00000003 0x00000000 0x00002000>;
|
||||
ccr = <0x00001000>;
|
||||
bank-settings = <0x80002222>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
nand {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
||||
partition@0 {
|
||||
label = "u-boot";
|
||||
reg = <0x00000000 0x00100000>;
|
||||
};
|
||||
partition@100000 {
|
||||
label = "user";
|
||||
reg = <0x00000000 0x03f00000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
UART0: serial@ef600300 {
|
||||
device_type = "serial";
|
||||
reg-shift = <0>;
|
||||
compatible = "ns16550";
|
||||
reg = <0xef600300 0x00000008>;
|
||||
virtual-reg = <0xef600300>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
current-speed = <0>; /* Filled in by U-Boot */
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <0x1 0x4>;
|
||||
};
|
||||
|
||||
UART1: serial@ef600400 {
|
||||
device_type = "serial";
|
||||
reg-shift = <0>;
|
||||
compatible = "ns16550";
|
||||
reg = <0xef600400 0x00000008>;
|
||||
virtual-reg = <0xef600400>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
current-speed = <0>; /* Filled in by U-Boot */
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x1 0x4>;
|
||||
};
|
||||
|
||||
UART2: serial@ef600500 {
|
||||
device_type = "serial";
|
||||
reg-shift = <0>;
|
||||
compatible = "ns16550";
|
||||
reg = <0xef600500 0x00000008>;
|
||||
virtual-reg = <0xef600500>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
current-speed = <0>; /* Filled in by U-Boot */
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <28 0x4>;
|
||||
};
|
||||
|
||||
UART3: serial@ef600600 {
|
||||
device_type = "serial";
|
||||
reg-shift = <0>;
|
||||
compatible = "ns16550";
|
||||
reg = <0xef600600 0x00000008>;
|
||||
virtual-reg = <0xef600600>;
|
||||
clock-frequency = <0>; /* Filled in by U-Boot */
|
||||
current-speed = <0>; /* Filled in by U-Boot */
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <29 0x4>;
|
||||
};
|
||||
|
||||
IIC0: i2c@ef600700 {
|
||||
compatible = "ibm,iic-460gt", "ibm,iic";
|
||||
reg = <0xef600700 0x00000014>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x2 0x4>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
rtc@68 {
|
||||
compatible = "stm,m41t80";
|
||||
reg = <0x68>;
|
||||
interrupt-parent = <&UIC2>;
|
||||
interrupts = <0x19 0x8>;
|
||||
};
|
||||
sttm@48 {
|
||||
compatible = "ad,ad7414";
|
||||
reg = <0x48>;
|
||||
interrupt-parent = <&UIC1>;
|
||||
interrupts = <0x14 0x8>;
|
||||
};
|
||||
};
|
||||
|
||||
IIC1: i2c@ef600800 {
|
||||
compatible = "ibm,iic-460gt", "ibm,iic";
|
||||
reg = <0xef600800 0x00000014>;
|
||||
interrupt-parent = <&UIC0>;
|
||||
interrupts = <0x3 0x4>;
|
||||
};
|
||||
|
||||
ZMII0: emac-zmii@ef600d00 {
|
||||
compatible = "ibm,zmii-460gt", "ibm,zmii";
|
||||
reg = <0xef600d00 0x0000000c>;
|
||||
};
|
||||
|
||||
RGMII0: emac-rgmii@ef601500 {
|
||||
compatible = "ibm,rgmii-460gt", "ibm,rgmii";
|
||||
reg = <0xef601500 0x00000008>;
|
||||
has-mdio;
|
||||
};
|
||||
|
||||
RGMII1: emac-rgmii@ef601600 {
|
||||
compatible = "ibm,rgmii-460gt", "ibm,rgmii";
|
||||
reg = <0xef601600 0x00000008>;
|
||||
has-mdio;
|
||||
};
|
||||
|
||||
TAH0: emac-tah@ef601350 {
|
||||
compatible = "ibm,tah-460gt", "ibm,tah";
|
||||
reg = <0xef601350 0x00000030>;
|
||||
};
|
||||
|
||||
TAH1: emac-tah@ef601450 {
|
||||
compatible = "ibm,tah-460gt", "ibm,tah";
|
||||
reg = <0xef601450 0x00000030>;
|
||||
};
|
||||
|
||||
EMAC0: ethernet@ef600e00 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460gt", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC0>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x10 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x14 0x4>;
|
||||
reg = <0xef600e00 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <0>;
|
||||
mal-rx-channel = <0>;
|
||||
cell-index = <0>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
phy-mode = "rgmii";
|
||||
phy-map = <0x00000000>;
|
||||
rgmii-device = <&RGMII0>;
|
||||
rgmii-channel = <0>;
|
||||
tah-device = <&TAH0>;
|
||||
tah-channel = <0>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
};
|
||||
|
||||
EMAC1: ethernet@ef600f00 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460gt", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC1>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x11 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x15 0x4>;
|
||||
reg = <0xef600f00 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <1>;
|
||||
mal-rx-channel = <8>;
|
||||
cell-index = <1>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
phy-mode = "rgmii";
|
||||
phy-map = <0x00000000>;
|
||||
rgmii-device = <&RGMII0>;
|
||||
rgmii-channel = <1>;
|
||||
tah-device = <&TAH1>;
|
||||
tah-channel = <1>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
mdio-device = <&EMAC0>;
|
||||
};
|
||||
|
||||
EMAC2: ethernet@ef601100 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460gt", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC2>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x12 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x16 0x4>;
|
||||
reg = <0xef601100 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <2>;
|
||||
mal-rx-channel = <16>;
|
||||
cell-index = <2>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
tx-fifo-size-gige = <16384>; /* emac2&3 only */
|
||||
phy-mode = "rgmii";
|
||||
phy-map = <0x00000000>;
|
||||
rgmii-device = <&RGMII1>;
|
||||
rgmii-channel = <0>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
mdio-device = <&EMAC0>;
|
||||
};
|
||||
|
||||
EMAC3: ethernet@ef601200 {
|
||||
device_type = "network";
|
||||
compatible = "ibm,emac-460gt", "ibm,emac4sync";
|
||||
interrupt-parent = <&EMAC3>;
|
||||
interrupts = <0x0 0x1>;
|
||||
#interrupt-cells = <1>;
|
||||
#address-cells = <0>;
|
||||
#size-cells = <0>;
|
||||
interrupt-map = </*Status*/ 0x0 &UIC2 0x13 0x4
|
||||
/*Wake*/ 0x1 &UIC2 0x17 0x4>;
|
||||
reg = <0xef601200 0x000000c4>;
|
||||
local-mac-address = [000000000000]; /* Filled in by U-Boot */
|
||||
mal-device = <&MAL0>;
|
||||
mal-tx-channel = <3>;
|
||||
mal-rx-channel = <24>;
|
||||
cell-index = <3>;
|
||||
max-frame-size = <9000>;
|
||||
rx-fifo-size = <4096>;
|
||||
tx-fifo-size = <2048>;
|
||||
rx-fifo-size-gige = <16384>;
|
||||
tx-fifo-size-gige = <16384>; /* emac2&3 only */
|
||||
phy-mode = "rgmii";
|
||||
phy-map = <0x00000000>;
|
||||
rgmii-device = <&RGMII1>;
|
||||
rgmii-channel = <1>;
|
||||
has-inverted-stacr-oc;
|
||||
has-new-stacr-staopc;
|
||||
mdio-device = <&EMAC0>;
|
||||
};
|
||||
};
|
||||
|
||||
PCIX0: pci@c0ec00000 {
|
||||
device_type = "pci";
|
||||
#interrupt-cells = <1>;
|
||||
#size-cells = <2>;
|
||||
#address-cells = <3>;
|
||||
compatible = "ibm,plb-pcix-460gt", "ibm,plb-pcix";
|
||||
primary;
|
||||
large-inbound-windows;
|
||||
enable-msi-hole;
|
||||
reg = <0x0000000c 0x0ec00000 0x00000008 /* Config space access */
|
||||
0x00000000 0x00000000 0x00000000 /* no IACK cycles */
|
||||
0x0000000c 0x0ed00000 0x00000004 /* Special cycles */
|
||||
0x0000000c 0x0ec80000 0x00000100 /* Internal registers */
|
||||
0x0000000c 0x0ec80100 0x000000fc>; /* Internal messaging registers */
|
||||
|
||||
/* Outbound ranges, one memory and one IO,
|
||||
* later cannot be changed
|
||||
*/
|
||||
ranges = <0x02000000 0x00000000 0x80000000 0x0000000d 0x80000000 0x00000000 0x80000000
|
||||
0x02000000 0x00000000 0x00000000 0x0000000c 0x0ee00000 0x00000000 0x00100000
|
||||
0x01000000 0x00000000 0x00000000 0x0000000c 0x08000000 0x00000000 0x00010000>;
|
||||
|
||||
/* Inbound 2GB range starting at 0 */
|
||||
dma-ranges = <0x42000000 0x0 0x0 0x0 0x0 0x0 0x80000000>;
|
||||
|
||||
/* This drives busses 0 to 0x3f */
|
||||
bus-range = <0x0 0x3f>;
|
||||
|
||||
/* All PCI interrupts are routed to ext IRQ 2 -> UIC1-0 */
|
||||
interrupt-map-mask = <0x0 0x0 0x0 0x0>;
|
||||
interrupt-map = < 0x0 0x0 0x0 0x0 &UIC1 0x0 0x8 >;
|
||||
};
|
||||
|
||||
PCIE0: pciex@d00000000 {
|
||||
device_type = "pci";
|
||||
#interrupt-cells = <1>;
|
||||
#size-cells = <2>;
|
||||
#address-cells = <3>;
|
||||
compatible = "ibm,plb-pciex-460ex", "ibm,plb-pciex";
|
||||
primary;
|
||||
port = <0x0>; /* port number */
|
||||
reg = <0x0000000d 0x00000000 0x20000000 /* Config space access */
|
||||
0x0000000c 0x08010000 0x00001000>; /* Registers */
|
||||
dcr-reg = <0x100 0x020>;
|
||||
sdr-base = <0x300>;
|
||||
|
||||
/* Outbound ranges, one memory and one IO,
|
||||
* later cannot be changed
|
||||
*/
|
||||
ranges = <0x02000000 0x00000000 0x80000000 0x0000000e 0x00000000 0x00000000 0x80000000
|
||||
0x02000000 0x00000000 0x00000000 0x0000000f 0x00000000 0x00000000 0x00100000
|
||||
0x01000000 0x00000000 0x00000000 0x0000000f 0x80000000 0x00000000 0x00010000>;
|
||||
|
||||
/* Inbound 2GB range starting at 0 */
|
||||
dma-ranges = <0x42000000 0x0 0x0 0x0 0x0 0x0 0x80000000>;
|
||||
|
||||
/* This drives busses 40 to 0x7f */
|
||||
bus-range = <0x40 0x7f>;
|
||||
|
||||
/* Legacy interrupts (note the weird polarity, the bridge seems
|
||||
* to invert PCIe legacy interrupts).
|
||||
* We are de-swizzling here because the numbers are actually for
|
||||
* port of the root complex virtual P2P bridge. But I want
|
||||
* to avoid putting a node for it in the tree, so the numbers
|
||||
* below are basically de-swizzled numbers.
|
||||
* The real slot is on idsel 0, so the swizzling is 1:1
|
||||
*/
|
||||
interrupt-map-mask = <0x0 0x0 0x0 0x7>;
|
||||
interrupt-map = <
|
||||
0x0 0x0 0x0 0x1 &UIC3 0xc 0x4 /* swizzled int A */
|
||||
0x0 0x0 0x0 0x2 &UIC3 0xd 0x4 /* swizzled int B */
|
||||
0x0 0x0 0x0 0x3 &UIC3 0xe 0x4 /* swizzled int C */
|
||||
0x0 0x0 0x0 0x4 &UIC3 0xf 0x4 /* swizzled int D */>;
|
||||
};
|
||||
|
||||
PCIE1: pciex@d20000000 {
|
||||
device_type = "pci";
|
||||
#interrupt-cells = <1>;
|
||||
#size-cells = <2>;
|
||||
#address-cells = <3>;
|
||||
compatible = "ibm,plb-pciex-460ex", "ibm,plb-pciex";
|
||||
primary;
|
||||
port = <0x1>; /* port number */
|
||||
reg = <0x0000000d 0x20000000 0x20000000 /* Config space access */
|
||||
0x0000000c 0x08011000 0x00001000>; /* Registers */
|
||||
dcr-reg = <0x120 0x020>;
|
||||
sdr-base = <0x340>;
|
||||
|
||||
/* Outbound ranges, one memory and one IO,
|
||||
* later cannot be changed
|
||||
*/
|
||||
ranges = <0x02000000 0x00000000 0x80000000 0x0000000e 0x80000000 0x00000000 0x80000000
|
||||
0x02000000 0x00000000 0x00000000 0x0000000f 0x00100000 0x00000000 0x00100000
|
||||
0x01000000 0x00000000 0x00000000 0x0000000f 0x80010000 0x00000000 0x00010000>;
|
||||
|
||||
/* Inbound 2GB range starting at 0 */
|
||||
dma-ranges = <0x42000000 0x0 0x0 0x0 0x0 0x0 0x80000000>;
|
||||
|
||||
/* This drives busses 80 to 0xbf */
|
||||
bus-range = <0x80 0xbf>;
|
||||
|
||||
/* Legacy interrupts (note the weird polarity, the bridge seems
|
||||
* to invert PCIe legacy interrupts).
|
||||
* We are de-swizzling here because the numbers are actually for
|
||||
* port of the root complex virtual P2P bridge. But I want
|
||||
* to avoid putting a node for it in the tree, so the numbers
|
||||
* below are basically de-swizzled numbers.
|
||||
* The real slot is on idsel 0, so the swizzling is 1:1
|
||||
*/
|
||||
interrupt-map-mask = <0x0 0x0 0x0 0x7>;
|
||||
interrupt-map = <
|
||||
0x0 0x0 0x0 0x1 &UIC3 0x10 0x4 /* swizzled int A */
|
||||
0x0 0x0 0x0 0x2 &UIC3 0x11 0x4 /* swizzled int B */
|
||||
0x0 0x0 0x0 0x3 &UIC3 0x12 0x4 /* swizzled int C */
|
||||
0x0 0x0 0x0 0x4 &UIC3 0x13 0x4 /* swizzled int D */>;
|
||||
};
|
||||
};
|
||||
};
|
7
arch/powerpc/include/asm/arch-ppc4xx/gpio.h
Normal file
7
arch/powerpc/include/asm/arch-ppc4xx/gpio.h
Normal file
@ -0,0 +1,7 @@
|
||||
/*
|
||||
* (C) Copyright 2014 Google, Inc
|
||||
*
|
||||
* SPDX-License-Identifier: GPL-2.0+
|
||||
*/
|
||||
|
||||
/* This is empty for now as we don't support the generic GPIO interface */
|
7
arch/powerpc/include/asm/linkage.h
Normal file
7
arch/powerpc/include/asm/linkage.h
Normal file
@ -0,0 +1,7 @@
|
||||
/*
|
||||
* Copyright (c) 2014 Google, Inc
|
||||
*
|
||||
* SPDX-License-Identifier: GPL-2.0+
|
||||
*/
|
||||
|
||||
/* We don't need anything here at present */
|
@ -19,10 +19,12 @@
|
||||
/* Memory mapped registers */
|
||||
#define CONFIG_SYS_PERIPHERAL_BASE 0xef600000 /* Internal Peripherals */
|
||||
|
||||
#ifndef CONFIG_DM_SERIAL
|
||||
#define CONFIG_SYS_NS16550_COM1 (CONFIG_SYS_PERIPHERAL_BASE + 0x0300)
|
||||
#define CONFIG_SYS_NS16550_COM2 (CONFIG_SYS_PERIPHERAL_BASE + 0x0400)
|
||||
#define CONFIG_SYS_NS16550_COM3 (CONFIG_SYS_PERIPHERAL_BASE + 0x0500)
|
||||
#define CONFIG_SYS_NS16550_COM4 (CONFIG_SYS_PERIPHERAL_BASE + 0x0600)
|
||||
#endif
|
||||
|
||||
#define GPIO0_BASE (CONFIG_SYS_PERIPHERAL_BASE + 0x0b00)
|
||||
#define GPIO1_BASE (CONFIG_SYS_PERIPHERAL_BASE + 0x0c00)
|
||||
|
@ -10,4 +10,28 @@ config SYS_BOARD
|
||||
config SYS_CONFIG_NAME
|
||||
default "sandbox"
|
||||
|
||||
config DM
|
||||
default y
|
||||
|
||||
config DM_GPIO
|
||||
default y
|
||||
|
||||
config DM_SERIAL
|
||||
default y
|
||||
|
||||
config DM_CROS_EC
|
||||
default y
|
||||
|
||||
config DM_SPI
|
||||
default y
|
||||
|
||||
config DM_SPI_FLASH
|
||||
default y
|
||||
|
||||
config DM_I2C
|
||||
default y
|
||||
|
||||
config DM_TEST
|
||||
default y
|
||||
|
||||
endmenu
|
||||
|
@ -67,6 +67,21 @@ config TARGET_GALILEO
|
||||
|
||||
endchoice
|
||||
|
||||
config DM
|
||||
default y
|
||||
|
||||
config DM_GPIO
|
||||
default y
|
||||
|
||||
config DM_SERIAL
|
||||
default y
|
||||
|
||||
config SYS_MALLOC_F
|
||||
default y
|
||||
|
||||
config SYS_MALLOC_F_LEN
|
||||
default 0x800
|
||||
|
||||
config RAMBASE
|
||||
hex
|
||||
default 0x100000
|
||||
|
@ -9,4 +9,42 @@ config SYS_VENDOR
|
||||
config SYS_CONFIG_NAME
|
||||
default "canyonlands"
|
||||
|
||||
choice BOARD_TYPE
|
||||
prompt "Select which board to build for"
|
||||
|
||||
config CANYONLANDS
|
||||
bool "Glacier"
|
||||
help
|
||||
Select this to build for the Canyonlands 460EX board.
|
||||
|
||||
config GLACIER
|
||||
bool "Glacier"
|
||||
help
|
||||
Select this to build for the Glacier 460GT board.
|
||||
|
||||
config ARCHES
|
||||
bool "Arches"
|
||||
help
|
||||
Select this to build for the Arches dual 460GT board.
|
||||
|
||||
endchoice
|
||||
|
||||
config DISPLAY_BOARDINFO
|
||||
bool
|
||||
default y
|
||||
|
||||
config DM
|
||||
default y
|
||||
|
||||
config DM_SERIAL
|
||||
default y
|
||||
|
||||
config SYS_MALLOC_F
|
||||
bool
|
||||
default y
|
||||
|
||||
config SYS_MALLOC_F_LEN
|
||||
hex
|
||||
default 0x400
|
||||
|
||||
endif
|
||||
|
@ -6,3 +6,4 @@ F: include/configs/canyonlands.h
|
||||
F: configs/arches_defconfig
|
||||
F: configs/canyonlands_defconfig
|
||||
F: configs/glacier_defconfig
|
||||
F: configs/glacier_ramboot_defconfig
|
||||
|
@ -8,8 +8,6 @@
|
||||
# AMCC 460EX/460GT Evaluation Board (Canyonlands) board
|
||||
#
|
||||
|
||||
PLATFORM_CPPFLAGS += -DCONFIG_440=1
|
||||
|
||||
ifeq ($(debug),1)
|
||||
PLATFORM_CPPFLAGS += -DDEBUG
|
||||
endif
|
||||
|
85
board/amcc/canyonlands/u-boot-ram.lds
Normal file
85
board/amcc/canyonlands/u-boot-ram.lds
Normal file
@ -0,0 +1,85 @@
|
||||
/*
|
||||
* (C) Copyright 2009
|
||||
* Stefan Roese, DENX Software Engineering, sr@denx.de.
|
||||
*
|
||||
* SPDX-License-Identifier: GPL-2.0+
|
||||
*/
|
||||
|
||||
OUTPUT_ARCH(powerpc)
|
||||
SECTIONS
|
||||
{
|
||||
/* Read-only sections, merged into text segment: */
|
||||
. = + SIZEOF_HEADERS;
|
||||
.text :
|
||||
{
|
||||
_image_copy_start = .;
|
||||
arch/powerpc/cpu/ppc4xx/start.o (.text*)
|
||||
board/amcc/canyonlands/init.o (.text*)
|
||||
|
||||
*(.text*)
|
||||
}
|
||||
_etext = .;
|
||||
PROVIDE (etext = .);
|
||||
.rodata :
|
||||
{
|
||||
*(SORT_BY_ALIGNMENT(SORT_BY_NAME(.rodata*)))
|
||||
}
|
||||
|
||||
/* Read-write section, merged into data segment: */
|
||||
. = (. + 0x00FF) & 0xFFFFFF00;
|
||||
_erotext = .;
|
||||
PROVIDE (erotext = .);
|
||||
.reloc :
|
||||
{
|
||||
KEEP(*(.got))
|
||||
_GOT2_TABLE_ = .;
|
||||
KEEP(*(.got2))
|
||||
_FIXUP_TABLE_ = .;
|
||||
KEEP(*(.fixup))
|
||||
}
|
||||
__got2_entries = (_FIXUP_TABLE_ - _GOT2_TABLE_) >>2;
|
||||
__fixup_entries = (. - _FIXUP_TABLE_)>>2;
|
||||
|
||||
.data :
|
||||
{
|
||||
*(.data*)
|
||||
*(.sdata*)
|
||||
}
|
||||
_edata = .;
|
||||
PROVIDE (edata = .);
|
||||
|
||||
. = .;
|
||||
|
||||
.u_boot_list : {
|
||||
KEEP(*(SORT(.u_boot_list*)));
|
||||
}
|
||||
|
||||
. = .;
|
||||
__start___ex_table = .;
|
||||
__ex_table : { *(__ex_table) }
|
||||
__stop___ex_table = .;
|
||||
|
||||
. = ALIGN(256);
|
||||
__init_begin = .;
|
||||
.text.init : { *(.text.init) }
|
||||
.data.init : {
|
||||
*(.data.init)
|
||||
. = ALIGN(256);
|
||||
LONG(0) LONG(0) /* Extend u-boot.bin to here */
|
||||
}
|
||||
__init_end = .;
|
||||
_end = .;
|
||||
_image_binary_end = .;
|
||||
|
||||
__bss_start = .;
|
||||
.bss (NOLOAD) :
|
||||
{
|
||||
*(.bss*)
|
||||
*(.sbss*)
|
||||
*(COMMON)
|
||||
. = ALIGN(4);
|
||||
}
|
||||
|
||||
__bss_end = . ;
|
||||
PROVIDE (end = .);
|
||||
}
|
@ -12,4 +12,13 @@ config SYS_SOC
|
||||
config SYS_CONFIG_NAME
|
||||
default "cm_t335"
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
endif
|
||||
|
@ -12,4 +12,13 @@ config SYS_SOC
|
||||
config SYS_CONFIG_NAME
|
||||
default "pepper"
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
endif
|
||||
|
@ -12,4 +12,13 @@ config SYS_SOC
|
||||
config SYS_CONFIG_NAME
|
||||
default "am335x_igep0033"
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
endif
|
||||
|
@ -12,4 +12,13 @@ config SYS_SOC
|
||||
config SYS_CONFIG_NAME
|
||||
default "pcm051"
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
endif
|
||||
|
@ -12,4 +12,13 @@ config SYS_SOC
|
||||
config SYS_CONFIG_NAME
|
||||
default "s5p_goni"
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
endif
|
||||
|
@ -22,6 +22,9 @@ config SYS_VENDOR
|
||||
config SYS_CONFIG_NAME
|
||||
default "peach-pi"
|
||||
|
||||
config DM_CROS_EC
|
||||
default y
|
||||
|
||||
endif
|
||||
|
||||
if TARGET_PEACH_PIT
|
||||
@ -35,6 +38,9 @@ config SYS_VENDOR
|
||||
config SYS_CONFIG_NAME
|
||||
default "peach-pit"
|
||||
|
||||
config DM_CROS_EC
|
||||
default y
|
||||
|
||||
endif
|
||||
|
||||
if TARGET_SMDK5420
|
||||
|
@ -12,4 +12,13 @@ config SYS_SOC
|
||||
config SYS_CONFIG_NAME
|
||||
default "smdkc100"
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
endif
|
||||
|
@ -12,4 +12,13 @@ config SYS_SOC
|
||||
config SYS_CONFIG_NAME
|
||||
default "pengwyn"
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if !SPL_BUILD
|
||||
|
||||
endif
|
||||
|
@ -37,4 +37,20 @@ config NOR_BOOT
|
||||
booted via NOR. In this case we will enable certain pinmux early
|
||||
as the ROM only partially sets up pinmux. We also default to using
|
||||
NOR for environment.
|
||||
|
||||
config DM
|
||||
default y if !SPL_BUILD
|
||||
|
||||
config DM_GPIO
|
||||
default y if DM && !SPL_BUILD
|
||||
|
||||
config DM_SERIAL
|
||||
default y if DM && !SPL_BUILD
|
||||
|
||||
config SYS_MALLOC_F
|
||||
default y if DM && !SPL_BUILD
|
||||
|
||||
config SYS_MALLOC_F_LEN
|
||||
default 0x400 if DM && !SPL_BUILD
|
||||
|
||||
endif
|
||||
|
@ -153,6 +153,29 @@ endmenu
|
||||
|
||||
menu "Device access commands"
|
||||
|
||||
config CMD_DM
|
||||
bool "dm - Access to driver model information"
|
||||
depends on DM
|
||||
default y
|
||||
help
|
||||
Provides access to driver model data structures and information,
|
||||
such as a list of devices, list of uclasses and the state of each
|
||||
device (e.g. activated). This is not required for operation, but
|
||||
can be useful to see the state of driver model for debugging or
|
||||
interest.
|
||||
|
||||
config CMD_DEMO
|
||||
bool "demo - Demonstration commands for driver model"
|
||||
depends on DM
|
||||
help
|
||||
Provides a 'demo' command which can be used to play around with
|
||||
driver model. To use this properly you will need to enable one or
|
||||
both of the demo devices (DM_DEMO_SHAPE and DM_DEMO_SIMPLE).
|
||||
Otherwise you will always get an empty list of devices. The demo
|
||||
devices are defined in the sandbox device tree, so the easiest
|
||||
option is to use sandbox and pass the -d point to sandbox's
|
||||
u-boot.dtb file.
|
||||
|
||||
config CMD_LOADB
|
||||
bool "loadb"
|
||||
help
|
||||
|
@ -1075,4 +1075,22 @@ void board_init_f_r(void)
|
||||
/* NOTREACHED - board_init_r() does not return */
|
||||
hang();
|
||||
}
|
||||
#else
|
||||
ulong board_init_f_mem(ulong top)
|
||||
{
|
||||
/* Leave space for the stack we are running with now */
|
||||
top -= 0x40;
|
||||
|
||||
top -= sizeof(struct global_data);
|
||||
top = ALIGN(top, 16);
|
||||
gd = (struct global_data *)top;
|
||||
memset((void *)gd, '\0', sizeof(*gd));
|
||||
|
||||
#ifdef CONFIG_SYS_MALLOC_F_LEN
|
||||
top -= CONFIG_SYS_MALLOC_F_LEN;
|
||||
gd->malloc_base = top;
|
||||
#endif
|
||||
|
||||
return top;
|
||||
}
|
||||
#endif /* CONFIG_X86 */
|
||||
|
@ -97,7 +97,9 @@ static int do_demo(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[])
|
||||
ARRAY_SIZE(demo_commands));
|
||||
argc -= 2;
|
||||
argv += 2;
|
||||
if (!demo_cmd || argc > demo_cmd->maxargs)
|
||||
|
||||
if ((!demo_cmd || argc > demo_cmd->maxargs) ||
|
||||
((demo_cmd->name[0] != 'l') && (argc < 1)))
|
||||
return CMD_RET_USAGE;
|
||||
|
||||
if (argc) {
|
||||
|
@ -1730,7 +1730,7 @@ static int do_i2c_bus_speed(cmd_tbl_t * cmdtp, int flag, int argc, char * const
|
||||
#endif
|
||||
if (argc == 1) {
|
||||
#ifdef CONFIG_DM_I2C
|
||||
speed = i2c_get_bus_speed(bus);
|
||||
speed = dm_i2c_get_bus_speed(bus);
|
||||
#else
|
||||
speed = i2c_get_bus_speed();
|
||||
#endif
|
||||
@ -1740,7 +1740,7 @@ static int do_i2c_bus_speed(cmd_tbl_t * cmdtp, int flag, int argc, char * const
|
||||
speed = simple_strtoul(argv[1], NULL, 10);
|
||||
printf("Setting bus speed to %d Hz\n", speed);
|
||||
#ifdef CONFIG_DM_I2C
|
||||
ret = i2c_set_bus_speed(bus, speed);
|
||||
ret = dm_i2c_set_bus_speed(bus, speed);
|
||||
#else
|
||||
ret = i2c_set_bus_speed(speed);
|
||||
#endif
|
||||
|
@ -19,7 +19,7 @@ void *malloc_simple(size_t bytes)
|
||||
|
||||
new_ptr = gd->malloc_ptr + bytes;
|
||||
if (new_ptr > gd->malloc_limit)
|
||||
panic("Out of pre-reloc memory");
|
||||
return NULL;
|
||||
ptr = map_sysmem(gd->malloc_base + gd->malloc_ptr, bytes);
|
||||
gd->malloc_ptr = ALIGN(new_ptr, sizeof(new_ptr));
|
||||
return ptr;
|
||||
|
@ -2,6 +2,8 @@ CONFIG_SPL=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="AXP209_POWER,SUNXI_GMAC,AHCI,SATAPWR=SUNXI_GPH(2),USB_EHCI"
|
||||
CONFIG_FDTFILE="sun7i-a20-pcduino3.dtb"
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_DM_SERIAL=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="sun7i-a20-pcduino3"
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_OF_SEPARATE=y
|
||||
@ -11,3 +13,5 @@ CONFIG_OF_SEPARATE=y
|
||||
+S:CONFIG_DRAM_CLK=480
|
||||
+S:CONFIG_DRAM_ZQ=122
|
||||
+S:CONFIG_DRAM_EMR1=4
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -1,3 +1,5 @@
|
||||
CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_AM335X_IGEP0033=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_AM3517_CRANE=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_AM3517_EVM=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -1,4 +1,7 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="ARCHES"
|
||||
CONFIG_PPC=y
|
||||
CONFIG_4xx=y
|
||||
CONFIG_TARGET_CANYONLANDS=y
|
||||
CONFIG_ARCHES=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="arches"
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_OF_SEPARATE=y
|
||||
|
@ -1,4 +1,7 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="CANYONLANDS"
|
||||
CONFIG_PPC=y
|
||||
CONFIG_4xx=y
|
||||
CONFIG_TARGET_CANYONLANDS=y
|
||||
CONFIG_CANYONLANDS=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="canyonlands"
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_OF_EMBED=y
|
||||
|
@ -2,3 +2,8 @@ CONFIG_SPL=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/imx-common/spl_sd.cfg,MX6QDL,SPL"
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_CM_FX6=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_DM_SERIAL=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -1,3 +1,5 @@
|
||||
CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_CM_T335=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=n
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_CM_T3517=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_CM_T35=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_DEVKIT8000=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_SERIAL=y
|
||||
CONFIG_DM_GPIO=y
|
||||
|
@ -1,3 +1,6 @@
|
||||
CONFIG_ARM=y
|
||||
CONFIG_OMAP34XX=y
|
||||
CONFIG_TARGET_DIG297=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_ECO5PK=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -1,4 +1,7 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="GLACIER"
|
||||
CONFIG_PPC=y
|
||||
CONFIG_4xx=y
|
||||
CONFIG_TARGET_CANYONLANDS=y
|
||||
CONFIG_GLACIER=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="glacier"
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_OF_EMBED=y
|
||||
|
8
configs/glacier_ramboot_defconfig
Normal file
8
configs/glacier_ramboot_defconfig
Normal file
@ -0,0 +1,8 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="SYS_RAMBOOT,SYS_TEXT_BASE=0x01000000,SYS_LDSCRIPT=board/amcc/canyonlands/u-boot-ram.lds"
|
||||
CONFIG_PPC=y
|
||||
CONFIG_4xx=y
|
||||
CONFIG_TARGET_CANYONLANDS=y
|
||||
CONFIG_GLACIER=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="glacier"
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_OF_EMBED=y
|
@ -2,3 +2,5 @@ CONFIG_SPL=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/imx-common/spl_sd.cfg,MX6QDL"
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_GW_VENTANA=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_MCX=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_MT_VENTOUX=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -1,3 +1,7 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6qsabreauto/mx6dl.cfg,MX6DL"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_MX6QSABREAUTO=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
|
@ -1,3 +1,5 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6sabresd/mx6dlsabresd.cfg,MX6DL"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_MX6SABRESD=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
|
@ -1,3 +1,7 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6qsabreauto/imximage.cfg,MX6Q"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_MX6QSABREAUTO=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
|
@ -1,3 +1,5 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/boundary/nitrogen6x/nitrogen6q.cfg,MX6Q,DDR_MB=1024,SABRELITE"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_NITROGEN6X=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
|
@ -1,3 +1,7 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6sabresd/mx6q_4x_mt41j128.cfg,MX6Q"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_MX6SABRESD=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
|
@ -2,4 +2,5 @@ CONFIG_SPL=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/imx-common/spl_sd.cfg,SPL,MX6Q"
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_MX6SABRESD=y
|
||||
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
|
@ -1,3 +1,5 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/freescale/mx6sxsabresd/imximage.cfg,MX6SX"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_MX6SXSABRESD=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -1,3 +1,8 @@
|
||||
CONFIG_ARM=y
|
||||
CONFIG_OMAP34XX=y
|
||||
CONFIG_TARGET_NOKIA_RX51=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -3,3 +3,6 @@ CONFIG_SYS_EXTRA_OPTIONS="NAND"
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_OMAP3_BEAGLE=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_DM_SERIAL=y
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_OMAP3_EVM=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_OMAP3_EVM_QUICK_MMC=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_OMAP3_EVM_QUICK_NAND=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -3,3 +3,6 @@ CONFIG_SYS_EXTRA_OPTIONS="SYS_BOARD_OMAP3_HA"
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_TAO3530=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -1,3 +1,6 @@
|
||||
CONFIG_ARM=y
|
||||
CONFIG_OMAP34XX=y
|
||||
CONFIG_TARGET_OMAP3_LOGIC=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -1,3 +1,6 @@
|
||||
CONFIG_ARM=y
|
||||
CONFIG_OMAP34XX=y
|
||||
CONFIG_TARGET_OMAP3_MVBLX=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -1,3 +1,6 @@
|
||||
CONFIG_ARM=y
|
||||
CONFIG_OMAP34XX=y
|
||||
CONFIG_TARGET_OMAP3_PANDORA=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -1,3 +1,6 @@
|
||||
CONFIG_ARM=y
|
||||
CONFIG_OMAP34XX=y
|
||||
CONFIG_TARGET_OMAP3_SDP3430=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,5 @@ CONFIG_SPL=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="REV1"
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_PCM051=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -2,3 +2,5 @@ CONFIG_SPL=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="REV3"
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_PCM051=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -1,3 +1,5 @@
|
||||
CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_PENGWYN=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -1,3 +1,5 @@
|
||||
CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_TARGET_PEPPER=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -1,2 +1,4 @@
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_RPI=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -2,3 +2,5 @@ CONFIG_ARM=y
|
||||
CONFIG_ARCH_S5PC1XX=y
|
||||
CONFIG_TARGET_S5P_GONI=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="s5pc1xx-goni"
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -5,3 +5,5 @@ CONFIG_FIT_VERBOSE=y
|
||||
CONFIG_FIT_SIGNATURE=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="sandbox"
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -2,3 +2,5 @@ CONFIG_ARM=y
|
||||
CONFIG_TARGET_SMDKC100=y
|
||||
CONFIG_ARCH_S5PC1XX=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="s5pc1xx-smdkc100"
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -1,3 +1,8 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="AT91SAM9260"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_SNAPPER9260=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_DM_SERIAL=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -1,3 +1,8 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="AT91SAM9G20"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_SNAPPER9260=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_DM_SERIAL=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x400
|
||||
|
@ -3,3 +3,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_TARGET_SOCFPGA_CYCLONE5=y
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="socfpga_cyclone5_socrates"
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_SPI=y
|
||||
CONFIG_DM_SPI_FLASH=y
|
||||
|
@ -1,3 +1,7 @@
|
||||
CONFIG_SYS_EXTRA_OPTIONS="stv0991"
|
||||
CONFIG_ARM=y
|
||||
CONFIG_TARGET_STV0991=y
|
||||
CONFIG_SYS_MALLOC_F=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x2000
|
||||
CONFIG_DM=y
|
||||
CONFIG_DM_SERIAL=y
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_TAO3530=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_TRICORDER=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -3,3 +3,6 @@ CONFIG_SYS_EXTRA_OPTIONS="FLASHCARD"
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_TRICORDER=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -2,3 +2,6 @@ CONFIG_SPL=y
|
||||
+S:CONFIG_ARM=y
|
||||
+S:CONFIG_OMAP34XX=y
|
||||
+S:CONFIG_TARGET_TWISTER=y
|
||||
CONFIG_DM=n
|
||||
CONFIG_DM_SERIAL=n
|
||||
CONFIG_DM_GPIO=n
|
||||
|
@ -40,8 +40,8 @@ with only minor changes:
|
||||
|
||||
Add these to your board config:
|
||||
|
||||
#define CONFIG_DM_SPI
|
||||
#define CONFIG_DM_SPI_FLASH
|
||||
CONFIG_DM_SPI
|
||||
CONFIG_DM_SPI_FLASH
|
||||
|
||||
|
||||
2. Add the skeleton
|
||||
|
@ -2,6 +2,8 @@ menu "Device Drivers"
|
||||
|
||||
source "drivers/core/Kconfig"
|
||||
|
||||
source "drivers/demo/Kconfig"
|
||||
|
||||
source "drivers/pci/Kconfig"
|
||||
|
||||
source "drivers/pcmcia/Kconfig"
|
||||
@ -48,4 +50,6 @@ source "drivers/dma/Kconfig"
|
||||
|
||||
source "drivers/crypto/Kconfig"
|
||||
|
||||
source "drivers/thermal/Kconfig"
|
||||
|
||||
endmenu
|
||||
|
@ -2,5 +2,51 @@ config DM
|
||||
bool "Enable Driver Model"
|
||||
depends on !SPL_BUILD
|
||||
help
|
||||
This config option enables Driver Model.
|
||||
To use legacy drivers, say N.
|
||||
This config option enables Driver Model. This brings in the core
|
||||
support, including scanning of platform data on start-up. If
|
||||
CONFIG_OF_CONTROL is enabled, the device tree will be scanned also
|
||||
when available.
|
||||
|
||||
config SPL_DM
|
||||
bool "Enable Driver Model for SPL"
|
||||
depends on DM && SPL
|
||||
help
|
||||
Enable driver model in SPL. You will need to provide a
|
||||
suitable malloc() implementation. If you are not using the
|
||||
full malloc() enabled by CONFIG_SYS_SPL_MALLOC_START,
|
||||
consider using CONFIG_SYS_MALLOC_SIMPLE. In that case you
|
||||
must provide CONFIG_SYS_MALLOC_F_LEN to set the size.
|
||||
In most cases driver model will only allocate a few uclasses
|
||||
and devices in SPL, so 1KB should be enable. See
|
||||
CONFIG_SYS_MALLOC_F_LEN for more details on how to enable it.
|
||||
|
||||
config DM_WARN
|
||||
bool "Enable warnings in driver model"
|
||||
help
|
||||
The dm_warn() function can use up quite a bit of space for its
|
||||
strings. By default this is disabled for SPL builds to save space.
|
||||
This will cause dm_warn() to be compiled out - it will do nothing
|
||||
when called.
|
||||
depends on DM
|
||||
default y if !SPL_BUILD
|
||||
default n if SPL_BUILD
|
||||
|
||||
config DM_DEVICE_REMOVE
|
||||
bool "Support device removal"
|
||||
help
|
||||
We can save some code space by dropping support for removing a
|
||||
device. This is not normally required in SPL, so by default this
|
||||
option is disabled for SPL.
|
||||
depends on DM
|
||||
default y if !SPL_BUILD
|
||||
default n if SPL_BUILD
|
||||
|
||||
config DM_STDIO
|
||||
bool "Support stdio registration"
|
||||
help
|
||||
Normally serial drivers register with stdio so that they can be used
|
||||
as normal output devices. In SPL we don't normally use stdio, so
|
||||
we can omit this feature.
|
||||
depends on DM
|
||||
default y if !SPL_BUILD
|
||||
default n if SPL_BUILD
|
||||
|
@ -449,3 +449,15 @@ enum uclass_id device_get_uclass_id(struct udevice *dev)
|
||||
{
|
||||
return dev->uclass->uc_drv->id;
|
||||
}
|
||||
|
||||
#ifdef CONFIG_OF_CONTROL
|
||||
fdt_addr_t dev_get_addr(struct udevice *dev)
|
||||
{
|
||||
return fdtdec_get_addr(gd->fdt_blob, dev->of_offset, "reg");
|
||||
}
|
||||
#else
|
||||
fdt_addr_t dev_get_addr(struct udevice *dev)
|
||||
{
|
||||
return FDT_ADDR_T_NONE;
|
||||
}
|
||||
#endif
|
||||
|
@ -37,6 +37,65 @@ struct udevice *dm_root(void)
|
||||
return gd->dm_root;
|
||||
}
|
||||
|
||||
#if defined(CONFIG_NEEDS_MANUAL_RELOC)
|
||||
void fix_drivers(void)
|
||||
{
|
||||
struct driver *drv =
|
||||
ll_entry_start(struct driver, driver);
|
||||
const int n_ents = ll_entry_count(struct driver, driver);
|
||||
struct driver *entry;
|
||||
|
||||
for (entry = drv; entry != drv + n_ents; entry++) {
|
||||
if (entry->of_match)
|
||||
entry->of_match = (const struct udevice_id *)
|
||||
((u32)entry->of_match + gd->reloc_off);
|
||||
if (entry->bind)
|
||||
entry->bind += gd->reloc_off;
|
||||
if (entry->probe)
|
||||
entry->probe += gd->reloc_off;
|
||||
if (entry->remove)
|
||||
entry->remove += gd->reloc_off;
|
||||
if (entry->unbind)
|
||||
entry->unbind += gd->reloc_off;
|
||||
if (entry->ofdata_to_platdata)
|
||||
entry->ofdata_to_platdata += gd->reloc_off;
|
||||
if (entry->child_pre_probe)
|
||||
entry->child_pre_probe += gd->reloc_off;
|
||||
if (entry->child_post_remove)
|
||||
entry->child_post_remove += gd->reloc_off;
|
||||
/* OPS are fixed in every uclass post_probe function */
|
||||
if (entry->ops)
|
||||
entry->ops += gd->reloc_off;
|
||||
}
|
||||
}
|
||||
|
||||
void fix_uclass(void)
|
||||
{
|
||||
struct uclass_driver *uclass =
|
||||
ll_entry_start(struct uclass_driver, uclass);
|
||||
const int n_ents = ll_entry_count(struct uclass_driver, uclass);
|
||||
struct uclass_driver *entry;
|
||||
|
||||
for (entry = uclass; entry != uclass + n_ents; entry++) {
|
||||
if (entry->post_bind)
|
||||
entry->post_bind += gd->reloc_off;
|
||||
if (entry->pre_unbind)
|
||||
entry->pre_unbind += gd->reloc_off;
|
||||
if (entry->post_probe)
|
||||
entry->post_probe += gd->reloc_off;
|
||||
if (entry->pre_remove)
|
||||
entry->pre_remove += gd->reloc_off;
|
||||
if (entry->init)
|
||||
entry->init += gd->reloc_off;
|
||||
if (entry->destroy)
|
||||
entry->destroy += gd->reloc_off;
|
||||
/* FIXME maybe also need to fix these ops */
|
||||
if (entry->ops)
|
||||
entry->ops += gd->reloc_off;
|
||||
}
|
||||
}
|
||||
#endif
|
||||
|
||||
int dm_init(void)
|
||||
{
|
||||
int ret;
|
||||
@ -47,6 +106,11 @@ int dm_init(void)
|
||||
}
|
||||
INIT_LIST_HEAD(&DM_UCLASS_ROOT_NON_CONST);
|
||||
|
||||
#if defined(CONFIG_NEEDS_MANUAL_RELOC)
|
||||
fix_drivers();
|
||||
fix_uclass();
|
||||
#endif
|
||||
|
||||
ret = device_bind_by_name(NULL, false, &root_info, &DM_ROOT_NON_CONST);
|
||||
if (ret)
|
||||
return ret;
|
||||
|
26
drivers/demo/Kconfig
Normal file
26
drivers/demo/Kconfig
Normal file
@ -0,0 +1,26 @@
|
||||
config DM_DEMO
|
||||
bool "Enable demo uclass support"
|
||||
depends on DM
|
||||
help
|
||||
This uclass allows you to play around with driver model. It provides
|
||||
an interface to a couple of demo devices. You can access it using
|
||||
the 'demo' command or by calling the uclass functions from your
|
||||
own code.
|
||||
|
||||
config DM_DEMO_SIMPLE
|
||||
bool "Enable simple demo device for driver model"
|
||||
depends on DM_DEMO
|
||||
help
|
||||
This device allows you to play around with driver model. It prints
|
||||
a message when the 'demo hello' command is executed which targets
|
||||
this device. It can be used to help understand how driver model
|
||||
works.
|
||||
|
||||
config DM_DEMO_SHAPE
|
||||
bool "Enable shape demo device for driver model"
|
||||
depends on DM_DEMO
|
||||
help
|
||||
This device allows you to play around with driver model. It prints
|
||||
a shape when the 'demo hello' command is executed which targets
|
||||
this device. It can be used to help understand how driver model
|
||||
works.
|
@ -2,5 +2,8 @@ config DM_GPIO
|
||||
bool "Enable Driver Model for GPIO drivers"
|
||||
depends on DM
|
||||
help
|
||||
If you want to use driver model for GPIO drivers, say Y.
|
||||
To use legacy GPIO drivers, say N.
|
||||
Enable driver model for GPIO access. The standard GPIO
|
||||
interface (gpio_get_value(), etc.) is then implemented by
|
||||
the GPIO uclass. Drivers provide methods to query the
|
||||
particular GPIOs that they provide. The uclass interface
|
||||
is defined in include/asm-generic/gpio.h.
|
||||
|
@ -451,7 +451,7 @@ struct at91_port_priv {
|
||||
/* set GPIO pin 'gpio' as an input */
|
||||
static int at91_gpio_direction_input(struct udevice *dev, unsigned offset)
|
||||
{
|
||||
struct at91_port_priv *port = dev_get_platdata(dev);
|
||||
struct at91_port_priv *port = dev_get_priv(dev);
|
||||
|
||||
at91_set_port_input(port->regs, offset, 0);
|
||||
|
||||
@ -462,7 +462,7 @@ static int at91_gpio_direction_input(struct udevice *dev, unsigned offset)
|
||||
static int at91_gpio_direction_output(struct udevice *dev, unsigned offset,
|
||||
int value)
|
||||
{
|
||||
struct at91_port_priv *port = dev_get_platdata(dev);
|
||||
struct at91_port_priv *port = dev_get_priv(dev);
|
||||
|
||||
at91_set_port_output(port->regs, offset, value);
|
||||
|
||||
@ -472,7 +472,7 @@ static int at91_gpio_direction_output(struct udevice *dev, unsigned offset,
|
||||
/* read GPIO IN value of pin 'gpio' */
|
||||
static int at91_gpio_get_value(struct udevice *dev, unsigned offset)
|
||||
{
|
||||
struct at91_port_priv *port = dev_get_platdata(dev);
|
||||
struct at91_port_priv *port = dev_get_priv(dev);
|
||||
|
||||
return at91_get_port_value(port->regs, offset);
|
||||
}
|
||||
@ -481,7 +481,7 @@ static int at91_gpio_get_value(struct udevice *dev, unsigned offset)
|
||||
static int at91_gpio_set_value(struct udevice *dev, unsigned offset,
|
||||
int value)
|
||||
{
|
||||
struct at91_port_priv *port = dev_get_platdata(dev);
|
||||
struct at91_port_priv *port = dev_get_priv(dev);
|
||||
|
||||
at91_set_port_value(port->regs, offset, value);
|
||||
|
||||
@ -490,7 +490,7 @@ static int at91_gpio_set_value(struct udevice *dev, unsigned offset,
|
||||
|
||||
static int at91_gpio_get_function(struct udevice *dev, unsigned offset)
|
||||
{
|
||||
struct at91_port_priv *port = dev_get_platdata(dev);
|
||||
struct at91_port_priv *port = dev_get_priv(dev);
|
||||
|
||||
/* GPIOF_FUNC is not implemented yet */
|
||||
if (at91_get_port_output(port->regs, offset))
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user