From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: "Barbier, Renaud" <renaud.barbier@abaco.com>,
"barebox@lists.infradead.org" <barebox@lists.infradead.org>
Subject: Re: Uart set up in PBL
Date: Fri, 5 Mar 2021 11:48:26 +0100 [thread overview]
Message-ID: <c3eae1a0-2296-64f4-95ea-cb808f1f0aa2@pengutronix.de> (raw)
In-Reply-To: <MN2PR16MB3135FD27767D80F4FB9FB44A91979@MN2PR16MB3135.namprd16.prod.outlook.com>
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@lists.infradead.org
>>>
>> 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@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next prev parent reply other threads:[~2021-03-05 10:51 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-03-04 12:28 Barbier, Renaud
2021-03-04 12:59 ` Ahmad Fatoum
2021-03-04 16:41 ` Barbier, Renaud
2021-03-05 10:48 ` Ahmad Fatoum [this message]
2021-03-05 13:08 ` Barbier, Renaud
2021-03-08 20:22 ` Ahmad Fatoum
2021-03-04 13:07 ` Sascha Hauer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=c3eae1a0-2296-64f4-95ea-cb808f1f0aa2@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=barebox@lists.infradead.org \
--cc=renaud.barbier@abaco.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox