From: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
To: "Maciej W. Rozycki" <macro@orcam.me.uk>
Cc: WangYuli <wangyuli@aosc.io>,
Chen Linxuan <chenlinxuan@uniontech.com>,
linux-mips@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH v3 0/7] MIPS: Resolve build problems on decstation_64
Date: Sat, 26 Sep 2026 11:40:51 +0200 [thread overview]
Message-ID: <areTI4iW1pbaAwn3@alpha.franken.de> (raw)
In-Reply-To: <alpine.DEB.2.21.2609191504030.27665@angie.orcam.me.uk>
On Sat, Sep 19, 2026 at 04:14:06PM +0100, Maciej W. Rozycki wrote:
> Hi Thomas,
>
> I chose to rework this patchset on behalf of WangYuli after all; I'm not
> sure if his address cc'd works. I've reordered the changes to put fixes
> ahead of improvements and reworded the piece of inline documentation for
> the KBUILD_SYM32 option since, frankly, the one we have now is hard to
> comprehend.
>
> I have verified this patchset with my 5000/150. Please apply.
>
> Previous iteration (v2) at
> <https://lore.kernel.org/r/24EC7D2CA58B25F5+20250422101855.136675-1-wangyuli@uniontech.com/>.
>
> The original cover letter follows.
>
> Maciej
>
> [ Part 1 ]: MIPS: dec: Only check -msym32 when need compiler
>
> During 'make modules_install', the need-compiler variable becomes
> null, so Makefile.compiler isn't included.
>
> This results in call cc-option-yn returning nothing.
>
> For more technical details on why need-compiler is null during
> 'make modules_install' and why no compiler invocation is actually
> needed at this point, please refer to commit 4fe4a6374c4d ("MIPS:
> Only fiddle with CHECKFLAGS if need-compiler") and commit
> 805b2e1d427a ("kbuild: include Makefile.compiler only when compiler
> is needed").
>
> Commit a79a404e6c22 ("MIPS: Fix CONFIG_CPU_DADDI_WORKAROUNDS
> `modules_install' regression") tried to fix the same issue but it
> caused a compile error on clang compiler because it doesn't support
> '-msym32'. Then, commit 18ca63a2e23c ("MIPS: Probe toolchain support
> of -msym32") fixed it but reintroduced the CONFIG_CPU_DADDI_WORKAROUNDS
> `modules_install' regression.
>
> Wrapping this entire code block with #ifdef need-compiler to avoid
> all issues is the best solution for now.
>
> To get rid of spurious "CONFIG_CPU_DADDI_WORKAROUNDS unsupported
> without -msym32" error.
>
> Moreover, I also identified an unnecessary check for KBUILD_SYM32
> in this Makefile section. Eliminate it for code simplification.
>
> NOTE:
>
> It is particularly important to note that this code fix does not
> imply that we have resolved the problem entirely.
>
> In fact, the entire application of cc-option and its auxiliary
> commands within the kernel codebase currently carries significant
> risk.
>
> When we execute make modules_install, the Makefile for the
> corresponding architecture under arch/subarches/Makefile is
> invariably included. Within these files, there are numerous
> usages of cc-option and its auxiliary commands, all of which will
> return empty strings. The reason other architectures can
> successfully complete compilation under these circumstances is
> purely because they do not, unlike MIPS, check the return values
> of cc-option and its auxiliary commands within their Makefiles
> and halt the compilation process when the expected results are
> not received.
>
> A feasible approach to remediation might be to encapsulate all
> usages of cc-option and its auxiliary commands within conditional
> statements across all architecture Makefiles, preventing their
> execution entirely during make modules_install.
>
> However, this would lead to a massive number of inelegant
> modifications, and these broader implications may require
> deliberation by Masahiro Yamada.
>
> Regardless, this does not preclude us from addressing the
> issue on MIPS first.
>
> Link: https://lore.kernel.org/all/41107E6D3A125047+20250211135616.1807966-1-wangyuli@uniontech.com/
> Link: https://lore.kernel.org/all/F49F5EE9975F29EA+20250214094758.172055-1-wangyuli@uniontech.com/
> Link: https://lore.kernel.org/all/8ABBF323414AEF93+20250217142541.48149-1-wangyuli@uniontech.com/
>
>
> [ Part 2 ]: MIPS: decstation_64_defconfig: Compile the kernel with warnings as errors
>
> Patch ("MIPS: dec: Only check -msym32 when need compiler") allows
> us to compile kernel image packages with decstation_64_defconfig.
>
> However, compilation warnings remain during the build.
>
> Address these warnings and enable CONFIG_WERROR for decstation_64_defconfig.
>
> Link: https://lore.kernel.org/all/487CE8AA937621E2+20250218125101.663980-1-wangyuli@uniontech.com/
> Link: https://lore.kernel.org/all/EA0AFB15DDCF65C1+20250227141949.1129536-1-wangyuli@uniontech.com/
> Link: https://lore.kernel.org/all/303EFD6BFBDAC7C8+20250305033436.31214-1-wangyuli@uniontech.com/
>
>
> [ Changelog: ]
>
> *v1->v2: Add Philippe Mathieu-Daudé's "Reviewed-by" tag in patch3.
> Link: https://lore.kernel.org/all/11740B01E659CAFF+20250407073158.493183-1-wangyuli@uniontech.com/
> Link: https://lore.kernel.org/all/8dcb5c6d-be4f-4891-a999-137d53edfc05@linaro.org/
>
> WangYuli (6):
> MIPS: dec: Only check -msym32 when need compiler
> MIPS: Eliminate Redundant KBUILD_SYM32 Checks
> MIPS: dec: Create reset.h
> MIPS: dec: Remove dec_irq_dispatch()
> MIPS: decstation_64_defconfig: Update configs dependencies
> MIPS: decstation_64_defconfig: Compile the kernel with warnings as
> errors
>
> arch/mips/Makefile | 6 ++--
> arch/mips/configs/decstation_64_defconfig | 43 +++++++++--------------
> arch/mips/dec/int-handler.S | 2 +-
> arch/mips/dec/prom/init.c | 3 +-
> arch/mips/dec/reset.c | 2 ++
> arch/mips/dec/setup.c | 15 ++------
> arch/mips/include/asm/dec/reset.h | 20 +++++++++++
> 7 files changed, 47 insertions(+), 44 deletions(-)
> create mode 100644 arch/mips/include/asm/dec/reset.h
series applied to mips-next
Thomas.
--
Crap can work. Given enough thrust pigs will fly, but it's not necessarily a
good idea. [ RFC1925, 2.3 ]
prev parent reply other threads:[~2026-09-26 10:27 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-09-19 15:14 Maciej W. Rozycki
2026-09-19 15:14 ` [PATCH v3 1/7] MIPS: Only check -msym32 when need-compiler Maciej W. Rozycki
2026-09-21 14:54 ` Chen Linxuan
2026-09-19 15:14 ` [PATCH v3 2/7] MIPS: dec: Add missing <linux/interrupt.h> inclusion to reset.h Maciej W. Rozycki
2026-09-19 15:14 ` [PATCH v3 3/7] MIPS: decstation_64_defconfig: Regenerate for 7.x Maciej W. Rozycki
2026-09-19 15:14 ` [PATCH v3 4/7] MIPS: decstation_64_defconfig: Compile the kernel with warnings as errors Maciej W. Rozycki
2026-09-19 15:14 ` [PATCH v3 5/7] MIPS: Eliminate redundant KBUILD_SYM32 check Maciej W. Rozycki
2026-09-19 15:14 ` [PATCH v3 6/7] MIPS: Reword KBUILD_SYM32 documentation for clarity Maciej W. Rozycki
2026-09-19 15:15 ` [PATCH v3 7/7] MIPS: dec: Reorder header inclusions in setup.c Maciej W. Rozycki
2026-09-21 14:40 ` [PATCH v3 0/7] MIPS: Resolve build problems on decstation_64 Chen Linxuan
2026-09-26 9:40 ` Thomas Bogendoerfer [this message]
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=areTI4iW1pbaAwn3@alpha.franken.de \
--to=tsbogend@alpha.franken.de \
--cc=chenlinxuan@uniontech.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mips@vger.kernel.org \
--cc=macro@orcam.me.uk \
--cc=wangyuli@aosc.io \
/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
all inboxes | Powered by JetHome®