en:bpi-r4:uboot
U-boot
NAND
compared to bpi-r3 fip on r4 is at position 0x580000 (plat/mediatek/mt7988/bl2/bl2_dev_spi_nand.c #define FIP_BASE 0x580000)
BPI-R4> mtd list spi-nand: spi_nand spi_nand@0: Winbond SPI NAND was found. spi-nand: spi_nand spi_nand@0: 128 MiB, block size: 128 KiB, page size: 2048, O4 List of MTD devices: * spi-nand0 - device: spi_nand@0 - parent: spi@1100a000 - driver: spi_nand - path: /spi@1100a000/spi_nand@0 - type: NAND flash - block size: 0x20000 bytes - min I/O: 0x800 bytes - OOB size: 64 bytes - OOB available: 24 bytes - 0x000000000000-0x000008000000 : "spi-nand0" BPI-R4> ls usb 0:1 u-boot_2024-10 ./ ../ 254821 bpi-r4_spim-nand_bl2.img 295477 bpi-r4_spim-nand_fip.bin 295409 bpi-r4_emmc_fip.bin 246069 bpi-r4_emmc_bl2.img 7874804 bpi-r4_emmc.img.gz 5 file(s), 2 dir(s) BPI-R4> mtd erase spi-nand0 Erasing 0x00000000 ... 0x07ffffff (1024 eraseblock(s)) BPI-R4> load usb 0:1 $loadaddr u-boot_2024-10/bpi-r4_spim-nand_bl2.img 254821 bytes read in 29 ms (8.4 MiB/s) BPI-R4> mtd write spi-nand0 $loadaddr 0x0 0x100000 Writing 1048576 byte(s) (512 page(s)) at offset 0x00000000 BPI-R4> BPI-R4> load usb 0:1 $loadaddr u-boot_2024-10/bpi-r4_spim-nand_fip.bin 295477 bytes read in 35 ms (8.1 MiB/s) BPI-R4> mtd write spi-nand0 $loadaddr 0x580000 0x200000 Writing 2097152 byte(s) (1024 page(s)) at offset 0x00580000 BPI-R4>
debug
devicetree
how to display uboot devicetree
BPI-R4> bdinfo ... fdt_blob = 0x00000000ff7fbc90 ... BPI-R4> fdt addr 0x00000000ff7fbc90 BPI-R4> fdt list BPI-R4> fdt print /pcie@11290000
pinmux
BPI-R4> pinmux list | Device | Driver | Parent | pinctrl@1001f000 | mt7988_pinctrl | root_driver BPI-R4> pinmux dev pinctrl@1001f000 dev: pinctrl@1001f000 BPI-R4> pinmux status ... PCIE30_2L : Aux Func.1 PCIE30_2L : Aux Func.1 PCIE30_1L : Aux Func.1 PCIE30_1L : Aux Func.1 ... PCIE30_2L : Aux Func.1 PCIE30_1L : Aux Func.1 ... PCIE30_2L : Aux Func.1 PCIE30_1L : Aux Func.1 PCIE30_2L : Aux Func.1 PCIE30_2L : Aux Func.1 PCIE30_1L : Aux Func.1 PCIE30_1L : Aux Func.1
clocks
BPI-R4> clk dump Rate Usecnt Name ------------------------------------------ 40000000 0 |-- dummy40m 208000000 0 |-- dummy208m 12000000 0 |-- dummy12m BPI-R4>
en/bpi-r4/uboot.txt · Last modified: 2024/10/28 11:27 by frank