Hi Anand,

Thanks for sending this. I tested the series on a Milk-V Jupiter,
booting from SD. It reaches the U-Boot prompt, but the SPL no longer
finds the PMIC:

  Get board name:k1-x_milkv-jupiter
  No PMIC (-19), leaving rails as found
  DDR firmware: [0xc0820740]:0xf0227179, size:0x8d98

With a Jupiter -u-boot.dtsi that has the same i2c8/pmic block this
patch removes, the SPL sets the rails before DDR init:

  vdd_core, value:900000
  vdd_1v8, value:1800000
  vdd_1v8_mmc, value:3300000

The commit message says the regulator configuration moves to
dts/upstream, but k1-milkv-jupiter.dts there has no bootph tags and no
vdd_core/vdd_1v8/vdd_1v8_mmc names, so the PMIC is not in the SPL
device tree and pmic_init() skips it. It works on this board only
because the rails come up at usable voltages. How do you plan to let
the SPL find the rails?

The new file is also not picked up until 6/6. U-Boot includes
<dtb>-u-boot.dtsi, $(SYS_SOC)-u-boot.dtsi, $(SYS_CPU)-u-boot.dtsi,
$(SYS_VENDOR)-u-boot.dtsi and u-boot.dtsi (scripts/Makefile.lib),
which on K1 means k1-u-boot.dtsi or spacemit-u-boot.dtsi. Nothing
includes spacemit-k1-u-boot.dtsi until 6/6 sets
CONFIG_DEVICE_TREE_INCLUDES, so 1/6 to 5/6 build without any K1
overlay, which breaks bisection. I have not built each step. Naming the
file k1-u-boot.dtsi would get it included from this patch on, and 6/6
would not need DEVICE_TREE_INCLUDES.

The MusePi Pro overlay also set sdhci0's cd-gpios to GPIO 80 active
low, while k1-musepi-pro.dts in dts/upstream has it active high, so
removing the override flips card detect on that board. Was the
override fixing the upstream polarity?

Two other things I saw, neither caused by this series: the SPI NOR on
the Jupiter is a GigaDevice part (JEDEC c8 40 17), which needs
"configs: k1: enable GigaDevice SPI NOR flash support" [1], and
U-Boot reports 8 GiB on this 4 GiB board, a known issue in
ddr_get_density().

[1] 
https://lore.kernel.org/u-boot/[email protected]/

Thanks,
Hung-Chun

Reply via email to