Tartarus changed the topic of #u-boot to: SOURCE MOVED TO https://source.denx.de/u-boot/u-boot.git / U-Boot v2024.01, v2024.04-rc4 are OUT / Merge Window is CLOSED, next branch is OPEN / Release v2024.04 is scheduled for 02 April 2024 / Channel archives at https://libera.irclog.whitequark.org/u-boot
joeskb7 has quit [Quit: Lost terminal]
slobodan_ has quit [Ping timeout: 260 seconds]
rvalue- has joined #u-boot
rvalue has quit [Ping timeout: 268 seconds]
rvalue- is now known as rvalue
qschulz has quit [Read error: Connection reset by peer]
germ has joined #u-boot
qschulz has joined #u-boot
stefanro has joined #u-boot
germ has quit [Changing host]
germ has joined #u-boot
germ has quit [Ping timeout: 260 seconds]
mmu_man has quit [Ping timeout: 252 seconds]
jclsn has quit [Ping timeout: 240 seconds]
jclsn has joined #u-boot
enok has joined #u-boot
lane_ has quit [Ping timeout: 255 seconds]
lane has joined #u-boot
enok has quit [Ping timeout: 260 seconds]
stefanro has quit [Ping timeout: 268 seconds]
rvalue has quit [Read error: Connection reset by peer]
rvalue has joined #u-boot
ikarso has quit [Quit: Connection closed for inactivity]
stefanro has joined #u-boot
mrnuke_ has quit [Ping timeout: 255 seconds]
mrnuke has joined #u-boot
Clamor has joined #u-boot
stefanro has quit [Ping timeout: 246 seconds]
stefanro has joined #u-boot
nehamalcom has joined #u-boot
gsz has joined #u-boot
Clamor has quit [Read error: Connection reset by peer]
Clamor has joined #u-boot
monstr has joined #u-boot
linfax has joined #u-boot
gsz has quit [Ping timeout: 268 seconds]
mckoan_ is now known as mckoan
Clamor has quit [Ping timeout: 252 seconds]
Clamor has joined #u-boot
sng has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
sng has joined #u-boot
Net147 has quit [Quit: Quit]
Net147 has joined #u-boot
Net147 has quit [Changing host]
Net147 has joined #u-boot
enok has joined #u-boot
prabhakalad has quit [Ping timeout: 260 seconds]
prabhakalad has joined #u-boot
gsz has joined #u-boot
enok has quit [Ping timeout: 240 seconds]
gsz has quit [Ping timeout: 256 seconds]
ikarso has joined #u-boot
enok has joined #u-boot
KREYREN has joined #u-boot
sszy has joined #u-boot
enok has quit [Ping timeout: 260 seconds]
enok has joined #u-boot
naoki has quit [Quit: naoki]
iprusov has quit [Quit: WeeChat 3.5]
<stgl> Hi, I am reverse engineering a device which has a serial port exposed on which I found u-boot output. I can stop autoboot with a key press and drop to the shell and the U-Boot> prompt appears. Problem is it doesn't echo any characters I type and nothing happens if I enter "sleep 10", "panic" or "help"
<stgl> It does print U-Boot> again if I press enter though, so I think it is reading the serial input
<stgl> Is there some built-in feature of u-boot that achieves this? Or is this some kind of obfuscation hack by the manufacturer?
enok has quit [Ping timeout: 252 seconds]
slobodan_ has joined #u-boot
enok has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
naoki has joined #u-boot
naoki has quit [Client Quit]
stefanro has quit [Ping timeout: 255 seconds]
enok has quit [Ping timeout: 256 seconds]
stefanro has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
gsz has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
slobodan_ has quit [Ping timeout: 256 seconds]
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
mmu_man has joined #u-boot
slobodan has joined #u-boot
stefanro has quit [Ping timeout: 272 seconds]
dsimic has quit [Ping timeout: 255 seconds]
dsimic has joined #u-boot
KREYREN has quit [Remote host closed the connection]
FergusL has quit [Changing host]
FergusL has joined #u-boot
stefanro has joined #u-boot
tgamblin has quit [Ping timeout: 264 seconds]
monstr has quit [Ping timeout: 252 seconds]
prabhakarlad has joined #u-boot
mmu_man has quit [Ping timeout: 252 seconds]
enok has joined #u-boot
mmu_man has joined #u-boot
monstr has joined #u-boot
Clamor has quit [Ping timeout: 268 seconds]
stefanro has quit [Ping timeout: 255 seconds]
Clamor has joined #u-boot
stefanro has joined #u-boot
edwinistrator24 has joined #u-boot
edwinistrator2 has quit [Ping timeout: 260 seconds]
edwinistrator24 is now known as edwinistrator2
tgamblin has joined #u-boot
<tlwoerner> qschulz: this patch https://source.denx.de/u-boot/u-boot/-/commit/3b95c03d5706255f39a8f1a0fa02045d4fd981df completely messes up the rock-pi-4b (for example)
<tlwoerner> i'm guessing that means the u-boot DT for this board is probably messed up
<qschulz> tlwoerner: do you have some logs?
<tlwoerner> in both cases (booting from eMMC and booting from SDcard) it can't save the environment
<qschulz> can you change the debug into printf in that file and send the logs in a pastebin somewhere?
<qschulz> also, which defconfig are you using? i see 4b only in upstream dtses, not in U-boot
<tlwoerner> yep, pasting now...
<qschulz> 4, 4a and 4c but no 4b :)
<tlwoerner> booting from eMMC: https://pastebin.com/ESd7wYts
<tlwoerner> booting from SDcard: https://pastebin.com/fsEkWTcE
joeskb7 has joined #u-boot
<tlwoerner> there are 4a, 4b, and 4c models. u-boot only has configs for 4 and 4c. 4a and 4b are supposed to use 4
<qschulz> tlwoerner: the logs are for 2024.01... is this some Yocto side effect replacing the version somehow? (from the one inside the recipe?)
<qschulz> trying to figure out what's your base commit
<tlwoerner> ah, yocto master + the patch
<tlwoerner> maybe cherry-picking that one patch isn't enough
<qschulz> ok, so 2024.04 not merged yet in yocto master
<qschulz> tlwoerner: can you check you have DM_SEQ_ALIAS and SPL_DM_SEQ_ALIAS enabled?
<tlwoerner> the SPL one isn't, but the other one is
<tlwoerner> confirmed: 2024.01 is latest in yocto master
linfax has quit [Ping timeout: 256 seconds]
<qschulz> lemme check on my Puma to see if I have the same issue
<tlwoerner> it's an rk3399?
<qschulz> yes
<tlwoerner> i only have 5 boards on which to test eMMC-vs-SDcard boot, but 2 of them don't seem to like my eMMC module
<tlwoerner> so i'm not able to test this very extensively
<qschulz> tlwoerner: I forgot to answer to your mail for meta-rockchip, sorry for that. I think we may have a hard time using /dev/disk/by-label because I **think** those are created by udev?
<qschulz> and udev isn't necessarily installed on the image
<tlwoerner> it doesn't look like the fw_{printenv|setenv} tool understand LABELs, so unfortunately we'll have to hard-code /dev/mmcblk{0|1}p5 for /etc/fw_env.config
<qschulz> tlwoerner: /dev/disk/by-label/u-boot-env is just a path
<tlwoerner> oh!! nice
<tlwoerner> yes, i now realize that's what you said, but the light hadn't turned on :-/
<qschulz> tlwoerner: do you have the logs of the SPL too?
vagrantc has joined #u-boot
<tlwoerner> qschulz: eMMC: https://pastebin.com/DcMwMecJ
<tlwoerner> SDcard: https://pastebin.com/5c0t5DMs
<qschulz> tlwoerner: no clue if it's supposed to work, but can you try with https://paste.ack.tf/91777c? I have a feeling this Card error message is only for SD cards
<tlwoerner> not using this patch and hard-coding the location of the environment via CONFIG_SYS_MMC_ENV_DEV works (i.e. the hardware is fine)
<qschulz> tlwoerner: and I assume you put either 0 or 1 in that variable, correct?
<tlwoerner> yes, the meta-rockchip patch i sent a week or two ago
<tlwoerner> oh... i've updated the patch to have another MACHINE_FEATURE to let the user say whether they're booting from SDcard or eMMC
<tlwoerner> i haven't submitted it yet, because adding the above patch messes things up
<qschulz> tlwoerner: i'm flabbergasted, i don't understand how this can not work
<tlwoerner> if i'm reading the DT correctly, with the patch included the board boots from eMMC and the patch says "hey, i just booted from the sdcard, let me try to store the environment there"
<qschulz> because it finds the appropriate dev number based on the MMC driver device in U-Boot
<tlwoerner> and visa-versa
<tlwoerner> oh, let me double-check
mmu_man has quit [Ping timeout: 272 seconds]
<tlwoerner> mmc@fe32 is the sdmmc (arch/arm/dts/rk3399.dtsi)
<qschulz> mmmm so it reads from the wrong controller
<tlwoerner> in https://pastebin.com/ESd7wYts the patch says: "mmc_get_env_dev: booted from mmc@fe32"
<tlwoerner> but that's the boot from emmc
<tlwoerner> exacly
<tlwoerner> so either the patch is fishy or the u-boot-dt (u-boot,spl-boot-device) is backwards
<qschulz> tlwoerner: the latter
<qschulz> mmc_get_env_dev: booted from /mmc@fe330000 is directly what's in u-boot,spl-boot-device
<qschulz> I think you may need d57e16c7e712ec8188c5c409e4854d147adb81e8
<qschulz> I had assumed it shouldn't change the behavior, but maybe it does (and would fix it?)
<qschulz> but this change won't apply cleanly sadly, it was part of a "big" rework
<tlwoerner> okay, i'll bump SRCREV to the latest master and see what happens
<qschulz> patches 1 to 4 I assume (they were merged)
<qschulz> lemme check with Puma, maybe I have the same issue (but since I always have eMMC, I don't see it)
<tlwoerner> my main goal is to get rauc (or any general A/B mechanism) working regardless of whether the user is booting from emmc or sdcard
<tlwoerner> getting the environment working was supposed to be a small bump along the way ;-)
<qschulz> tlwoerner: yeah, that would be great. It'd be even better if the exact same image can be flashed on SD card or eMMC :)
<qschulz> tlwoerner: oopsies :)
<tlwoerner> i'm happy to see progress is being made in the direction of using the same image on both emmc and sdcard!
<tlwoerner> i guess we're just in a period of flux for the time-being
<qschulz> tlwoerner: same issue on my Puma
mmu_man has joined #u-boot
<qschulz> reading eMMC when booting from SD card on v2024.01
<tlwoerner> okay good (i'm not off-track)
<qschulz> tlwoerner: mmmm seems to also be incorrect on v2024.01...
<qschulz> 04*
<tlwoerner> for the record, i do have rauc working for everything supported by meta-rockchip (it's been working for a while) but getting everything upstream properly is the hiccup
<tlwoerner> but i'm glad for the feedback to make sure it is done properly
<qschulz> tlwoerner: that's some code area I don't like digging into, so that may take some time, it's not fun in there :D
<qschulz> tlwoerner: sorry, I had a massive brainfart I think
<qschulz> Puma v2024.01 works fine
<qschulz> boots from SD card and detects /mmc@fe320000 as being the device it booted from
mmu_man has quit [Ping timeout: 255 seconds]
<qschulz> tlwoerner: https://paste.ack.tf/9c2936 can you add this on top of v2024.01 and tell me what SPL prints?
<qschulz> I think it's really because the rockpi defconfig is missing SPL_DM_SEQ_ALIAS
<qschulz> this means that the aliases aren't used for mmc devices, so the first probed is going to have devnum 0
<tlwoerner> updating with 'SRCREV = "master"' works for the SDcard, give me a minute to test the emmc
<tlwoerner> maybe i just add that to the patch and go from there? ;-)
<qschulz> and since the sd card controller is before the emmc controller in the DT, it has a higher chance to probe before the emmc controller
<qschulz> making sd card mmc0 and emmc mmc1, instead of the opposite
slobodan_ has joined #u-boot
slobodan has quit [Ping timeout: 264 seconds]
slobodan_ has quit [Remote host closed the connection]
<tlwoerner> i will try testing with SPL_DM_SEQ_ALIAS too
mckoan is now known as mckoan|away
<tlwoerner> darn Upstream-Status ... :-|
<qschulz> tlwoerner: surprising that it works in master, SPL_DM_SEQ_ALIAS is still missing
<qschulz> tlwoerner: compile locally, you'll have a better time :)
<qschulz> export BL31=/path/to/tf-a/bl31.elf
<qschulz> make
<qschulz> then flash idbloader.img to offset 64 (seek=64 in dd)
<qschulz> and u-boot.itb at offset 16384
slobodan has joined #u-boot
* qschulz shrugs
<tlwoerner> 2024.01 with your patch: https://paste.ack.tf/06e153
sszy has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
<tlwoerner> (booting from sdcard)
<qschulz> tlwoerner: as expected, incorrect. Can you apply the same patch for v2024.04 ?
<tlwoerner> okay
slobodan_ has joined #u-boot
slobodan has quit [Read error: Connection reset by peer]
<qschulz> tlwoerner: in v2024.04 you still have Card did not respond to voltage select! : -110
<qschulz> Unable to get mmc desc
<qschulz> which is surprising
<tlwoerner> yes, but unrelated to the environment
<tlwoerner> it's trying to probe all mmc devices (for some reason)?
<tlwoerner> oops, patch doesn't apply in master, i'll tweak it
<qschulz> tlwoerner: the s/debug/printf/ in mmc_get_env_dev + dev_err(dev, "devnum: %d\n", desc->devnum); in arch/arm/mach-rockchip/spl-boot-order.c + s/debug/printf/ in arch/arm/mach-rockchip/spl.c ?
mmu_man has joined #u-boot
slobodan_ has quit [Ping timeout: 260 seconds]
<tlwoerner> in 2024.01 i'm applying the mmc_get_env_dev myself, so in that case i've changed s/debug/printf
<tlwoerner> but in master i'm just using as-is. i'll tweak it to make the same change
slobodan has joined #u-boot
monstr has quit [Ping timeout: 252 seconds]
enok has quit [Ping timeout: 264 seconds]
stefanro has quit [Ping timeout: 268 seconds]
<tlwoerner> qschulz: rock-pi-4b, u-boot master with qschlutz patches: https://paste.ack.tf/c06fe0
<tlwoerner> booting from sdcard
* qschulz facepalms himself
<tlwoerner> hmm.. the spl is backwards, it thinks mmc1 is fe33
<tlwoerner> but u-boot proper says mmc1 is fe32 (sdcard)
<qschulz> tlwoerner: yes, but it doesn't matter anymore in v2024.04+
<qschulz> this really does fix it for you without needing SPL_DM_SEQ_ALIAS
stefanro has joined #u-boot
<qschulz> instead of mapping BOOT_DEVICE_MMC1 to a path in SPL, what we do is mapping BOOT_DEVICE_MMC1 to the path returned by the MMC device with that devnum in the blk subsystem
<qschulz> meaning there aren't any synchronization issue between those two steps of the SPL
<tlwoerner> it leaves meta-rockchip in limbo. there's no point doing a whole bunch of work-arounds that won't be needed very soon
<tlwoerner> or i could just force the SRCREV in meta-rockchip to 2024.04 and go from there
<qschulz> So I believe 2024.01 with the SPL_DM_SEQ_ALIAS should work with the mmc_get_env_dev patch from Ben Wolsieffer
<tlwoerner> okay, let me give that a try
<qschulz> tlwoerner: there aren't any work-arounds, only patches to backport :) (and patches that are merged already)
<tlwoerner> are your eMMCs (on puma etc) removable?
<qschulz> tlwoerner: no
mmu_man has quit [Ping timeout: 272 seconds]
<qschulz> tlwoerner: and before you ask, I don't have a heatgun :)
<tlwoerner> out of curiosity, how do you flash them?
<qschulz> tlwoerner: rkdeveloptool through a USB OTG port
<tlwoerner> yuck
<qschulz> rockusb from collabora-rockchiprs also works
<tlwoerner> wasn't aware of that one
<qschulz> though this USB thing works well only if your board manufacturer added a mechanism to disable the eMMC
<qschulz> otherwise... you can brick your device without being able to recover it
<qschulz> (we have a slider that cuts the data lines)
<tlwoerner> agreed! i like that the modules on some boards are removable
<qschulz> another option is to boot from SD card, somehow load the images to flash in RAM, and then flash them on the eMMC
<tlwoerner> but i need to find a module that my rock-3a and rock-5a will like
<qschulz> tlwoerner: yeah, I don't know if it's really a good thing to have removable eMMCs
<tlwoerner> that's the "beaglebone black" workflow
<qschulz> signal integrity and all that kind of stuff
<qschulz> tlwoerner: cargo install --example rockusb rockusb
<qschulz> for rockusb
<qschulz> tlwoerner: rkdeveloptool not fun also, I somehow cannot erase the flash on Fedora
<qschulz> but it seems to work on Debian
<qschulz> (distro of the host)
<tlwoerner> yea... necessary tools delivered as binaries only
<tlwoerner> fun
<qschulz> tlwoerner: no, you have the sources for rkdeveloptool :)
enok has joined #u-boot
joeskb7 has quit [Quit: Lost terminal]
<tlwoerner> the http://radxa.com/products/zeros/zero3e/ looks pretty nice! small, rockchip, PoE, camera interface, no eMMC... could be the perfect basis for cameras
enok has quit [Ping timeout: 268 seconds]
ldevulder has quit [Quit: Leaving]
prabhakarlad has quit [Quit: Client closed]
enok has joined #u-boot
slobodan has quit [Read error: Connection reset by peer]
slobodan has joined #u-boot
f_[xmpp] has quit [Quit: Gateway shutdown]
enok has quit [Ping timeout: 240 seconds]
<tlwoerner> qschulz: u-boot 2024.01 + SPL_DM_SEQ_ALIAS + Ben Wolsieffer patch (with your extra debug output) works PERFECTLY on rock-pi-4b via both sdcard and emmc
f_[xmpp] has joined #u-boot
enok has joined #u-boot
<tlwoerner> qschulz: however, it doesn't seem possible to assign a label to a "rawcopy" partition, even if its type is marked "ext4" (instead of "none")
GNUtoo_ is now known as GNUtoo
Clamor has quit [Ping timeout: 264 seconds]
enok has quit [Ping timeout: 252 seconds]
Clamor has joined #u-boot
KREYREN has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
<tlwoerner> qschulz: YES! --part-label works → /dev/disk/by-partlabel/u-boot-env
<tlwoerner> oops, --part-name (in wic)
Clamor has quit [Read error: Connection reset by peer]
prabhakalad has quit [Ping timeout: 268 seconds]
prabhakalad has joined #u-boot
prabhakalad has quit [Ping timeout: 252 seconds]
prabhakalad has joined #u-boot
gsz has quit [Ping timeout: 255 seconds]
gsz has joined #u-boot
mmu_man has joined #u-boot
naoki has joined #u-boot
prabhakalad has quit [Ping timeout: 268 seconds]
prabhakalad has joined #u-boot
rvalue has quit [Ping timeout: 255 seconds]
stefanro has quit [Ping timeout: 240 seconds]
jfsimon1981_c has joined #u-boot
jybz has quit [Remote host closed the connection]
jybz has joined #u-boot
stefanro has joined #u-boot
redbrain has quit [Read error: Connection reset by peer]
redbrain has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
wooosaiiii has quit [Remote host closed the connection]
wooosaiiii has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
stefanro has quit [Ping timeout: 272 seconds]
slobodan has quit [Ping timeout: 256 seconds]
stefanro has joined #u-boot
KREYREN has quit [Remote host closed the connection]
KREYREN has joined #u-boot
mmu_man has quit [Ping timeout: 256 seconds]
wooosaiiii1 has joined #u-boot
wooosaiiii has quit [Ping timeout: 256 seconds]
wooosaiiii1 is now known as wooosaiiii
mmu_man has joined #u-boot
enok has joined #u-boot