From: Ahmad Fatoum <a.fatoum@pengutronix.de>
To: distrokit@pengutronix.de
Cc: Ahmad Fatoum <a.fatoum@pengutronix.de>
Subject: [DistroKit] [PATCH 5/6] datapartition: disable autoformat of non-MBR Linux partitions
Date: Mon, 2 Mar 2020 12:03:55 +0100 [thread overview]
Message-ID: <20200302110356.19112-6-a.fatoum@pengutronix.de> (raw)
In-Reply-To: <20200302110356.19112-1-a.fatoum@pengutronix.de>
The upcoming STM32MP157C-DK2 board will be the first DistroKit board
with a GPT based image and it has barebox as partition 3, unlike the
other boards where this is always the data partition.
This causes the data partition rule to brick the image by overwriting
barebox.
As a temporary measure, disable the data partition auto formatting
on GPT-images by explicitly checking for partition type 0x83 before
starting the service. Eventually we might want to match against
a UUID before autoformatting, or create the partition anew altogether.
Signed-off-by: Ahmad Fatoum <a.fatoum@pengutronix.de>
---
projectroot/usr/lib/udev/rules.d/91-mkfs-ext4.rules | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/projectroot/usr/lib/udev/rules.d/91-mkfs-ext4.rules b/projectroot/usr/lib/udev/rules.d/91-mkfs-ext4.rules
index 1c1a39612aed..8af8f6cd39ba 100644
--- a/projectroot/usr/lib/udev/rules.d/91-mkfs-ext4.rules
+++ b/projectroot/usr/lib/udev/rules.d/91-mkfs-ext4.rules
@@ -1,5 +1,5 @@
ACTION!="add", GOTO="systemd-autoformat-ext4-devices_end"
SUBSYSTEM!="block", GOTO="systemd-autoformat-ext4-devices_end"
-ENV{ID_FS_USAGE}!="filesystem", SUBSYSTEMS=="mmc", KERNEL=="mmcblk0p3", ENV{ID_FS_TYPE}!="ext4", ENV{SYSTEMD_WANTS}+="systemd-autoformat@$name.service"
+ENV{ID_FS_USAGE}!="filesystem", SUBSYSTEMS=="mmc", KERNEL=="mmcblk0p3", ENV{ID_PART_ENTRY_TYPE}=="0x83", ENV{ID_FS_TYPE}!="ext4", ENV{SYSTEMD_WANTS}+="systemd-autoformat@$name.service"
LABEL="systemd-autoformat-ext4-devices_end"
--
2.25.0
_______________________________________________
DistroKit mailing list
DistroKit@pengutronix.de
next prev parent reply other threads:[~2020-03-02 11:03 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-03-02 11:03 [DistroKit] [PATCH 0/6] v7a: add basic STM32MP157C-DK2 support Ahmad Fatoum
2020-03-02 11:03 ` [DistroKit] [PATCH 1/6] v7a: kernel: configure for STM32MP157 support Ahmad Fatoum
2020-03-05 16:43 ` Robert Schwebel
2020-03-02 11:03 ` [DistroKit] [PATCH 2/6] v7a: barebox: add new stm32mp rule Ahmad Fatoum
2020-03-03 9:43 ` Roland Hieber
2020-03-03 9:54 ` Ahmad Fatoum
2020-03-05 16:44 ` Robert Schwebel
2020-03-02 11:03 ` [DistroKit] [PATCH 3/6] rules: add ARM Trusted Firmware-A Ahmad Fatoum
2020-03-05 16:44 ` Robert Schwebel
2020-03-05 17:28 ` Robert Schwebel
2020-03-02 11:03 ` [DistroKit] [PATCH 4/6] v7a: stm32mp: enable TF-A for first stage Ahmad Fatoum
2020-03-05 16:45 ` Robert Schwebel
2020-03-02 11:03 ` Ahmad Fatoum [this message]
2020-03-05 16:45 ` [DistroKit] [PATCH 5/6] datapartition: disable autoformat of non-MBR Linux partitions Robert Schwebel
2020-03-02 11:03 ` [DistroKit] [PATCH 6/6] v7a: add stm32mp157c-dk2 SD-Card image Ahmad Fatoum
2020-03-03 12:08 ` Roland Hieber
2020-03-05 16:46 ` Robert Schwebel
2020-03-05 16:46 ` Robert Schwebel
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=20200302110356.19112-6-a.fatoum@pengutronix.de \
--to=a.fatoum@pengutronix.de \
--cc=distrokit@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