Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 19 Jul 2022 16:35:36 -0400
From:      Ed Maste <emaste@freebsd.org>
To:        "Rodney W. Grimes" <freebsd-rwg@gndrsh.dnsmgr.net>
Cc:        Mark Millard <marklmi@yahoo.com>, Glen Barber <gjb@freebsd.org>, Warner Losh <imp@bsdimp.com>,  dev-commits-src-main@freebsd.org, "Dr. Rolf Jansen" <freebsd-rj@cyclaero.com>,  freebsd-arm <freebsd-arm@freebsd.org>
Subject:   Re: git: 1dfcff294e44 - main - release: increase IMAGE_SIZE for arm, arm64, riscv [odd alignment for SBC images]
Message-ID:  <CAPyFy2D1aBe8h4kq=RqCR2tkEiEXh_pHNEqaAnW7tk9-HxCmBQ@mail.gmail.com>
In-Reply-To: <202207171708.26HH81bA062303@gndrsh.dnsmgr.net>
References:  <16906DFD-286B-4D59-9438-CA9CD9026C55@yahoo.com> <202207171708.26HH81bA062303@gndrsh.dnsmgr.net>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 17 Jul 2022 at 13:08, Rodney W. Grimes
<freebsd-rwg@gndrsh.dnsmgr.net> wrote:

> Perhaps an assert for kern.geom.part.mbr.enforce_chs not
> being zero in /usr/src/release scripts is in order so that
> the builds blow up rather than produce BAD images.

This is a good interim step (before switching to mkimg).

Perhaps:

diff --git a/release/tools/arm.subr b/release/tools/arm.subr
index 77b708bca4a2..94e0ee89deaf 100644
--- a/release/tools/arm.subr
+++ b/release/tools/arm.subr
@@ -62,6 +62,10 @@ umount_loop() {
 }

 arm_create_disk() {
+       if [ $(sysctl -n kern.geom.part.mbr.enforce_chs) != 0 ]; then
+               return 1
+       fi
+
        # Create the target raw file and temporary work directory.
        chroot ${CHROOTDIR} gpart create -s ${PART_SCHEME} ${mddev}
        if [ "${PART_SCHEME}" = "GPT" ]; then



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?CAPyFy2D1aBe8h4kq=RqCR2tkEiEXh_pHNEqaAnW7tk9-HxCmBQ>