ltp: upgrade 20240930 -> 20250130

* Drop 0001-sched_attr-Do-not-define-for-glibc-2.41.patch as it has been
  merged upstream.
* Skip statmount02 case which does not work on musl.

(From OE-Core rev: 5d72185e65aa0d9012913d9d095caceada7799d7)

Signed-off-by: Yi Zhao <yi.zhao@windriver.com>
Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
This commit is contained in:
Yi Zhao
2025-02-27 21:20:34 +08:00
committed by Richard Purdie
parent 61b88919f7
commit 9ac081be6f
2 changed files with 5 additions and 45 deletions

View File

@@ -1,42 +0,0 @@
From 38ac9ed7a4f7e2dcedb3c13d807ad0575435bab4 Mon Sep 17 00:00:00 2001
From: Khem Raj <raj.khem@gmail.com>
Date: Wed, 30 Oct 2024 14:37:12 -0700
Subject: [PATCH] sched_attr: Do not define for glibc >= 2.41
glibc 2.41+ has added [1] definitions for sched_setattr and sched_getattr functions
and struct sched_attr. Therefore, it needs to be checked for here as well before
defining sched_attr
Define sched_attr conditionally on SCHED_ATTR_SIZE_VER0
Fixes builds with glibc/trunk
[1] https://sourceware.org/git/?p=glibc.git;a=commitdiff;h=21571ca0d70302909cf72707b2a7736cf12190a0;hp=298bc488fdc047da37482f4003023cb9adef78f8
Upstream-Status: Submitted [https://lists.linux.it/pipermail/ltp/2024-October/040678.html]
Signed-off-by: Khem Raj <raj.khem@gmail.com>
---
include/lapi/sched.h | 3 +++
1 file changed, 3 insertions(+)
diff --git a/include/lapi/sched.h b/include/lapi/sched.h
index 26fdb628d..e1c7ff011 100644
--- a/include/lapi/sched.h
+++ b/include/lapi/sched.h
@@ -15,6 +15,8 @@
#include "lapi/syscalls.h"
#include "lapi/sched.h"
+/* sched_attr is not defined in glibc < 2.41 */
+#ifndef SCHED_ATTR_SIZE_VER0
struct sched_attr {
uint32_t size;
@@ -44,6 +46,7 @@ static inline int sched_getattr(pid_t pid, struct sched_attr *attr,
{
return syscall(__NR_sched_getattr, pid, attr, size, flags);
}
+#endif
#ifndef HAVE_CLONE3
struct clone_args {

View File

@@ -24,12 +24,11 @@ TUNE_CCARGS:remove:x86-64 = "-mfpmath=sse"
CFLAGS:append:powerpc64 = " -D__SANE_USERSPACE_TYPES__"
CFLAGS:append:mipsarchn64 = " -D__SANE_USERSPACE_TYPES__"
SRCREV = "60f81419c43f94ec182827ef0b9eb5baeb303419"
SRCREV = "a7c31dff7edc089a32e990765e12952cc4d7666a"
SRC_URI = "git://github.com/linux-test-project/ltp.git;branch=master;protocol=https \
file://0001-Remove-OOM-tests-from-runtest-mm.patch \
file://0001-Add-__clear_cache-declaration-for-clang.patch \
file://0001-sched_attr-Do-not-define-for-glibc-2.41.patch \
"
S = "${WORKDIR}/git"
@@ -121,6 +120,8 @@ FILES:${PN} += "${prefix}/* ${prefix}/runtest/* ${prefix}/scenario_groups/* ${pr
INHIBIT_PACKAGE_STRIP_FILES = "${prefix}/testcases/bin/nm01 ${prefix}/testcases/bin/ldd01"
INSANE_SKIP:${PN} += "already-stripped staticdev"
CACHED_CONFIGUREVARS:libc-musl = "ac_cv_type_struct_mnt_id_req=no ac_cv_type_struct_statmount=no"
remove_broken_musl_sources() {
[ "${TCLIBC}" = "musl" ] || return 0
@@ -134,7 +135,8 @@ remove_broken_musl_sources() {
testcases/kernel/syscalls/getcontext/getcontext01.c \
testcases/kernel/syscalls/rt_tgsigqueueinfo/rt_tgsigqueueinfo01.c \
testcases/kernel/syscalls/timer_create/timer_create01.c \
testcases/kernel/syscalls/timer_create/timer_create03.c
testcases/kernel/syscalls/timer_create/timer_create03.c \
testcases/kernel/syscalls/statmount/statmount02.c
}
do_patch[postfuncs] += "remove_broken_musl_sources"