From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Wed, 22 Nov 2023 15:17:16 +0100 Received: from metis.whiteo.stw.pengutronix.de ([2a0a:edc0:2:b01:1d::104]) by lore.white.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1r5o2V-004Ryp-2N for lore@lore.pengutronix.de; Wed, 22 Nov 2023 15:17:16 +0100 Received: from localhost ([127.0.0.1] helo=metis.whiteo.stw.pengutronix.de) by metis.whiteo.stw.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1r5o2V-0002qV-Tn; Wed, 22 Nov 2023 15:17:15 +0100 Received: from drehscheibe.grey.stw.pengutronix.de ([2a0a:edc0:0:c01:1d::a2]) by metis.whiteo.stw.pengutronix.de with esmtps (TLS1.3:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1r5o2S-0002qG-CW; Wed, 22 Nov 2023 15:17:12 +0100 Received: from [2a0a:edc0:2:b01:1d::c5] (helo=pty.whiteo.stw.pengutronix.de) by drehscheibe.grey.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.94.2) (envelope-from ) id 1r5o2R-00ApiO-Va; Wed, 22 Nov 2023 15:17:12 +0100 Received: from rhi by pty.whiteo.stw.pengutronix.de with local (Exim 4.94.2) (envelope-from ) id 1r5o2R-00HJ7C-MU; Wed, 22 Nov 2023 15:17:11 +0100 Date: Wed, 22 Nov 2023 15:17:11 +0100 From: Roland Hieber To: Ahmad Fatoum Message-ID: <20231122141711.iudghqftvkpp7wf2@pengutronix.de> References: <20231020090519.3320460-1-rhi@pengutronix.de> <20231020090519.3320460-3-rhi@pengutronix.de> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Disposition: inline In-Reply-To: Subject: Re: [DistroKit] =?utf-8?q?=5BPATCH_v3_3/6=5D_v7a=3A_barebox=3A_pass_?= =?utf-8?q?root=3DmmcblkXpN_instead_of_root=3DPARTUUID=3D=E2=80=A6_to_kern?= =?utf-8?q?el?= X-BeenThere: distrokit@pengutronix.de X-Mailman-Version: 2.1.29 Precedence: list List-Id: DistroKit Mailinglist List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: distrokit@pengutronix.de Sender: "DistroKit" X-SA-Exim-Connect-IP: 127.0.0.1 X-SA-Exim-Mail-From: distrokit-bounces@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false On Wed, Nov 22, 2023 at 02:27:00PM +0100, Ahmad Fatoum wrote: > Hello Roland, > > On 20.10.23 11:05, Roland Hieber wrote: > > Kernels prior to v5.10-rc1 could not ensure deterministic ordering for > > MMC devices. For this reason, the default 'append-root' behaviour of > > barebox for MMC block devices is to append a 'root=PARTUUID=XYZ' option > > to the kernel command line. The PARTUUID is derived from the partition > > table and is expected to be unique system-wide. This is however > > susceptible to breakage if the exact same image is written to different > > boot media in the system, e.g. SD and eMMC, so the PARTUUID will no > > longer uniquely refer to a single partition. > > > > Newer kernel versions honor the numbering used for 'mmc' aliases, > > which makes 'root=mmcblkXpN' deterministic as long as barebox and > > kernel aliases are identical. Since we're using kernel 6.4, enable this > > option in barebox. > > As you mention this feature requires that barebox and kernel aliases > are identical. At least for the STM32MP157C-EV1, this is not the case > as the kernel device tree has no aliases at all. Oh. How come? Can we patch the kernel DT to make them the same? > Can you send a revert? I can send a revert, but I don't like the implications. Incidentally, this topic was discussed in length last week on a systemd pull request of mine [1], with the TL;DR that filesystem and partition UUIDs should not generally be considered unique. While that might be the case in the DistroKit test runs, we also have some boards with eMMCs that can hold the same image as the SD cards that we boot from. I suspect this might come back to bite us some time in the future. [1]: https://github.com/systemd/systemd/pull/29219#issuecomment-1812226959 - Roland -- Roland Hieber, Pengutronix e.K. | r.hieber@pengutronix.de | Steuerwalder Str. 21 | https://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |