selftests/rseq: Change type of rseq_offset to ptrdiff_t

commit 889c5d60fbcf332c8b6ab7054d45f2768914a375 upstream.

Just before the 2.35 release of glibc, the __rseq_offset userspace ABI
was changed from int to ptrdiff_t.

Adapt to this change in the kernel selftests.

Signed-off-by: Mathieu Desnoyers <mathieu.desnoyers@efficios.com>
Signed-off-by: Peter Zijlstra (Intel) <peterz@infradead.org>
Link: https://sourceware.org/pipermail/libc-alpha/2022-February/136024.html
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Mathieu Desnoyers
2022-02-03 10:05:32 -05:00
committed by Greg Kroah-Hartman
parent 7e617278bf
commit d341e5a754
3 changed files with 12 additions and 10 deletions

View File

@@ -27,16 +27,17 @@
#include <signal.h>
#include <limits.h>
#include <dlfcn.h>
#include <stddef.h>
#include "../kselftest.h"
#include "rseq.h"
static const int *libc_rseq_offset_p;
static const ptrdiff_t *libc_rseq_offset_p;
static const unsigned int *libc_rseq_size_p;
static const unsigned int *libc_rseq_flags_p;
/* Offset from the thread pointer to the rseq area. */
int rseq_offset;
ptrdiff_t rseq_offset;
/* Size of the registered rseq area. 0 if the registration was
unsuccessful. */