Tartarus changed the topic of #u-boot to: SOURCE MOVED TO https://source.denx.de/u-boot/u-boot.git / U-Boot v2022.01, v2022.04-rc2 are OUT / Merge Window is CLOSED / Release v2022.04 is scheduled for 4 April 2022 / http://www.denx.de/wiki/U-Boot / Channel archives at https://libera.irclog.whitequark.org/u-boot
flyback has quit [Read error: Connection reset by peer]
flyback has joined #u-boot
prabhakarlad has joined #u-boot
chrfle has quit [Quit: ZNC - https://znc.in]
chrfle has joined #u-boot
camus has quit [Ping timeout: 256 seconds]
camus has joined #u-boot
kaitsh has quit [Quit: WeeChat 3.3]
jclsn7 has quit [Ping timeout: 240 seconds]
mmu_man has quit [Ping timeout: 252 seconds]
jclsn7 has joined #u-boot
qschulz has quit [Remote host closed the connection]
qschulz has joined #u-boot
jclsn7 has quit [Ping timeout: 256 seconds]
jclsn7 has joined #u-boot
jclsn7 has quit [Ping timeout: 240 seconds]
jclsn7 has joined #u-boot
camus1 has joined #u-boot
camus has quit [Ping timeout: 256 seconds]
camus1 is now known as camus
jclsn7 has quit [Ping timeout: 256 seconds]
jclsn7 has joined #u-boot
thopiekar has quit [Ping timeout: 240 seconds]
thopiekar has joined #u-boot
jclsn7 has quit [Ping timeout: 240 seconds]
jclsn7 has joined #u-boot
camus1 has joined #u-boot
camus has quit [Ping timeout: 240 seconds]
camus1 is now known as camus
jclsn7 has quit [Ping timeout: 240 seconds]
jclsn7 has joined #u-boot
mripard has quit [Ping timeout: 256 seconds]
mripard has joined #u-boot
jclsn7 has quit [Quit: Ping timeout (120 seconds)]
jclsn7 has joined #u-boot
jclsn7 has quit [Quit: Ping timeout (120 seconds)]
jclsn7 has joined #u-boot
jclsn7 has quit [Ping timeout: 240 seconds]
jclsn7 has joined #u-boot
jclsn7 has quit [Quit: Ping timeout (120 seconds)]
jclsn7 has joined #u-boot
jclsn7 has quit [Quit: Ping timeout (120 seconds)]
jclsn7 has joined #u-boot
jclsn7 has quit [Quit: Ping timeout (120 seconds)]
jclsn7 has joined #u-boot
jclsn74 has joined #u-boot
jclsn7 has quit [Ping timeout: 260 seconds]
jclsn74 is now known as jclsn7
milkylainen_ has joined #u-boot
sbach has quit [Read error: Connection reset by peer]
sbach has joined #u-boot
tre has joined #u-boot
lucaceresoli has joined #u-boot
fdanis_away is now known as fdanis
mmu_man has joined #u-boot
monstr has joined #u-boot
frieder has joined #u-boot
mckoan|away is now known as mckoan
camus1 has joined #u-boot
camus has quit [Ping timeout: 260 seconds]
camus1 is now known as camus
thopiekar has quit [Ping timeout: 240 seconds]
thopiekar has joined #u-boot
zibolo has joined #u-boot
thopiekar has quit [Ping timeout: 252 seconds]
michalkotyla has quit [Quit: michalkotyla]
thopiekar has joined #u-boot
qschulz has quit [Remote host closed the connection]
sszy has joined #u-boot
qschulz has joined #u-boot
jurc192[m] has quit [Quit: You have been kicked for being idle]
ldevulder has quit [Quit: Leaving]
ldevulder has joined #u-boot
matthias_bgg has joined #u-boot
apritzel has joined #u-boot
tnovotny has joined #u-boot
prabhakarlad has quit [Quit: Client closed]
milkylainen has quit [Quit: Connection closed]
milkylainen has joined #u-boot
tre has quit [Ping timeout: 240 seconds]
tre has joined #u-boot
mckoan is now known as mckoan|away
crb_ has quit [Quit: Leaving]
milkylainen_ has quit [Remote host closed the connection]
prabhakarlad has joined #u-boot
lucaceresoli has quit [Remote host closed the connection]
lucaceresoli has joined #u-boot
Thorn has quit [Ping timeout: 260 seconds]
Thorn has joined #u-boot
<sjg1> Tartarus: Yes... also Takahiro's UEFI clean-up series uses it, as well as the tag stuff (which is just inline in his series)
<Tartarus> sjg1: OK, I'll pick that up for next soon then
<Tartarus> I'm already at 0/1 in "lets merge 2 series and push them through CI to see that nothing breaks"
<sjg1> Tartarus: OK ta. I hope the UEFI stuff can come in soon
<sjg1> Tartarus: If you like I can rebase and check it to save you the hassle. Something may have changed
<Tartarus> sjg1: Please and thanks!
<sjg1> Tartarus: OK I'll let you know
monstr has quit [Remote host closed the connection]
lucaceresoli has quit [Remote host closed the connection]
lucaceresoli has joined #u-boot
<sjg1> Tartarus: sadly there is one new misc_init_f() function to convert, so I'll send a v2
<Tartarus> OK, thanks!
kveremitz has quit [Ping timeout: 250 seconds]
lucaceresoli has quit [Remote host closed the connection]
lucaceresoli has joined #u-boot
Dhruvag2000[m] has quit [Quit: You have been kicked for being idle]
tnovotny has quit [Quit: Leaving]
zibolo has quit [Ping timeout: 240 seconds]
tre has quit [Remote host closed the connection]
milkylainen_ has joined #u-boot
<MWelchUK> I'm currently working on a system which has a SoM mounted to a main board. Due to supplier shortages there's a desire to use both the existing SoM or a second one from a different supplier, but boot from the same firmware Binary.
<MWelchUK> Both of the SoMs are i.MX6 based. I have a build where this basically works booting with a shared SPL and main U-Boot image, however both SoMs use SPI-NOR to store U-Boot, but on different buses. This is a little bit problematic with CONFIG_ENV_SPI_BUS/CONFIG_SF_DEFAULT_BUS.
sobkas has joined #u-boot
<MWelchUK> I have what seems to me to be a very hacky solution where I replace the usage of these defines with a weakly defined function returning the define value. I then provide this function as part of the board support with a function that determines the correct bus for the SoM in use.
<MWelchUK> Ideally we'd be upstreaming support for this device at some point in the not too distant future.
<MWelchUK> (It's a sister product for the already upstreamed bx50v3 devices)
<MWelchUK> Would such a solution potentially be acceptable upstream? Can anyone suggest a better option?
vagrantc has joined #u-boot
guillaume_g has quit [Quit: Konversation terminated!]
<marex> MWelchUK: doesnt DM_SPI permit you to select bus in DT ?
<marex> MWelchUK: which SoMs are these btw ?
<MWelchUK> marex: Unless I'm missing something, the default bus is hardcoded in `spl_spi_load_image()` (common/spl/spl_spi.c), `do_spi_flash_probe()` (cmd/sf.c), `splash_sf_read_raw()` (common/splash_source.c), `fsl_spi_spl_load_image()` and `fsl_spi_boot()` (drivers/mtd/spi/fsl_espi_spl.c), and `setup_flash_device()` and `setup_flash_device()` (env/sf.c).
milkylainen has quit [Quit: Ping timeout (120 seconds)]
<MWelchUK> marex: The SoMs are the Congatec QMX6 and MSC Q7-imx
<MWelchUK> marex: I don't currently have DM support in the SPL, which I guess is where the bulk of the issue lies...
<MWelchUK> I'm not using all the functions listed above, but I clearly need to find a solution that continues to work for others too if I'm going to be upstreaming this...
kveremitz has joined #u-boot
<apritzel> MWelchUK: if you don't have DM_SPL, and this problem is SPL only, then I'd hope those kind of "hacks" are somewhat tolerated
<apritzel> MWelchUK: we use similar tricks in sunxi to support booting board variants, where we select one of multiple DTs, in SPL code
<MWelchUK> apritzel: Looking at `setup_flash_device()` in `env/sf.h`, the default bus is hardcoded regardless of whether DM_SPL is being used or not.
<apritzel> MWelchUK: smells like some legacy, since nobody had this case so far
<apritzel> but replacing a fixed CONFIG_ with a weak function sounds familiar, I think I did this in the past as well ;-)
<MWelchUK> apritzel: Yes, I'm assuming what we're trying to do isn't something that many people have tried before (I assume we wouldn't if chip supply wasn't fairly screwed up at the moment.
<apritzel> I don't know about that, but I would assume that the boot SPI flash is mostly at one fixed bus on a platform, so there was little need for runtime checks so far
<apritzel> for instance the Allwinner BootROM only supports SPI booting from SPI0 on the PortC pins, so this indeed nicely modeled with a CONFIG_ variable
<MWelchUK> That would seem like a very sane assumption to make. :-)
<apritzel> MWelchUK: and I think just selecting a different bus is not enough, since you would probably need differentiation between the board variants in U-Boot proper as well
<apritzel> for Allwinner we put multiple DTs in the U-Boot FIT image, and select the right one from the SPL: check board_fit_config_name_match() in board/sunxi/board.c
<MWelchUK> apritzel: Yep, that's what I'm doing in this instance. Though there's a few bits that are hard coded with are a little problematic. Other than the SPI bus, the console UART seems to be hardcoded too. Thankfully I have access to a UART that both SoMs use.
<apritzel> I don't think there is much opposition to go from hardcoded to runtime determined, given that this doesn't ignore the DT (which is not the case if this is in the SPL with DM_SPL)
<apritzel> s/with/without/
matthias_bgg has quit [Ping timeout: 245 seconds]
<MWelchUK> apritzel: Oh, OK. I'll assume that my hacky solution may be closer to something upstreamable than I'd expected then :-)
frieder has quit [Remote host closed the connection]
<apritzel> if that allows a single image, simplifying the user experience, and prevents worse hacks ...
<marex> MWelchUK: __weak functions are fine
___nick___ has joined #u-boot
sszy has quit [Quit: http://quassel-irc.org - Chat comfortably. Anywhere.]
___nick___ has quit [Quit: https://quassel-irc.org - Chat comfortably. Anywhere.]
___nick___ has joined #u-boot
___nick___ has quit [Client Quit]
apritzel has quit [Ping timeout: 272 seconds]
___nick___ has joined #u-boot
fdanis is now known as fdanis_away
jclsn7 has quit [Ping timeout: 272 seconds]
jclsn7 has joined #u-boot
crb has joined #u-boot
___nick___ has quit [Ping timeout: 256 seconds]
lucaceresoli has quit [Ping timeout: 256 seconds]
torez has joined #u-boot
<sjg1> Tartarus: yuk that is pretty horrible. I suspect it can be fixed by adding: self.patch = '' to the __init__() function in class Commit (see commit.py)
torez has quit [Ping timeout: 250 seconds]
prabhakarlad has quit [Quit: Client closed]