Hello Renaud, On 04.03.21 17:41, Barbier, Renaud wrote: >>> Would it possible from the PBL to read the "baudrate" variable from the >> environment? >> >> Normally, you would want to avoid doing anything, but the >> bare minimum from PBL. Does the baudrate device parameter >> work for you? >> > [Barbier, Renaud] > Just to give you a bit more context. In our platform ARM (all non-pbl) or PPC, we add a call to do a PBIT memory test before starting barebox. The uart is initialized just before that at a fixed baud rate of 9600 bauds. Now we have a requirement to support more than one baud rate configurable by the user. And our next ARM based board is going to have a PBL. > > Are you saying that from the PBL, I can do something like baud=getenv("baudrate") to get the environment variable value. This would require to have /dev/env0 instantiated, would not it? I am saying: don't do it from PBL at all if possible. > Does not that require to have the environment init code (fs support and all) be compiled as part of the PBL (lwl-y +=....). > My environment variables are in QSPI, so I would think I could parse the environment variable without the whole barebox support instead. > If not possible then I think we can find some other way to retrieve the baud rate. So you load pbl/bare init barebox into SRAM, run PBIT memory test on DRAM, then extract/copy barebox proper to DRAM or how does it work? Cheers, Ahmad > > Cheers. > > >> Cheers, >> Ahmad >> >>> >>> Cheers, >>> Renaud >>> >>> >>> _______________________________________________ >>> barebox mailing list >>> barebox@xxxxxxxxxxxxxxxxxxx >>> >> https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Flists.infra >> dead.org%2Fmailman%2Flistinfo%2Fbarebox&data=04%7C01%7Crenaud.b >> arbier%40abaco.com%7C5feb6191d4d647f8afdb08d8df0d5b4c%7Ce6f2745189 >> 9d4d0db8fa88baafa551a7%7C0%7C0%7C637504595763337955%7CUnknown% >> 7CTWFpbGZsb3d8eyJWIjoiMC4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiL >> CJXVCI6Mn0%3D%7C1000&sdata=U5XVs%2Bf0L4t6LX49D7IJZNexAa77Pkjy >> kZv74%2FJ8klk%3D&reserved=0 >>> >> >> -- >> Pengutronix e.K. | | >> Steuerwalder Str. 21 | >> https://nam11.safelinks.protection.outlook.com/?url=http%3A%2F%2Fwww.pen >> gutronix.de%2F&data=04%7C01%7Crenaud.barbier%40abaco.com%7C5fe >> b6191d4d647f8afdb08d8df0d5b4c%7Ce6f27451899d4d0db8fa88baafa551a7%7 >> C0%7C0%7C637504595763337955%7CUnknown%7CTWFpbGZsb3d8eyJWIjoiMC >> 4wLjAwMDAiLCJQIjoiV2luMzIiLCJBTiI6Ik1haWwiLCJXVCI6Mn0%3D%7C1000&a >> mp;sdata=H1Ifw3D43oCbwUMkyKECroRAm22bBXka2wbBMGFhM%2BE%3D&a >> mp;reserved=0 | >> 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | >> Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | > -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 | _______________________________________________ barebox mailing list barebox@xxxxxxxxxxxxxxxxxxx http://lists.infradead.org/mailman/listinfo/barebox