mail archive of the rauc mailing list
 help / color / mirror / Atom feed
* [RAUC] Non reduntant bootloader update
@ 2023-01-03  8:17 BAUER Bernd
  2023-01-03  8:31 ` Ahmad Fatoum
  0 siblings, 1 reply; 11+ messages in thread
From: BAUER Bernd @ 2023-01-03  8:17 UTC (permalink / raw)
  To: RAUC

Hi!

I have an IMX8MN system and want to use RAUC to update the bootloader.
The BL is on the EMMC (no partition) and is not redundant.

Does this work with Rauc at all?

I have unfortunately found nothing in the manual about it.

Greets Bernd



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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-03  8:17 [RAUC] Non reduntant bootloader update BAUER Bernd
@ 2023-01-03  8:31 ` Ahmad Fatoum
  2023-01-03  9:39   ` Jan Lübbe
  0 siblings, 1 reply; 11+ messages in thread
From: Ahmad Fatoum @ 2023-01-03  8:31 UTC (permalink / raw)
  To: BAUER Bernd, RAUC

Hello Bernd,

On 03.01.23 09:17, BAUER Bernd wrote:
> Hi!
> 
> I have an IMX8MN system and want to use RAUC to update the bootloader.
> The BL is on the EMMC (no partition) and is not redundant.

Why would you not place it into the dedicated hardware boot partitions
that your eMMC already has?

> Does this work with Rauc at all?

eMMC boot partition are better because they provide power-fail safe update,
but you could use the eMMC user area with RAUC as well.
Easiest way is to just place a MBR/GPT partition at the location where the
bootrom expects the bootloader. There's no rule that the bootloader needs
to be located in unpartitioned space.

> I have unfortunately found nothing in the manual about it.

There's: https://rauc.readthedocs.io/en/latest/examples.html#atomic-bootloader-updates-emmc

Cheers,
Ahmad

> 
> Greets Bernd
> 
> 

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




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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-03  8:31 ` Ahmad Fatoum
@ 2023-01-03  9:39   ` Jan Lübbe
  2023-01-03 10:22     ` Jan Lübbe
  0 siblings, 1 reply; 11+ messages in thread
From: Jan Lübbe @ 2023-01-03  9:39 UTC (permalink / raw)
  To: Ahmad Fatoum, BAUER Bernd, RAUC

Hi,

On Tue, 2023-01-03 at 09:31 +0100, Ahmad Fatoum wrote:
> Hello Bernd,
> 
> On 03.01.23 09:17, BAUER Bernd wrote:
> > Hi!
> > 
> > I have an IMX8MN system and want to use RAUC to update the bootloader.
> > The BL is on the EMMC (no partition) and is not redundant.
> 
> Why would you not place it into the dedicated hardware boot partitions
> that your eMMC already has?
> 
> > Does this work with Rauc at all?
> 
> eMMC boot partition are better because they provide power-fail safe update,
> but you could use the eMMC user area with RAUC as well.
> Easiest way is to just place a MBR/GPT partition at the location where the
> bootrom expects the bootloader. There's no rule that the bootloader needs
> to be located in unpartitioned space.

Which SoC are you using?

Depending on what the ROM code expects, you could use the other types (boot-raw-
fallback or boot-mbr-switch).

If the ROM code only supports a single fixed bootloader offset, you cannot
update it atomically. Support for that is not implemented in RAUC yet.

> > I have unfortunately found nothing in the manual about it.
> 
> There's: https://rauc.readthedocs.io/en/latest/examples.html#atomic-bootloader-updates-emmc

More details on the available methods are in:
https://rauc.readthedocs.io/en/latest/advanced.html#updating-the-bootloader

