linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: "Arnd Bergmann" <arnd@arndb.de>
To: "Thomas Weißschuh" <thomas.weissschuh@linutronix.de>,
	"Conor Dooley" <conor@kernel.org>
Cc: "James E . J . Bottomley" <James.Bottomley@hansenpartnership.com>,
	"Helge Deller" <deller@gmx.de>,
	"Andy Lutomirski" <luto@kernel.org>,
	"Thomas Gleixner" <tglx@linutronix.de>,
	"Vincenzo Frascino" <vincenzo.frascino@arm.com>,
	"Anna-Maria Gleixner" <anna-maria@linutronix.de>,
	"Frederic Weisbecker" <frederic@kernel.org>,
	"Andrew Morton" <akpm@linux-foundation.org>,
	"Catalin Marinas" <catalin.marinas@arm.com>,
	"Will Deacon" <will@kernel.org>, "Theodore Ts'o" <tytso@mit.edu>,
	"Jason A . Donenfeld" <Jason@zx2c4.com>,
	"Paul Walmsley" <paul.walmsley@sifive.com>,
	"Palmer Dabbelt" <palmer@dabbelt.com>,
	"Albert Ou" <aou@eecs.berkeley.edu>,
	"Huacai Chen" <chenhuacai@kernel.org>,
	"WANG Xuerui" <kernel@xen0n.name>,
	"Russell King" <linux@armlinux.org.uk>,
	"Heiko Carstens" <hca@linux.ibm.com>,
	"Vasily Gorbik" <gor@linux.ibm.com>,
	"Alexander Gordeev" <agordeev@linux.ibm.com>,
	"Christian Borntraeger" <borntraeger@linux.ibm.com>,
	"Sven Schnelle" <svens@linux.ibm.com>,
	"Thomas Bogendoerfer" <tsbogend@alpha.franken.de>,
	"Michael Ellerman" <mpe@ellerman.id.au>,
	"Nicholas Piggin" <npiggin@gmail.com>,
	"Christophe Leroy" <christophe.leroy@csgroup.eu>,
	"Naveen N Rao" <naveen@kernel.org>,
	"Madhavan Srinivasan" <maddy@linux.ibm.com>,
	"Ingo Molnar" <mingo@redhat.com>,
	"Borislav Petkov" <bp@alien8.de>,
	"Dave Hansen" <dave.hansen@linux.intel.com>,
	x86@kernel.org, "H. Peter Anvin" <hpa@zytor.com>,
	linux-parisc@vger.kernel.org, linux-kernel@vger.kernel.org,
	linux-arm-kernel@lists.infradead.org,
	linux-riscv@lists.infradead.org, loongarch@lists.linux.dev,
	linux-s390@vger.kernel.org, linux-mips@vger.kernel.org,
	linuxppc-dev@lists.ozlabs.org,
	Linux-Arch <linux-arch@vger.kernel.org>,
	"Nam Cao" <namcao@linutronix.de>
Subject: Re: [PATCH 07/17] riscv: vdso: Switch to generic storage implementation
Date: Wed, 18 Dec 2024 17:35:31 +0100	[thread overview]
Message-ID: <137c0594-e178-4c91-bc8b-5f99b3ddb2f0@app.fastmail.com> (raw)
In-Reply-To: <20241218162031-ee920684-db10-4f17-b1cb-50373d7ea954@linutronix.de>

On Wed, Dec 18, 2024, at 16:46, Thomas Weißschuh wrote:
> On Wed, Dec 18, 2024 at 03:08:28PM +0000, Conor Dooley wrote:
>> On Mon, Dec 16, 2024 at 03:10:03PM +0100, Thomas Weißschuh wrote:

>> Might be a clang thing, allmodconfig with clang doesn't build either.
>
> The proposed generic storage infrastructure currently expects that all
> its users also use HAVE_GENERIC_VDSO.
> I missed rv32 when checking this assumption.
>
> I can add a bunch of ifdefs into the storage code to handle this.
>
> Or we re-add the time vDSO functions which were removed in commit
> d4c08b9776b3 ("riscv: Use latest system call ABI").
> Today there are upstream ports of musl and glibc which can use them.
> (currently musl even tries to use __vdso_clock_gettime() as 64-bit only
> on rv32 due to a copy-and-paste error from its rv64 code)

Adding back __vdso_clock_gettime() wouldn't work on rv32 because there
is no fallback syscall for it, and it wouldn't really help since
there is no existing userspace that uses time32 structures.

> There is precedence in providing 64bit only vDSO functions, for example
> __vdso_clock_gettime64() in arm.
> I do have a small, so far untested, proof-of-concept patch for it.
> This would even be less code than the ifdefs.
>
> What do you think about it?

