[BPI-R64] open source ATF

atf

F0: 102B 0000
F5: 0000 0000
V0: 0000 0000 [0001]
00: 0000 0000
BP: 0400 0041 [0000]
G0: 1190 0000
T0: 0000 0277 [000F]
Jump to BL

NOTICE:  BL2: v2.2(release):
NOTICE:  BL2: Built : 07:17:31, Nov 27 2020
NOTICE:  GPT bl2 > start:524288 length:131072 byte
NOTICE:  GPT fip > start:655360 length:1048576 byte
NOTICE:  GPT boot > start:1703936 length:33554432 byte
NOTICE:  GPT root > start:35258368 length:7711588864 byte
NOTICE:  BL2: Booting BL31
NOTICE:  BL31: v2.4(release):
NOTICE:  BL31: Built : 06:39:13, Jan 20 2021

BL2: v2.2(release) and BL31: v2.4(release)?

it depends on what you have flashed…it should be both 2.4…remember that bl2 on emmc is on separate partition

I guess you boot from emmc and missed flashing bl2 in boot0…builddate of bl2 is Nov 27 2020,bl31 is Jan 20 2021 :slight_smile:

my sdcard (new Bootchain by flashing the full img) looks like this:

F0: 102B 0000
F5: 0000 0000
V0: 0000 0000 [0001]
00: 0000 0000
BP: 0400 0041 [0000]
G0: 1190 0000
T0: 0000 0359 [000F]
Jump to BL

NOTICE:  BL2: v2.4(release):v2.4-15-g54397dca8
NOTICE:  BL2: Built : 19:09:59, Jan 15 2021
NOTICE:  BL2: Booting BL31
NOTICE:  BL31: v2.4(release):v2.4-15-g54397dca8
NOTICE:  BL31: Built : 19:10:01, Jan 15 2021


U-Boot 2021.01-bpi (Jan 13 2021 - 19:46:11 +0100)

whereas booting my emmc shows this:

F0: 102B 0000
F5: 480A 0031
F5: 480A 0031
F3: 0000 0000
V0: 0000 0000 [0001]
00: 0000 0000
BP: 0400 0041 [0000]
G0: 1190 0000
T0: 0000 02D2 [000F]
Jump to BL

NOTICE:  BL2: v2.2(release):CI-BUILD-20201124_181406-d407ab2-dirty
NOTICE:  BL2: Built : 10:44:17, Nov 29 2020
NOTICE:  BL2: Booting BL31
NOTICE:  BL31: v2.2(release):CI-BUILD-20201124_181406-d407ab2-dirty
NOTICE:  BL31: Built : 11:05:15, Nov 29 2020


U-Boot 2020.10-bpi (Nov 29 2020 - 11:04:35 +0100)

i don’t know why bootrom differs also on emmc-bootup…i expected it would be same

i have tested the new uboot and cannot solve the sdcard problem

ok, so reset is still needed in linux? thanks for testing

have you got the bl2 to new version??

yeah, I updated to the latest version, which I added in atf drivers/partition/gpt.c,to view the partition table:

int parse_gpt_entry (gpt_entry_t * gpt_entry, partition_entry_t * entry)
{
.
.
.
NOTICE ("GPT%s>start:%lld length:%lld bytes\n", input -> name, input -> start, input -> length);
Return 0;
}

information:

F0: 102B 0000
F5: 0000 0000
V0: 0000 0000 [0001]
00: 0000 0000
BP: 0400 0041 [0000]
G0: 1190 0000
T0: 0000 0277 [000F]
Jump to BL

NOTICE:  BL2: v2.4(release):
NOTICE:  BL2: Built : 23:20:04, Jan 20 2021
NOTICE:  GPT bl2 > start:524288 length:131072 byte
NOTICE:  GPT fip > start:655360 length:1048576 byte
NOTICE:  GPT boot > start:1703936 length:33554432 byte
NOTICE:  GPT root > start:35258368 length:7711588864 byte
NOTICE:  BL2: Booting BL31
NOTICE:  BL31: v2.4(release):
NOTICE:  BL31: Built : 23:20:17, Jan 20 2021


U-Boot 2021.01 (Jan 20 2021 - 23:17:41 -0900)

CPU:   MediaTek MT7622
Model: mt7622-rfb
DRAM:  256 MiB
WDT:   Started with servicing (60s timeout)
MMC:   mmc@11230000: 0, mmc@11240000: 1
In:    serial@11002000
Out:   serial@11002000
Err:   serial@11002000
Net:   
Warning: ethernet@1b100000 (eth0) using random MAC address - 66:35:7e:ed:d2:ad
eth0: ethernet@1b100000
Hit any key to stop autoboot:  0 
575 bytes read in 2 ms (280.3 KiB/s)
10078216 bytes read in 678 ms (14.2 MiB/s)
24679 bytes read in 5 ms (4.7 MiB/s)
Moving Image from 0x44000000 to 0x44080000, end=44a6d000
## Flattened Device Tree blob at 47000000
   Booting using the fdt blob at 0x47000000
   Loading Device Tree to 000000004f7f1000, end 000000004f7fa066 ... OK

Starting kernel ...

mt7622.dtsi must add resets:

mmc0: 
resets = <&pericfg MT7622_PERI_MSDC0_SW_RST>;
reset-names = "hrst";

mmc1: 
resets = <&pericfg MT7622_PERI_MSDC1_SW_RST>;
reset-names = "hrst";

now your bl2 is 2.4… :slight_smile:

sd-card fix is nearly upstream for 5.12

https://git.kernel.org/pub/scm/linux/kernel/git/soc/soc.git/log/?h=arm/dt

and i got uboot via TFTP working with new bootchain :wink: needs “dcache off” before go command

@skype have you an idea how to write a flag with bl2 which can be read from uboot to determine device booted from (emmc or sdcard)?

Btw is this your repo: https://github.com/colorhacker/BPI-R64-ATF ? Change in master (without r64 support) looks like your change