Regards,
Jan


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



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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-03  9:39   ` Jan Lübbe
@ 2023-01-03 10:22     ` Jan Lübbe
  2023-01-03 14:22       ` BAUER Bernd
  0 siblings, 1 reply; 11+ messages in thread
From: Jan Lübbe @ 2023-01-03 10:22 UTC (permalink / raw)
  To: Ahmad Fatoum, BAUER Bernd, RAUC

Hi again,

On Tue, 2023-01-03 at 10:39 +0100, Jan Lübbe wrote:
> Hi,
> 
> On Tue, 2023-01-03 at 09:31 +0100, Ahmad Fatoum wrote:
> > Hello Bernd,
> > 
> > On 03.01.23 09:17, BAUER Bernd wrote:
> > > Hi!
> > > 
> > > I have an IMX8MN system and want to use RAUC to update the bootloader.
> > > The BL is on the EMMC (no partition) and is not redundant.
> > 
> > Why would you not place it into the dedicated hardware boot partitions
> > that your eMMC already has?
> > 
> > > Does this work with Rauc at all?
> > 
> > eMMC boot partition are better because they provide power-fail safe update,
> > but you could use the eMMC user area with RAUC as well.
> > Easiest way is to just place a MBR/GPT partition at the location where the
> > bootrom expects the bootloader. There's no rule that the bootloader needs
> > to be located in unpartitioned space.
> 
> Which SoC are you using?

Ah, I just noticed that you're using a i.MX8MN. That means you can use the eMMC
boot partitions and have atomic bootloader updates with the current
implementation in RAUC:
https://rauc.readthedocs.io/en/latest/advanced.html#update-bootloader-in-emmc-boot-partitions

Regards,
Jan

> Depending on what the ROM code expects, you could use the other types (boot-raw-
> fallback or boot-mbr-switch).
> 
> If the ROM code only supports a single fixed bootloader offset, you cannot
> update it atomically. Support for that is not implemented in RAUC yet.
> 
> > > I have unfortunately found nothing in the manual about it.
> > 
> > There's: https://rauc.readthedocs.io/en/latest/examples.html#atomic-bootloader-updates-emmc
> 
> More details on the available methods are in:
> https://rauc.readthedocs.io/en/latest/advanced.html#updating-the-bootloader

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



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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-03 10:22     ` Jan Lübbe
@ 2023-01-03 14:22       ` BAUER Bernd
  2023-01-04 10:14         ` BAUER Bernd
  0 siblings, 1 reply; 11+ messages in thread
From: BAUER Bernd @ 2023-01-03 14:22 UTC (permalink / raw)
  To: RAUC

Hi Jan, hi Ahmad!

Thank you for your quick help.
I will have a look at it. 😊

Greets Bernd


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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-03 14:22       ` BAUER Bernd
@ 2023-01-04 10:14         ` BAUER Bernd
  2023-01-04 10:18           ` Ahmad Fatoum
  0 siblings, 1 reply; 11+ messages in thread
From: BAUER Bernd @ 2023-01-04 10:14 UTC (permalink / raw)
  To: RAUC

Hi Jan, hi Ahmad!

I've changed the Bootloader to the mmcblk1boot0 and mmcblk1boot1 partitions.
Now it works with rauc.

Very cool... 😊

Thanks for the help!

Greets Bernd


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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-04 10:14         ` BAUER Bernd
@ 2023-01-04 10:18           ` Ahmad Fatoum
  2023-01-04 10:23             ` BAUER Bernd
  0 siblings, 1 reply; 11+ messages in thread
From: Ahmad Fatoum @ 2023-01-04 10:18 UTC (permalink / raw)
  To: BAUER Bernd, RAUC

Hello Bernd,

On 04.01.23 11:14, BAUER Bernd wrote:
> Hi Jan, hi Ahmad!
> 
> I've changed the Bootloader to the mmcblk1boot0 and mmcblk1boot1 partitions.
> Now it works with rauc.

Good to hear. In case you are using meta-rauc, I recently submitted
this change, that you may find useful if you are using barebox on 8MN/P:

https://github.com/rauc/meta-rauc/commit/f2d051d37008deb4204acd8ab0f5f3f0e9a3971d

Cheers,
Ahmad

> 
> Very cool... 😊
> 
> Thanks for the help!
> 
> Greets Bernd
> 

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




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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-04 10:18           ` Ahmad Fatoum
@ 2023-01-04 10:23             ` BAUER Bernd
  2023-01-04 10:36               ` Peter Korsgaard
  0 siblings, 1 reply; 11+ messages in thread
From: BAUER Bernd @ 2023-01-04 10:23 UTC (permalink / raw)
  To: Ahmad Fatoum, RAUC

Hi Ahmad!

-----Ursprüngliche Nachricht-----
Von: Ahmad Fatoum <a.fatoum@pengutronix.de> 
> Good to hear. In case you are using meta-rauc, I recently submitted this change,
> that you may find useful if you are using barebox on 8MN/P:
> https://github.com/rauc/meta-rauc/commit/f2d051d37008deb4204acd8ab0f5f3f0e9a3971d

Yes, I'm using meta-rauc.

But I don't use barebox at the moment, but maybe I'll change, when I find some time.

Bernd

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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-04 10:23             ` BAUER Bernd
@ 2023-01-04 10:36               ` Peter Korsgaard
  2023-01-04 10:40                 ` Ahmad Fatoum
  0 siblings, 1 reply; 11+ messages in thread
