From: Jens Remus <jremus@linux.ibm.com>
To: Ilya Leoshkevich <iii@linux.ibm.com>,
linux-s390@vger.kernel.org, linux-kernel@vger.kernel.org
Cc: Heiko Carstens <hca@linux.ibm.com>,
Vasily Gorbik <gor@linux.ibm.com>,
Alexander Gordeev <agordeev@linux.ibm.com>,
Sven Schnelle <svens@linux.ibm.com>
Subject: Re: [PATCH 2/2] s390/vdso: Use symbolic constants for the PHDR permission flags
Date: Tue, 7 Jul 2026 09:32:50 +0200 [thread overview]
Message-ID: <ed9c694b-642b-4210-870d-a85d1c53b2fc@linux.ibm.com> (raw)
In-Reply-To: <d3ffd684-73e8-40e8-ae18-f847a6d0691a@linux.ibm.com>
On 7/6/2026 7:06 PM, Ilya Leoshkevich wrote:
> On 7/6/26 17:19, Jens Remus wrote:
>> While at it explicitly specify GNU_EH_FRAME PHDR to be read-only.
>>
>> Inspired by x86 commit 8717b02b8c03 ("x86/entry/vdso: Include
>> GNU_PROPERTY and GNU_STACK PHDRs").
>>
>> Signed-off-by: Jens Remus <jremus@linux.ibm.com>
>> ---
>> arch/s390/kernel/vdso/vdso.lds.S | 12 ++++++++----
>> 1 file changed, 8 insertions(+), 4 deletions(-)
>>
>> diff --git a/arch/s390/kernel/vdso/vdso.lds.S b/arch/s390/kernel/vdso/vdso.lds.S
>> index 7bec4de0e8e0..35ea7ede06c0 100644
>> --- a/arch/s390/kernel/vdso/vdso.lds.S
>> +++ b/arch/s390/kernel/vdso/vdso.lds.S
>> @@ -82,12 +82,16 @@ SECTIONS
>> * We must supply the ELF program headers explicitly to get just one
>> * PT_LOAD segment, and set the flags explicitly to make segments read-only.
>> */
>> +#define PF_R FLAGS(4)
>> +#define PF_RW FLAGS(6)
>
> PF_RW seems to be unused
> Intel uses it for gnu_stack, which we don't seem to have.
Good catch, that slipped through.
I wondered whether we should also add a GNU_STACK PHDR in a separate
patch - similar to x86 and for the same reasons, as some of the .o files
linked into vdso.so do have a .note.GNU-stack.
> Anyway:
>
> Reviewed-by: Ilya Leoshkevich <iii@linux.ibm.com>
Thanks!
Regards,
Jens
--
Jens Remus
Linux on Z Development (D3303)
jremus@de.ibm.com / jremus@linux.ibm.com
IBM Deutschland Research & Development GmbH; Vorsitzender des Aufsichtsrats: Wolfgang Wendt; Geschäftsführung: David Faller; Sitz der Gesellschaft: Ehningen; Registergericht: Amtsgericht Stuttgart, HRB 243294
IBM Data Privacy Statement: https://www.ibm.com/privacy/
prev parent reply other threads:[~2026-07-07 7:32 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-07-06 15:19 [PATCH 0/2] s390/vdso: Fix GNU_EH_FRAME PHDR Jens Remus
2026-07-06 15:19 ` [PATCH 1/2] s390/vdso: Pass --eh-frame-hdr to the linker Jens Remus
2026-07-06 15:22 ` Jens Remus
2026-07-06 17:26 ` Ilya Leoshkevich
2026-07-06 15:19 ` [PATCH 2/2] s390/vdso: Use symbolic constants for the PHDR permission flags Jens Remus
2026-07-06 17:06 ` Ilya Leoshkevich
2026-07-07 7:32 ` Jens Remus [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=ed9c694b-642b-4210-870d-a85d1c53b2fc@linux.ibm.com \
--to=jremus@linux.ibm.com \
--cc=agordeev@linux.ibm.com \
--cc=gor@linux.ibm.com \
--cc=hca@linux.ibm.com \
--cc=iii@linux.ibm.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=svens@linux.ibm.com \
/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