From: Nicolas Schier <nsc@kernel.org>
To: Nathan Chancellor <nathan@kernel.org>
Cc: "Thomas Weißschuh" <thomas.weissschuh@linutronix.de>,
linux-kbuild@vger.kernel.org, linux-kernel@vger.kernel.org,
"Anish Rashinkar" <rashinkar.anish@gmail.com>,
stable@vger.kernel.org, "Philipp Hahn" <p.hahn@avm.de>
Subject: Re: [PATCH RESEND] kbuild: Stop modifying $(objtree)/Makefile when building oot-kmods oos
Date: Fri, 24 Jul 2026 06:57:53 +0200 [thread overview]
Message-ID: <amLw0RbalfDGzyJl@levanger> (raw)
In-Reply-To: <178484858201.4095280.2018856728416028444.b4-review@b4>
On Thu, Jul 23, 2026 at 04:16:22PM -0700, Nathan Chancellor wrote:
> > Update output Makefile in the corresponding tree only: for out-of-source
> > in-tree builds update $(objtree)/Makefile, for out-of-source out-of-tree
> > module builds update $(KBUILD_EXTMOD_OUTPUT)/Makefile instead.
> >
> > In-source builds are not affected.
> >
> > Since commit c9bb03ac2c66 ("kbuild: reduce output spam when building out
> > of tree"), building out-of-tree kernel modules out-of-source (make M=...
> > MO=...) causes a rewrite of $(objtree)/Makefile with KBUILD_EXTMOD and
> > KBUILD_EXTMOD_OUTPUT being set. That is problematic:
> >
> > * $(objtree)/ must not be changed in any way when building out-of-tree
> > modules as it breaks other uses of $(objtree).
> >
> > * Setting KBUILD_EXTMOD and KBUILD_EXTMOD_OUTPUT in $(objtree)/Makefile
> > kills the tree for incremental builds that start right there
> > ('make -C $(objtree)'); builds starting in $(srctree) reset
> > $(objtree)/Makefile to its original content.
> >
> > Further, $(KBUILD_EXTMOD_OUTPUT)/Makefile was not generated any more at
> > all.
> >
> > This commit restores the previous kbuild behaviour prior to commit
> > c9bb03ac2c66 ("kbuild: reduce output spam when building out of tree")
> > but leaves in-place the use of filechk for output spam reduction.
> >
> > Fixes: c9bb03ac2c66 ("kbuild: reduce output spam when building out of tree")
> > Reported-by: Anish Rashinkar <rashinkar.anish@gmail.com>
> > Closes: https://lore.kernel.org/r/CAOESE2Q2-0KUDaM0mUo+c_F-tMaUsBZ-gpnhdoe0rmYdgnnuJQ@mail.gmail.com
> > Cc: stable@vger.kernel.org
> > Tested-by: Philipp Hahn <p.hahn@avm.de>
> > Reviewed-by: Philipp Hahn <p.hahn@avm.de>
> > Signed-off-by: Nicolas Schier <n.schier@fritz.com>
> > Signed-off-by: Nicolas Schier <nsc@kernel.org>
>
> Thanks!
>
> Reviewed-by: Nathan Chancellor <nathan@kernel.org>
> Tested-by: Nathan Chancellor <nathan@kernel.org>
>
> Do you want me to take this via kbuild-fixes?
Yes, please take it via kbuild-fixes, as it actually breaks build trees.
Thanks!
--
Nicolas
next prev parent reply other threads:[~2026-07-24 5:00 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-23 10:58 Nicolas Schier
2026-07-23 23:16 ` Nathan Chancellor
2026-07-24 4:57 ` Nicolas Schier [this message]
2026-07-25 0:49 ` Nathan Chancellor
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=amLw0RbalfDGzyJl@levanger \
--to=nsc@kernel.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=nathan@kernel.org \
--cc=p.hahn@avm.de \
--cc=rashinkar.anish@gmail.com \
--cc=stable@vger.kernel.org \
--cc=thomas.weissschuh@linutronix.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
Powered by JetHome