From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-wr1-f53.google.com (mail-wr1-f53.google.com [209.85.221.53]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0951B3A6B8E for ; Sun, 10 May 2026 17:40:55 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.221.53 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778434857; cv=none; b=bNyvfvjQb0UiJxXro7IQvn/zJpD487KPWN6DMym6jM545EDEPG5AjFDmG02loKnQsf93XpuaHZMZAIpPm03Yfc0UTSiqXb/mGfdurkfUKK+c+us+0H4JGUgO5HXeQn2O8lpvMvvnsr2EX2p51opGGGcHaKoediJakVyXeVHZ/xM= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1778434857; c=relaxed/simple; bh=rwY1wZgWP6lAxH5fQhy+fB4NQcmidi0m7y3TQiRbKvU=; h=Message-ID:Subject:From:To:Cc:Date:In-Reply-To:References: Content-Type:MIME-Version; b=uaf3bLmxZh2M0F5wCILuqvawPN4tnwmRAEHfpDH0QmpyoQFFkJKFVHXGpQ03m0KtyRoelNa1SrInBb5U8zaPysdDR+jnLl5A9y0Blk4qq6vPtt1zObzDuHLpUo+TefoiZDdbtPxEUzrTi5bNlcUpgOiQ/Il3Ou/ijLESGMpyPZo= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=c0Q5Z/aK; arc=none smtp.client-ip=209.85.221.53 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="c0Q5Z/aK" Received: by mail-wr1-f53.google.com with SMTP id ffacd0b85a97d-449d6c68ed8so3079707f8f.0 for ; Sun, 10 May 2026 10:40:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20251104; t=1778434854; x=1779039654; darn=vger.kernel.org; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:from:to:cc:subject :date:message-id:reply-to; bh=Zv/ru0QR6grpm7KNdBiLatfgWhf7D3FKLR22CUG+sp4=; b=c0Q5Z/aKOkQTa9TndlAGxGV637YH7OsInRh/Ct4I+xj5rAzJVRl4pIp5VRn3k3iq0V yl36tDmkPZ+6ijnLIjZVHZrLBBZmlby0hDqk65v7XBcNkZAXM4jqi/VOtLzIj3NjkfBx NBXh2AqAgIF55CfVtZMJ57YF9MoErkS2wlutYCpQudVpMS3s+46HknGxHloQOw2mn7Yf L2CzZMpfAk6PJCtshHbwvHT6sqf8lomYQo+9ZTGgfDbA+0Hk94Ydfc3ysk8Y07dwGmqQ PUlq38A1AzN0LASSak5mIe+enBpLCH9TOQ5XgHdmp+t4Ps49QT2fYL7xQf6zkqn+zgsv C7Zw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20251104; t=1778434854; x=1779039654; h=mime-version:user-agent:content-transfer-encoding:references :in-reply-to:date:cc:to:from:subject:message-id:x-gm-gg :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Zv/ru0QR6grpm7KNdBiLatfgWhf7D3FKLR22CUG+sp4=; b=pTqY6HhXgz5hk/aOQdJ2QvaO8MJPhra+6mg+HHdmUJS+DXrCuvaYKIj/DeuWk4EsPU HHo208iGiajIZ8luLPqkEkVX+QJ5iYwfvNsMg+SMKGuOtrY/eM6nSRktyj5l4hmTfH7v 8OakJxyfihAXxXiXfxfG6FX4r+cvORtLU8pFq6DULPvd61IlQmn+WLm6dHcPdty6Hy48 H7uOUgHPhNnDYeTcB+SkkBRVlm1Xg2GKjYQn3mfS+m0xkTluuKXQ+zUsxg5bMeELV8o/ WdVZb/Qoapbm1jLwR264AzlCMyhChRzxVWw8ZaNDnzrb6KM+YPjPR1m49+7DYrVtQECU Bvvw== X-Forwarded-Encrypted: i=1; AFNElJ/QLikQB+e2lSO2R3O+glbw9IoZiRFrum9N6qJGQqSrzSlg7bNEwW3uqU5SiforI/O7fM4+X96AISS7kEc=@vger.kernel.org X-Gm-Message-State: AOJu0Yx9V/76B53DstmdMZ3lVHu1PET2dqbNBQ2bWwlC8odDYxirqQ04 6iPDboqEtb+8Yn3tjRmUOiIo8KbS0pgoD+iI6Jcaz1po5FvJyAFg6a4H X-Gm-Gg: Acq92OHG4oVgWWpwFcP+tpSCufCkq/WSgb7ji94KuiWyeDbijdApvAQo4iRjaCL/aVX krsfHeSt6Vz11YN5s6OOdd7G5FZbi3I+Vg5zKSeoXROMss2226kWb8Pz7Y4Ob9EjIafvc+JbA7R TiPwP07YcvS/9MsyD5UHi4qkkZNKBjTmaV6RWChEutgL2tY9gDF10+LP1Z2mVQZKNC1q2a+5EWh kau8DH71eVBuMoFINi0qo/xZqWxmhZHH6/qJVU3IAHKfJ0zQgtrLJzrXLKYof+Emmk4Y8CloTPk FhfiLOxyO0VFU7yCdAkcj0Bccey3KD0SSxoR528bzSW1owd8M/03F50rDw0s+2FVtWmqqS1nJo/ YKcIdhL66odktjJgpUY6oUPX70EkNR7iuKja9Y3wnvdsKTS44U8w2jVT3Y4CgAxkBHZrfRDBu/c sI+fr2F9Cg2YjI+obbfEa+65dPMpvz+nE04V0Qp0Qu/6cBC7cn6D1ElMtiF3tvN8btpade3BWiS HKN144= X-Received: by 2002:a05:6000:61e:b0:44f:f2d5:a401 with SMTP id ffacd0b85a97d-456a4ac9619mr9575531f8f.37.1778434854250; Sun, 10 May 2026 10:40:54 -0700 (PDT) Received: from 0.1.2.1.2.0.a.2.dynamic.cust.swisscom.net ([2a02:1210:8642:2b00:82ee:73ff:feb8:99e3]) by smtp.gmail.com with ESMTPSA id ffacd0b85a97d-4548ec6c221sm20183334f8f.13.2026.05.10.10.40.51 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Sun, 10 May 2026 10:40:52 -0700 (PDT) Message-ID: <26be9a11b5f2a7d196904d9a97306d2aafb9bf1c.camel@gmail.com> Subject: Re: [PATCH] arm: boot: ep93xx: don't rely on machine_is_*() for removed board files From: Alexander Sverdlin To: Ethan Nelson-Moore , linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org Cc: Russell King , Hartley Sweeten , Nikita Shubin Date: Sun, 10 May 2026 19:40:54 +0200 In-Reply-To: <20260509223820.50347-1-enelsonmoore@gmail.com> References: <20260509223820.50347-1-enelsonmoore@gmail.com> Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable User-Agent: Evolution 3.60.1 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Hi Ethan, On Sat, 2026-05-09 at 15:38 -0700, Ethan Nelson-Moore wrote: > Code in misc-ep93xx.h relies on machine_is_*() macros for several > boards that no longer have legacy board files. They were removed in > commit e5ef574dda70 ("ARM: ep93xx: delete all boardfiles"). This > prevents the removal of machine IDs no longer used by the kernel from > mach-types. To resolve this issue, create local copies of these macros. > (The checks themselves are still valid because the IDs are still passed > in by the bootloader on these machines.) Also take the opportunity to > remove three repeated checks for the same ID. I most probably miss something, but what is the reason for removing the machine IDs from the mach-types, especially if they are still used by the kernel (though only in its decompressor code)? > Signed-off-by: Ethan Nelson-Moore > --- > =C2=A0arch/arm/boot/compressed/misc-ep93xx.h | 20 ++++++++++++++++---- > =C2=A01 file changed, 16 insertions(+), 4 deletions(-) >=20 > diff --git a/arch/arm/boot/compressed/misc-ep93xx.h b/arch/arm/boot/compr= essed/misc-ep93xx.h > index 65b4121d1490..b0a1b42aab31 100644 > --- a/arch/arm/boot/compressed/misc-ep93xx.h > +++ b/arch/arm/boot/compressed/misc-ep93xx.h > @@ -3,7 +3,22 @@ > =C2=A0 * Copyright (C) 2006 Lennert Buytenhek > =C2=A0 */ > =C2=A0 > -#include > +/* > + * These machine IDs are no longer used by the kernel since EP93xx was c= onverted > + * to DT booting, but they are still passed in by bootloaders, so we use= our own > + * local definitions of the relevant macros. > + */ > +#define machine_is_bk3() (__machine_arch_type =3D=3D 1880) > +#define machine_is_edb9301() (__machine_arch_type =3D=3D 462) > +#define machine_is_edb9302a() (__machine_arch_type =3D=3D 1127) > +#define machine_is_edb9302() (__machine_arch_type =3D=3D 538) > +#define machine_is_edb9307a() (__machine_arch_type =3D=3D 1128) > +#define machine_is_edb9307() (__machine_arch_type =3D=3D 607) > +#define machine_is_edb9312() (__machine_arch_type =3D=3D 451) > +#define machine_is_edb9315a() (__machine_arch_type =3D=3D 772) > +#define machine_is_edb9315() (__machine_arch_type =3D=3D 463) > +#define machine_is_ts72xx() (__machine_arch_type =3D=3D 673) > +#define machine_is_vision_ep9307() (__machine_arch_type =3D=3D 1578) > =C2=A0 > =C2=A0static inline unsigned int __raw_readl(unsigned int ptr) > =C2=A0{ > @@ -60,14 +75,11 @@ static inline void ep93xx_decomp_setup(void) > =C2=A0 if (machine_is_edb9301() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_edb9302() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_edb9302a() || > - =C2=A0=C2=A0=C2=A0 machine_is_edb9302a() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_edb9307() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_edb9307a() || > - =C2=A0=C2=A0=C2=A0 machine_is_edb9307a() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_edb9312() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_edb9315() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_edb9315a() || > - =C2=A0=C2=A0=C2=A0 machine_is_edb9315a() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_ts72xx() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_bk3() || > =C2=A0 =C2=A0=C2=A0=C2=A0 machine_is_vision_ep9307()) --=20 Alexander Sverdlin.