From: Peter Korsgaard @ 2023-01-04 10:36 UTC (permalink / raw)
  To: Ahmad Fatoum; +Cc: RAUC

Hi,

 >> Good to hear. In case you are using meta-rauc, I recently submitted this change,
 >> that you may find useful if you are using barebox on 8MN/P:
 >> https://github.com/rauc/meta-rauc/commit/f2d051d37008deb4204acd8ab0f5f3f0e9a3971d

Not a meta-rauc user, but doesn't this now require that positive offsets
have a + prefix, breaking backwards compatibility?

-- 
Bye, Peter Korsgaard



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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-04 10:36               ` Peter Korsgaard
@ 2023-01-04 10:40                 ` Ahmad Fatoum
  2023-01-04 11:08                   ` Peter Korsgaard
  0 siblings, 1 reply; 11+ messages in thread
From: Ahmad Fatoum @ 2023-01-04 10:40 UTC (permalink / raw)
  To: Peter Korsgaard; +Cc: RAUC

Hello Peter,

On 04.01.23 11:36, Peter Korsgaard wrote:
> Hi,
> 
>  >> Good to hear. In case you are using meta-rauc, I recently submitted this change,
>  >> that you may find useful if you are using barebox on 8MN/P:
>  >> https://github.com/rauc/meta-rauc/commit/f2d051d37008deb4204acd8ab0f5f3f0e9a3971d
> 
> Not a meta-rauc user, but doesn't this now require that positive offsets
> have a + prefix, breaking backwards compatibility?

imgoffset is slotflags.get('offset') by default unless it starts
with either a + or -. Similarly, padding is "seek" by default.

The original RAUC_SLOT_bootloader[offset] = "32K" syntax should
thus continue to work normally.

Cheers,
Ahmad

> 

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




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

* Re: [RAUC] Non reduntant bootloader update
  2023-01-04 10:40                 ` Ahmad Fatoum
@ 2023-01-04 11:08                   ` Peter Korsgaard
  0 siblings, 0 replies; 11+ messages in thread
From: Peter Korsgaard @ 2023-01-04 11:08 UTC (permalink / raw)
  To: Ahmad Fatoum; +Cc: RAUC

>>>>> "Ahmad" == Ahmad Fatoum <a.fatoum@pengutronix.de> writes:

 > Hello Peter,
 > On 04.01.23 11:36, Peter Korsgaard wrote:
 >> Hi,
 >> 
 >> >> Good to hear. In case you are using meta-rauc, I recently submitted this change,
 >> >> that you may find useful if you are using barebox on 8MN/P:
 >> >> https://github.com/rauc/meta-rauc/commit/f2d051d37008deb4204acd8ab0f5f3f0e9a3971d
 >> 
 >> Not a meta-rauc user, but doesn't this now require that positive offsets
 >> have a + prefix, breaking backwards compatibility?

 > imgoffset is slotflags.get('offset') by default unless it starts
 > with either a + or -. Similarly, padding is "seek" by default.

 > The original RAUC_SLOT_bootloader[offset] = "32K" syntax should
 > thus continue to work normally.

Ahh yes, so the assignment to padding in line 270 is not strictly
needed. Sorry for the noise.

-- 
Bye, Peter Korsgaard



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

end of thread, other threads:[~2023-01-04 11:08 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-01-03  8:17 [RAUC] Non reduntant bootloader update BAUER Bernd
2023-01-03  8:31 ` Ahmad Fatoum
2023-01-03  9:39   ` Jan Lübbe
2023-01-03 10:22     ` Jan Lübbe
2023-01-03 14:22       ` BAUER Bernd
2023-01-04 10:14         ` BAUER Bernd
2023-01-04 10:18           ` Ahmad Fatoum
2023-01-04 10:23             ` BAUER Bernd
2023-01-04 10:36               ` Peter Korsgaard
2023-01-04 10:40                 ` Ahmad Fatoum
2023-01-04 11:08                   ` Peter Korsgaard

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