mail archive of the barebox mailing list
 help / color / mirror / Atom feed
From: David Jander <david@protonic.nl>
To: Sascha Hauer <s.hauer@pengutronix.de>
Cc: barebox@lists.infradead.org
Subject: Re: [PATCH] arm: boards: Add support for Protonic PRTPUK board
Date: Mon, 25 Aug 2025 11:30:40 +0200	[thread overview]
Message-ID: <20250825113040.42cade82@erd003.prtnl> (raw)
In-Reply-To: <aKwnPBfs3rjNaqDv@pengutronix.de>

On Mon, 25 Aug 2025 11:05:00 +0200
Sascha Hauer <s.hauer@pengutronix.de> wrote:

> On Thu, Aug 14, 2025 at 03:23:00PM +0200, David Jander wrote:
> > 
> > Dear Sascha,
> > 
> > On Thu, 14 Aug 2025 13:26:31 +0200
> > Sascha Hauer <s.hauer@pengutronix.de> wrote:
> >   
> > > Hi David,
> > > 
> > > On Wed, Aug 13, 2025 at 09:01:49AM +0200, David Jander wrote:  
> > > > PRTPUK is a credit-card sized ISOBUS virtual terminal, based on the
> > > > Rockchip RK3576 SoC, that features a CAN interface and a 100/1000Base-T1
> > > > interface for HS-ISOBUS (HSI), as well as a USB-C port for connecting to a
> > > > touch-screen monitor.
> > > > 
> > > > +&sdhci {
> > > > +	no-sd;
> > > > +
> > > > +	partitions {
> > > > +		compatible = "barebox,fixed-partitions";
> > > > +		#address-cells = <2>;
> > > > +		#size-cells = <2>;
> > > > +
> > > > +		/* eMMC reserved 8MiB for barebox (2 copies?), env and state */
> > > > +		environment_emmc: partition@7b0000 {
> > > > +			label = "barebox-environment";
> > > > +			reg = <0x0 0x7b0000 0x0 0x10000>;
> > > > +		};
> > > > +
> > > > +		/* eMMC state after barebox and environment */
> > > > +		state_backend_emmc: partition@7c0000 {
> > > > +			label = "state";
> > > > +			reg = <0x0 0x7c0000 0x0 0x40000>;
> > > > +		};
> > > > +	};    
> > > 
> > > We are trying to get away from hardcoding partitions outside the GPT in
> > > the device tree and I think we are there.
> > > 
> > > A partition with the type UUID PARTITION_BAREBOX_ENVIRONMENT_GUID will be
> > > used as environment partition automatically.
> > > 
> > > A partition with the type UUID BAREBOX_STATE_PARTITION_GUID will be used
> > > as state partition provided the state node points to the device
> > > containing this partition.
> > > 
> > > We also have a parted command to create/modify partitions and for
> > > further convenience a createnv command which will create a barebox
> > > environment partition in case you haven't built a full partition image
> > > from a BSP.
> > > 
> > > It would be great if you could test this and eventually switch over to
> > > it.  
> > 
> > This was copied over from MECSBC. I didn't know things had changed since.
> > 
> > I agree it is much better to have all storage areas indexed by a GPT, but it
> > will mean that we will need to change every instance of identifying a
> > partition from number-based indexes to UUID or labels. And of course there are
> > a lot more partitions that will have to be included for completeness,
> > specially on Rockchip platforms. See here:
> > 
> > https://opensource.rock-chips.com/wiki_Partitions
> > 
> > This looks like a big mess, but I suppose we should at leas have loader1
> > (which is the whole of barebox, TF-A and optee). "U-Boot ENV" would be
> > replaced by barebox environment, and loader2 and trust would disappear.
> > On the MECSBC platform we started to use the Vendor Storage partition for
> > storing serial number and MAC address, so unless there is a better place for
> > these, we'd continue adhering to the Rockchip standard... for lack of a better
> > standard.
> > 
> > I'll try to come up with a partition layout that includes everything,
> > including the GUID's you mentioned above. Thanks.  
> 
> I'm not sure how it helps us to adhere to the partitioning scheme
> described in your link. If you want to do it, you can do it and still
> give the barebox environment partition the expected UUID so that barebox
> detects it.

Sure. The link was more or less informative in case you hadn't seen this.

> Anyway, I applied the patch as-is to get some compile coverage for
> RK3576, you can still change the partitioning later.

Ok, thanks. Sorry I couldn't find time to resubmit a new version yet. I will
look into this later and send incremental patches if needed.

Best regards,

-- 
David Jander




  reply	other threads:[~2025-08-25 11:29 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-08-13  7:01 David Jander
2025-08-13  7:28 ` David Jander
2025-08-13  8:17   ` Ahmad Fatoum
2025-08-14 11:26 ` Sascha Hauer
2025-08-14 13:23   ` David Jander
2025-08-25  9:05     ` Sascha Hauer
2025-08-25  9:30       ` David Jander [this message]
2025-08-25  8:55 ` 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=20250825113040.42cade82@erd003.prtnl \
    --to=david@protonic.nl \
    --cc=barebox@lists.infradead.org \
    --cc=s.hauer@pengutronix.de \
    /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