Linux-ARM-Kernel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Ethan Nelson-Moore <enelsonmoore@gmail.com>
To: linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org
Cc: Ethan Nelson-Moore <enelsonmoore@gmail.com>,
	Russell King <linux@armlinux.org.uk>
Subject: [PATCH] arm: boot: head-sharpsl.S: don't rely on MACH_TYPE_* of removed boards
Date: Fri,  8 May 2026 18:13:20 -0700	[thread overview]
Message-ID: <20260509011322.13013-1-enelsonmoore@gmail.com> (raw)

Code in head-sharpsl.S relies on the MACH_TYPE_* constants for five
boards that are no longer supported by the kernel. They were removed in
commit d6df7df7ae5a ("ARM: pxa: remove unused board files"). This
prevents the removal of boards no longer present in the kernel from
mach-types. Replace the MACH_TYPE_* references with hardcoded values.
(If the IDs were simply removed, these boards would be detected as
other supported machines, causing incorrect behavior. The kernel will
abort on detecting an unsupported machine ID.)

Signed-off-by: Ethan Nelson-Moore <enelsonmoore@gmail.com>
---
 arch/arm/boot/compressed/head-sharpsl.S | 16 +++++++++++-----
 1 file changed, 11 insertions(+), 5 deletions(-)

diff --git a/arch/arm/boot/compressed/head-sharpsl.S b/arch/arm/boot/compressed/head-sharpsl.S
index 992e784500fa..da05e01903e2 100644
--- a/arch/arm/boot/compressed/head-sharpsl.S
+++ b/arch/arm/boot/compressed/head-sharpsl.S
@@ -103,16 +103,22 @@ __SharpSL_start:
 	.word 	0x08010000		@ w100 Chip ID Reg Address
 .SCOOP2ADDR:
 	.word	0x08800040
+/*
+ * These five machines are no longer supported by the kernel, but if checks for
+ * them were removed, they would be detected as other supported machines,
+ * causing incorrect behavior. The kernel will abort on detecting an unsupported
+ * machine ID.
+ */
 .POODLEID:
-	.word	MACH_TYPE_POODLE
+	.word	424			@ MACH_TYPE_POODLE
 .CORGIID:
-	.word	MACH_TYPE_CORGI
+	.word	423			@ MACH_TYPE_CORGI
 .SHEPHERDID:
-	.word	MACH_TYPE_SHEPHERD
+	.word	545			@ MACH_TYPE_SHEPHERD
 .HUSKYID:
-	.word	MACH_TYPE_HUSKY
+	.word	543			@ MACH_TYPE_HUSKY
 .TOSAID:
-	.word	MACH_TYPE_TOSA
+	.word	520			@ MACH_TYPE_TOSA
 .SPITZID:
 	.word	MACH_TYPE_SPITZ
 .AKITAID:
-- 
2.43.0



                 reply	other threads:[~2026-05-09  1:14 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=20260509011322.13013-1-enelsonmoore@gmail.com \
    --to=enelsonmoore@gmail.com \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    /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