mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: "H. Peter Anvin" <hpa@zytor.com>
To: "Thomas Weißschuh" <thomas.weissschuh@linutronix.de>
Cc: "Vincenzo Frascino" <vincenzo.frascino@arm.com>,
	"Nathan Chancellor" <nathan@kernel.org>,
	"Nicolas Schier" <nsc@kernel.org>,
	"Thomas Gleixner" <tglx@kernel.org>,
	"Andy Lutomirski" <luto@kernel.org>,
	"Ingo Molnar" <mingo@redhat.com>,
	"Borislav Petkov" <bp@alien8.de>,
	"Dave Hansen" <dave.hansen@linux.intel.com>,
	x86@kernel.org, linux-kbuild@vger.kernel.org,
	linux-kernel@vger.kernel.org, "Nam Cao" <namcao@linutronix.de>,
	"Sebastian Andrzej Siewior" <bigeasy@linutronix.de>,
	"André Almeida" <andrealmeid@igalia.com>
Subject: Re: [PATCH] vDSO, kbuild: Provide vDSO debug variants at runtime
Date: Fri, 10 Jul 2026 00:32:55 -0700	[thread overview]
Message-ID: <DC26CD8F-9767-4544-A157-8367439CE0BA@zytor.com> (raw)
In-Reply-To: <20260710081440-d355b1fd-c34d-40bb-965c-8bbe2a8c375a@linutronix.de>

On July 9, 2026 11:36:25 PM PDT, "Thomas Weißschuh" <thomas.weissschuh@linutronix.de> wrote:
>On Thu, Jul 09, 2026 at 12:06:07PM -0700, H. Peter Anvin wrote:
>> On July 9, 2026 2:57:09 AM PDT, Vincenzo Frascino <vincenzo.frascino@arm.com> wrote:
>> >On 08/07/2026 14:56, Thomas Weißschuh wrote:
>> >> Finding the debug version of the vDSO is not trivial as there is no common
>> >> scheme where it is placed. That's especially problematic for CI testing.
>> >> 
>> >> The vDSO futex unlock mechanism requires for testing to have access to the
>> >> inner labels of the unlock assembly, which are only accessible via the
>> >> debug so.
>> >> 
>> >> Also for general debugging purposes it's convenient to have access to the
>> >> debug vDSO at a well defined place.
>> >> 
>> >> The files are placed in /sys/kernel/vdso_debug.tar.xz. They use the
>> >> regular 'make vdso_install' layout, including build-id symlinks to find
>> >> the correct file for each process.
>> >> 
>> >> The design is kept close to the ones of the similar IKCONFIG and IKHEADERS.
>> >> 
>> >> On x86 the x32 vDSO is derived from the x86_64 one, necessitating an
>> >> explicit dependency to avoid errors due to concurrent builds.
>> >> 
>> >> Suggested-by: Thomas Gleixner <tglx@kernel.org>
>> >> Link: https://lore.kernel.org/lkml/20260602090536.045586688@kernel.org/
>> >> Signed-off-by: Thomas Weißschuh <thomas.weissschuh@linutronix.de>
>
>(...)
>
>> Why stuff them into a tarball?
>
>Because it was the easiest solution to implement and has been sufficient
>for IKHEADERS so far. I don't see a clearly winning solution among the
>possibilities to expose a directory:
>
>* Use plain sysfs:
>  Requires a new code generator and potentially changes to sysfs
>
>* Use a read-only filesystem like cramfs/erofs:
>  Introduces new build-time and runtime dependencies
>
>* Add a new filesystem backed by a tarball or cpio archive:
>  Lot's of complexity and work to implement
>
>But I am open to discussions and other ideas.
>
>
>Thomas

I discussed this with GregKH a while ago, in the context of eventually making the vdso an actual mapping of a virtual file. According to him it should be quite simple in sysfs; I got a bit stumped on the necessary hooks (the kernel needs to keep track of where the vdso lives in the address space.)

  reply	other threads:[~2026-07-10  7:33 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-08 13:56 Thomas Weißschuh
2026-07-08 15:28 ` André Almeida
2026-07-15 12:29   ` André Almeida
2026-07-24 14:14     ` Thomas Weißschuh
2026-07-09  9:57 ` Vincenzo Frascino
2026-07-09 19:06   ` H. Peter Anvin
2026-07-10  6:36     ` Thomas Weißschuh
2026-07-10  7:32       ` H. Peter Anvin [this message]
2026-07-10  7:41         ` Thomas Weißschuh
2026-07-10 18:34           ` H. Peter Anvin
2026-07-13 13:17             ` Thomas Weißschuh
2026-10-27 20:22 ` Nicolas Schier
2026-10-28  0:02   ` H. Peter Anvin
2026-10-28  5:55     ` Thomas Weißschuh
2026-10-28  6:12       ` H. Peter Anvin

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=DC26CD8F-9767-4544-A157-8367439CE0BA@zytor.com \
    --to=hpa@zytor.com \
    --cc=andrealmeid@igalia.com \
    --cc=bigeasy@linutronix.de \
    --cc=bp@alien8.de \
    --cc=dave.hansen@linux.intel.com \
    --cc=linux-kbuild@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=luto@kernel.org \
    --cc=mingo@redhat.com \
    --cc=namcao@linutronix.de \
    --cc=nathan@kernel.org \
    --cc=nsc@kernel.org \
    --cc=tglx@kernel.org \
    --cc=thomas.weissschuh@linutronix.de \
    --cc=vincenzo.frascino@arm.com \
    --cc=x86@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

all inboxes | Powered by JetHome®