Yes, simply exposing the normal time64 syscalls through vdso
should be fine. I think this currently works on everything except
rv32 and sparc32, probably because neither of them have actual
users that are able to test.

       Arnd


  reply	other threads:[~2024-12-18 16:36 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-16 14:09 [PATCH 00/17] vDSO: Introduce generic data storage Thomas Weißschuh
2024-12-16 14:09 ` [PATCH 01/17] parisc: Remove unused symbol vdso_data Thomas Weißschuh
2024-12-16 14:09 ` [PATCH 02/17] vdso: Introduce vdso/align.h Thomas Weißschuh
2024-12-16 14:09 ` [PATCH 03/17] vdso: Add generic time data storage Thomas Weißschuh
2024-12-18  7:32   ` Christophe Leroy
2024-12-18 10:25     ` Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 04/17] vdso: Add generic random " Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 05/17] vdso: Add generic architecture-specific " Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 06/17] arm64: vdso: Switch to generic storage implementation Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 07/17] riscv: " Thomas Weißschuh
2024-12-18 15:08   ` Conor Dooley
2024-12-18 15:46     ` Thomas Weißschuh
2024-12-18 16:35       ` Arnd Bergmann [this message]
2024-12-19  6:30         ` Thomas Weißschuh
2024-12-19  7:03           ` Arnd Bergmann
2024-12-16 14:10 ` [PATCH 08/17] LoongArch: vDSO: " Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 09/17] arm: vdso: " Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 10/17] s390/vdso: " Thomas Weißschuh
2025-01-09 11:55   ` Heiko Carstens
2024-12-16 14:10 ` [PATCH 11/17] MIPS: vdso: " Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 12/17] powerpc/vdso: " Thomas Weißschuh
2024-12-18  7:20   ` Christophe Leroy
2024-12-18 10:16     ` Thomas Weißschuh
2024-12-18 10:20     ` Christophe Leroy
2024-12-16 14:10 ` [PATCH 13/17] x86/vdso: " Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 14/17] x86/vdso/vdso2c: Remove page handling Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 15/17] vdso: Remove remnants of architecture-specific random state storage Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 16/17] vdso: Remove remnants of architecture-specific time storage Thomas Weißschuh
2024-12-16 14:10 ` [PATCH 17/17] vdso: Remove kconfig symbol GENERIC_VDSO_DATA_STORE Thomas Weißschuh

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=137c0594-e178-4c91-bc8b-5f99b3ddb2f0@app.fastmail.com \
    --to=arnd@arndb.de \
    --cc=James.Bottomley@hansenpartnership.com \
    --cc=Jason@zx2c4.com \
    --cc=agordeev@linux.ibm.com \
    --cc=akpm@linux-foundation.org \
    --cc=anna-maria@linutronix.de \
    --cc=aou@eecs.berkeley.edu \
    --cc=borntraeger@linux.ibm.com \
    --cc=bp@alien8.de \
    --cc=catalin.marinas@arm.com \
    --cc=chenhuacai@kernel.org \
    --cc=christophe.leroy@csgroup.eu \
    --cc=conor@kernel.org \
    --cc=dave.hansen@linux.intel.com \
    --cc=deller@gmx.de \
    --cc=frederic@kernel.org \
    --cc=gor@linux.ibm.com \
    --cc=hca@linux.ibm.com \
    --cc=hpa@zytor.com \
    --cc=kernel@xen0n.name \
    --cc=linux-arch@vger.kernel.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mips@vger.kernel.org \
    --cc=linux-parisc@vger.kernel.org \
    --cc=linux-riscv@lists.infradead.org \
    --cc=linux-s390@vger.kernel.org \
    --cc=linux@armlinux.org.uk \
    --cc=linuxppc-dev@lists.ozlabs.org \
    --cc=loongarch@lists.linux.dev \
    --cc=luto@kernel.org \
    --cc=maddy@linux.ibm.com \
    --cc=mingo@redhat.com \
    --cc=mpe@ellerman.id.au \
    --cc=namcao@linutronix.de \
    --cc=naveen@kernel.org \
    --cc=npiggin@gmail.com \
    --cc=palmer@dabbelt.com \
    --cc=paul.walmsley@sifive.com \
    --cc=svens@linux.ibm.com \
    --cc=tglx@linutronix.de \
    --cc=thomas.weissschuh@linutronix.de \
    --cc=tsbogend@alpha.franken.de \
    --cc=tytso@mit.edu \
    --cc=vincenzo.frascino@arm.com \
    --cc=will@kernel.org \
    --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;
as well as URLs for NNTP newsgroup(s).