From: Li Wang <liwang@redhat.com>
To: Andrew Morton <akpm@linux-foundation.org>
Cc: linux-kbuild@vger.kernel.org, linux-kselftest@vger.kernel.org
Subject: Re: tools/testing/selftests
Date: Sun, 29 Mar 2026 18:04:52 +0800 [thread overview]
Message-ID: <acj5RK3lze7o704Y@redhat.com> (raw)
In-Reply-To: <20260328140311.d6ce99302f93923b0cffb441@linux-foundation.org>
On Sat, Mar 28, 2026 at 02:03:11PM -0700, Andrew Morton wrote:
> On Sat, 28 Mar 2026 13:56:50 -0700 Andrew Morton <akpm@linux-foundation.org> wrote:
>
> > On Sat, 28 Mar 2026 10:12:06 +0800 Li Wang <liwang@redhat.com> wrote:
> >
> > > > from the top level?
> > >
> > > Should use:
> > >
> > > make kselftest
> >
>
> I'm probably doing something wrong, but `make -j50 kselftest-all'
> appears to have scribbled on my top-level Makefile, so now I'm getting
>
> ts:/usr/src/25> make kselftest-all
> /usr/src/25/Makefile:5: *** Too many open files. Stop.
>
> ts:/usr/src/25> cat Makefile
> # Automatically generated by /usr/src/25/Makefile: don't edit
> export KBUILD_OUTPUT = .
> export KBUILD_EXTMOD = /usr/src/25
> export KBUILD_EXTMOD_OUTPUT = /usr/src/25
> include /usr/src/25/Makefile
>
> I've done this twice in succession now. Any suggestions where I should
> look?
When build selftests from the top-level, sub-makes entered via `-C` may
still inherit the caller's PWD from the environment.
Some selftests use $(PWD) in recursive kbuild invocations, which can
then incorrectly resolve to the kernel top directory instead of the
current test directory.
Maybe try export PWD in the ../selftests/lib.mk?
export PWD := $(CURDIR)
--
Regards,
Li Wang
prev parent reply other threads:[~2026-03-29 10:04 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-27 21:32 tools/testing/selftests Andrew Morton
2026-03-28 2:12 ` tools/testing/selftests Li Wang
2026-03-28 4:09 ` tools/testing/selftests Andrew Morton
2026-03-29 9:29 ` tools/testing/selftests Li Wang
[not found] ` <20260328135650.435b415f8c00835b2fa471e0@linux-foundation.org>
2026-03-28 21:03 ` tools/testing/selftests Andrew Morton
2026-03-29 10:04 ` Li Wang [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=acj5RK3lze7o704Y@redhat.com \
--to=liwang@redhat.com \
--cc=akpm@linux-foundation.org \
--cc=linux-kbuild@vger.kernel.org \
--cc=linux-kselftest@vger.kernel.org \
/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