mail archive of the barebox mailing list
 help / color / mirror / Atom feed
* eMMC partitions kernel comand line
@ 2020-06-18  8:21 Giorgio Dal Molin
  2020-06-18 13:18 ` Sascha Hauer
  0 siblings, 1 reply; 2+ messages in thread
From: Giorgio Dal Molin @ 2020-06-18  8:21 UTC (permalink / raw)
  To: barebox

Hallo,

I'm working on an arm IMX7 module with an eMMC flash on it.

I don't need/want to have a partition table on the eMMC, some hardcoded
partitions are just OK. I've already defined them in the barebox device tree
and it works, for barebox:

...
  partition@0 {
    label = "bl_env";
    reg = <BLENV_OFS BLENV_SIZE>;
  };
  partition@1 {
    label = "boot";
    reg = <BOOT_OFS BOOT_SIZE>;
  };
...

Unfortunately the same trick is not supported by the linux kernel.
What works for the kernel is the special command line option:

blkdevparts=mmcblk1:1M(bl_env),50M(boot),...

My question is: is it possible to let barebox automatically generate
this command line according to what it has in its device tree or do I
have to do it manually.

giorgio

_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: eMMC partitions kernel comand line
  2020-06-18  8:21 eMMC partitions kernel comand line Giorgio Dal Molin
@ 2020-06-18 13:18 ` Sascha Hauer
  0 siblings, 0 replies; 2+ messages in thread
From: Sascha Hauer @ 2020-06-18 13:18 UTC (permalink / raw)
  To: Giorgio Dal Molin; +Cc: barebox

Hi Giorgio,

On Thu, Jun 18, 2020 at 10:21:12AM +0200, Giorgio Dal Molin wrote:
> Hallo,
> 
> I'm working on an arm IMX7 module with an eMMC flash on it.
> 
> I don't need/want to have a partition table on the eMMC, some hardcoded
> partitions are just OK. I've already defined them in the barebox device tree
> and it works, for barebox:
> 
> ...
>   partition@0 {
>     label = "bl_env";
>     reg = <BLENV_OFS BLENV_SIZE>;
>   };
>   partition@1 {
>     label = "boot";
>     reg = <BOOT_OFS BOOT_SIZE>;
>   };
> ...
> 
> Unfortunately the same trick is not supported by the linux kernel.
> What works for the kernel is the special command line option:
> 
> blkdevparts=mmcblk1:1M(bl_env),50M(boot),...
> 
> My question is: is it possible to let barebox automatically generate
> this command line according to what it has in its device tree or do I
> have to do it manually.

No, this is currently not possible, at least not without adding this
feature to barebox. Note that barebox doesn't know which MMC device
corresponds to "mmcblk1" as it depends on the initialization order in
Linux which MMC ends up as "mmcblk1".

It might be worth trying to add device tree partitioning support for
MMCs to Linux. The command line option was accepted also, so why not
device tree?

Regards,
  Sascha

-- 
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

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-06-18 13:18 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-18  8:21 eMMC partitions kernel comand line Giorgio Dal Molin
2020-06-18 13:18 ` Sascha Hauer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox