mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
To: "André Almeida" <andrealmeid@igalia.com>
Cc: Thomas Gleixner <tglx@linutronix.de>,
	Ingo Molnar <mingo@redhat.com>,
	Peter Zijlstra <peterz@infradead.org>,
	Darren Hart <dvhart@infradead.org>,
	Davidlohr Bueso <dave@stgolabs.net>,
	Shuah Khan <shuah@kernel.org>, Arnd Bergmann <arnd@arndb.de>,
	Waiman Long <longman@redhat.com>,
	linux-kernel@vger.kernel.org, linux-kselftest@vger.kernel.org,
	linux-api@vger.kernel.org, kernel-dev@igalia.com
Subject: Re: [PATCH RESEND v4 0/7] futex: Create set_robust_list2
Date: Wed, 18 Jun 2025 18:56:41 +0200	[thread overview]
Message-ID: <20250618165641.bKu1_p0P@linutronix.de> (raw)
In-Reply-To: <fd2b5bb2-590a-47ee-8e56-965a1d09b2fc@igalia.com>

On 2025-06-18 13:39:46 [-0300], André Almeida wrote:
> 
> Ops, I forgot to address them. I will do it for v5.
> 
> > - You say 64bit x86-64 does not have the problem due the compat syscall.
> >    Arm64 has this problem. New arm64 do not provide arm32 facility. You
> >    introduce the syscall here. Why not introduce the compat syscall
> >    instead? I'm sorry if this has been answered somewhere below but this
> >    was one question I had while I initially skimmed over the patches.
> > 
> 
> The main target for this new syscall is Arm64, that can't handle 32 pointers
> in the current syscall, so this new interface allows the robust list
> mechanism to know if it needs to do 64 or 32 bit pointer arithmetic
> operations to walk in the list.
> 
> Introducing a compat syscall won't fix this, giving that it only works in
> x86-64. We need an entry point for Arm64 that can handle 32 bit pointers.

I would need to dig into details to figure out why it won't work for
arm64 and works only for x86-64. 
There is the set_robust_list syscall as compat which sets
::compat_robust_list. And non-compat sets ::robust_list. The 32bit
application on 64bit kernel should set ::compat_robust_list which what
your syscall provides.
That is why I don't understand the need for it so far. Maybe I am
missing a detail.
We have other architectures with 64 bit kernel and a possible 32bit
userland such as mips, s390 or powerpc which would have the same issue
then. Or there is something special about arm64 in this case which makes
it unique.

Sebastian

  reply	other threads:[~2025-06-18 16:56 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-06-17 18:34 André Almeida
2025-06-17 18:34 ` [PATCH RESEND v4 1/7] selftests/futex: Add ASSERT_ macros André Almeida
2025-06-17 18:34 ` [PATCH RESEND v4 2/7] selftests/futex: Create test for robust list André Almeida
2025-06-17 18:34 ` [PATCH RESEND v4 3/7] futex: Use explicit sizes for compat_exit_robust_list André Almeida
2025-06-17 18:34 ` [PATCH RESEND v4 4/7] futex: Create set_robust_list2 André Almeida
2025-06-17 18:34 ` [PATCH RESEND v4 5/7] futex: Wire up set_robust_list2 syscall André Almeida
2025-06-17 18:34 ` [PATCH RESEND v4 6/7] futex: Remove the limit of elements for sys_set_robust_list2 lists André Almeida
2025-06-17 18:34 ` [PATCH RESEND v4 7/7] selftests: futex: Expand robust list test for the new interface André Almeida
2025-06-18  7:08 ` [PATCH RESEND v4 0/7] futex: Create set_robust_list2 Sebastian Andrzej Siewior
2025-06-18 16:39   ` André Almeida
2025-06-18 16:56     ` Sebastian Andrzej Siewior [this message]
2025-06-18 17:03       ` Arnd Bergmann

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=20250618165641.bKu1_p0P@linutronix.de \
    --to=bigeasy@linutronix.de \
    --cc=andrealmeid@igalia.com \
    --cc=arnd@arndb.de \
    --cc=dave@stgolabs.net \
    --cc=dvhart@infradead.org \
    --cc=kernel-dev@igalia.com \
    --cc=linux-api@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-kselftest@vger.kernel.org \
    --cc=longman@redhat.com \
    --cc=mingo@redhat.com \
    --cc=peterz@infradead.org \
    --cc=shuah@kernel.org \
    --cc=tglx@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

all inboxes | Powered by JetHome®