2016-11-26 03:16:01 +00:00
|
|
|
#include <config.h>
|
|
|
|
|
2020-10-22 02:12:12 +00:00
|
|
|
#ifdef CONFIG_MACH_SUN50I_H6
|
|
|
|
#define BL31_ADDR 0x104000
|
2020-10-22 02:12:16 +00:00
|
|
|
#define SCP_ADDR 0x114000
|
2021-01-11 20:11:46 +00:00
|
|
|
#elif defined(CONFIG_MACH_SUN50I_H616)
|
2021-03-25 16:20:13 +00:00
|
|
|
#define BL31_ADDR 0x40000000
|
2020-10-22 02:12:12 +00:00
|
|
|
#else
|
|
|
|
#define BL31_ADDR 0x44000
|
2020-10-22 02:12:16 +00:00
|
|
|
#define SCP_ADDR 0x50000
|
2020-10-22 02:12:12 +00:00
|
|
|
#endif
|
|
|
|
|
2016-11-26 03:16:01 +00:00
|
|
|
/ {
|
arm: dts: sunxi: Alter mmc2 auto-numbering to mmc1
Environment and fastboot mmc devices are configured based on the number
of mmc slots defined on particular board configs, MMC_SUNXI_SLOT_EXTRA.
If MMC_SUNXI_SLOT_EXTRA is more than 1, the default env and fastboot
mmc devices is mmc1 by assuming mmc0 is SD and mmc1 is emmc device.
But with DM_MMC the mmc devices are numbered as per the dts node
enablement. If there is a chance of having enabling all mmc nodes
in dts say mmc0, mmc1, mmc2 then the default env and fastboot devices
will failed to assign proper emmc device since mmc2 is emmc in most
of the Allwinner platforms.
So, we need to alter the auto-numbering by aliasing mmc2 to mmc1 since
aliases take precedence over auto-numbering.
If the dts enables mmc0, mmc1, mmc2, then all the nodes will probe
sequentially and auto-numbered as it is. but when aliases mmc1 with mmc2
the resulting number should be that mmc0 is till mmc0, mmc2 become mmc1
and mmc2 become mmc1
Without aliases of mmc1 = &mmc2;
-------------------------------
MMC: mmc@1c0f000: 0, mmc@1c10000: 1, mmc@1c11000: 2
With aliases of mmc1 = &mmc2;
----------------------------
MMC: Device 'mmc@1c11000': seq 1 is in use by 'mmc@1c10000'
mmc@1c0f000: 0, mmc@1c10000: 2, mmc@1c11000: 1
Loading Environment from FAT... OK
Some platforms like A20 has mmc0...mmc3, but there is no usecases now
for enabling all mmc controllers in any of A20 board dts files.
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
2019-01-21 10:31:15 +00:00
|
|
|
aliases {
|
2021-04-16 10:52:27 +00:00
|
|
|
mmc0 = &mmc0;
|
2021-07-22 06:30:04 +00:00
|
|
|
#if CONFIG_MMC_SUNXI_EXTRA_SLOT == 2
|
arm: dts: sunxi: Alter mmc2 auto-numbering to mmc1
Environment and fastboot mmc devices are configured based on the number
of mmc slots defined on particular board configs, MMC_SUNXI_SLOT_EXTRA.
If MMC_SUNXI_SLOT_EXTRA is more than 1, the default env and fastboot
mmc devices is mmc1 by assuming mmc0 is SD and mmc1 is emmc device.
But with DM_MMC the mmc devices are numbered as per the dts node
enablement. If there is a chance of having enabling all mmc nodes
in dts say mmc0, mmc1, mmc2 then the default env and fastboot devices
will failed to assign proper emmc device since mmc2 is emmc in most
of the Allwinner platforms.
So, we need to alter the auto-numbering by aliasing mmc2 to mmc1 since
aliases take precedence over auto-numbering.
If the dts enables mmc0, mmc1, mmc2, then all the nodes will probe
sequentially and auto-numbered as it is. but when aliases mmc1 with mmc2
the resulting number should be that mmc0 is till mmc0, mmc2 become mmc1
and mmc2 become mmc1
Without aliases of mmc1 = &mmc2;
-------------------------------
MMC: mmc@1c0f000: 0, mmc@1c10000: 1, mmc@1c11000: 2
With aliases of mmc1 = &mmc2;
----------------------------
MMC: Device 'mmc@1c11000': seq 1 is in use by 'mmc@1c10000'
mmc@1c0f000: 0, mmc@1c10000: 2, mmc@1c11000: 1
Loading Environment from FAT... OK
Some platforms like A20 has mmc0...mmc3, but there is no usecases now
for enabling all mmc controllers in any of A20 board dts files.
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
2019-01-21 10:31:15 +00:00
|
|
|
mmc1 = &mmc2;
|
2021-07-22 06:30:04 +00:00
|
|
|
#endif
|
arm: dts: sunxi: Alter mmc2 auto-numbering to mmc1
Environment and fastboot mmc devices are configured based on the number
of mmc slots defined on particular board configs, MMC_SUNXI_SLOT_EXTRA.
If MMC_SUNXI_SLOT_EXTRA is more than 1, the default env and fastboot
mmc devices is mmc1 by assuming mmc0 is SD and mmc1 is emmc device.
But with DM_MMC the mmc devices are numbered as per the dts node
enablement. If there is a chance of having enabling all mmc nodes
in dts say mmc0, mmc1, mmc2 then the default env and fastboot devices
will failed to assign proper emmc device since mmc2 is emmc in most
of the Allwinner platforms.
So, we need to alter the auto-numbering by aliasing mmc2 to mmc1 since
aliases take precedence over auto-numbering.
If the dts enables mmc0, mmc1, mmc2, then all the nodes will probe
sequentially and auto-numbered as it is. but when aliases mmc1 with mmc2
the resulting number should be that mmc0 is till mmc0, mmc2 become mmc1
and mmc2 become mmc1
Without aliases of mmc1 = &mmc2;
-------------------------------
MMC: mmc@1c0f000: 0, mmc@1c10000: 1, mmc@1c11000: 2
With aliases of mmc1 = &mmc2;
----------------------------
MMC: Device 'mmc@1c11000': seq 1 is in use by 'mmc@1c10000'
mmc@1c0f000: 0, mmc@1c10000: 2, mmc@1c11000: 1
Loading Environment from FAT... OK
Some platforms like A20 has mmc0...mmc3, but there is no usecases now
for enabling all mmc controllers in any of A20 board dts files.
Signed-off-by: Jagan Teki <jagan@amarulasolutions.com>
2019-01-21 10:31:15 +00:00
|
|
|
};
|
|
|
|
|
2020-09-01 11:14:01 +00:00
|
|
|
binman: binman {
|
|
|
|
multiple-images;
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
&binman {
|
|
|
|
u-boot-sunxi-with-spl {
|
2016-11-26 03:16:01 +00:00
|
|
|
filename = "u-boot-sunxi-with-spl.bin";
|
|
|
|
pad-byte = <0xff>;
|
2020-10-22 02:12:10 +00:00
|
|
|
|
2016-11-26 03:16:01 +00:00
|
|
|
blob {
|
|
|
|
filename = "spl/sunxi-spl.bin";
|
|
|
|
};
|
2020-10-22 02:12:10 +00:00
|
|
|
|
2020-09-01 11:14:01 +00:00
|
|
|
#ifdef CONFIG_ARM64
|
|
|
|
fit {
|
|
|
|
description = "Configuration to load ATF before U-Boot";
|
|
|
|
#address-cells = <1>;
|
|
|
|
fit,fdt-list = "of-list";
|
|
|
|
|
|
|
|
images {
|
|
|
|
uboot {
|
|
|
|
description = "U-Boot (64-bit)";
|
|
|
|
type = "standalone";
|
2020-10-22 02:12:14 +00:00
|
|
|
os = "u-boot";
|
2020-09-01 11:14:01 +00:00
|
|
|
arch = "arm64";
|
|
|
|
compression = "none";
|
2021-02-08 06:03:17 +00:00
|
|
|
load = <CONFIG_SYS_TEXT_BASE>;
|
2020-09-01 11:14:01 +00:00
|
|
|
|
|
|
|
u-boot-nodtb {
|
|
|
|
};
|
|
|
|
};
|
2020-10-22 02:12:10 +00:00
|
|
|
|
2020-09-01 11:14:01 +00:00
|
|
|
atf {
|
|
|
|
description = "ARM Trusted Firmware";
|
|
|
|
type = "firmware";
|
2020-10-22 02:12:14 +00:00
|
|
|
os = "arm-trusted-firmware";
|
2020-09-01 11:14:01 +00:00
|
|
|
arch = "arm64";
|
|
|
|
compression = "none";
|
2020-10-22 02:12:12 +00:00
|
|
|
load = <BL31_ADDR>;
|
|
|
|
entry = <BL31_ADDR>;
|
2020-10-22 02:12:10 +00:00
|
|
|
|
2020-09-01 11:14:01 +00:00
|
|
|
atf-bl31 {
|
2020-10-22 02:12:11 +00:00
|
|
|
filename = "bl31.bin";
|
2020-09-06 16:39:10 +00:00
|
|
|
missing-msg = "atf-bl31-sunxi";
|
2020-09-01 11:14:01 +00:00
|
|
|
};
|
|
|
|
};
|
|
|
|
|
2021-07-22 06:30:03 +00:00
|
|
|
#ifdef SCP_ADDR
|
2020-10-22 02:12:16 +00:00
|
|
|
scp {
|
|
|
|
description = "SCP firmware";
|
|
|
|
type = "firmware";
|
|
|
|
arch = "or1k";
|
|
|
|
compression = "none";
|
|
|
|
load = <SCP_ADDR>;
|
|
|
|
|
|
|
|
scp {
|
|
|
|
filename = "scp.bin";
|
|
|
|
missing-msg = "scp-sunxi";
|
|
|
|
};
|
|
|
|
};
|
2021-01-11 20:11:46 +00:00
|
|
|
#endif
|
2020-10-22 02:12:16 +00:00
|
|
|
|
2020-09-01 11:14:01 +00:00
|
|
|
@fdt-SEQ {
|
|
|
|
description = "NAME";
|
|
|
|
type = "flat_dt";
|
|
|
|
compression = "none";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
|
|
|
|
configurations {
|
2021-02-08 06:03:16 +00:00
|
|
|
default = "@config-DEFAULT-SEQ";
|
2020-10-22 02:12:10 +00:00
|
|
|
|
2020-09-01 11:14:01 +00:00
|
|
|
@config-SEQ {
|
|
|
|
description = "NAME";
|
2020-10-22 02:12:14 +00:00
|
|
|
firmware = "atf";
|
2021-07-22 06:30:03 +00:00
|
|
|
#ifndef SCP_ADDR
|
2021-01-11 20:11:46 +00:00
|
|
|
loadables = "uboot";
|
|
|
|
#else
|
2020-10-22 02:12:16 +00:00
|
|
|
loadables = "scp", "uboot";
|
2021-01-11 20:11:46 +00:00
|
|
|
#endif
|
2020-09-01 11:14:01 +00:00
|
|
|
fdt = "fdt-SEQ";
|
|
|
|
};
|
|
|
|
};
|
|
|
|
};
|
|
|
|
#else
|
2016-11-26 03:16:01 +00:00
|
|
|
u-boot-img {
|
2018-08-01 21:22:37 +00:00
|
|
|
offset = <CONFIG_SPL_PAD_TO>;
|
2016-11-26 03:16:01 +00:00
|
|
|
};
|
2020-09-01 11:14:01 +00:00
|
|
|
#endif
|
2016-11-26 03:16:01 +00:00
|
|
|
};
|
|
|
|
};
|