summaryrefslogtreecommitdiffstats
path: root/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch
diff options
context:
space:
mode:
Diffstat (limited to 'poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch')
-rw-r--r--poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch26
1 files changed, 13 insertions, 13 deletions
diff --git a/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch b/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch
index e325ce4e4..428ac3004 100644
--- a/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch
+++ b/poky/meta/recipes-extended/ltp/ltp/0008-Check-if-__GLIBC_PREREQ-is-defined-before-using-it.patch
@@ -11,9 +11,9 @@ Signed-off-by: Khem Raj <raj.khem@gmail.com>
Upstream-Status: Pending
---
testcases/kernel/syscalls/accept4/accept4_01.c | 9 ++++-
- testcases/kernel/syscalls/getcpu/getcpu01.c | 40 +++++++++++++++++++++-
- .../sched_getaffinity/sched_getaffinity01.c | 26 ++++++++++++++
- 3 files changed, 73 insertions(+), 2 deletions(-)
+ testcases/kernel/syscalls/getcpu/getcpu01.c | 39 +++++++++++++++++++++-
+ .../sched_getaffinity/sched_getaffinity01.c | 26 +++++++++++++++
+ 3 files changed, 72 insertions(+), 2 deletions(-)
diff --git a/testcases/kernel/syscalls/accept4/accept4_01.c b/testcases/kernel/syscalls/accept4/accept4_01.c
index 6072bfa..2b090cb 100644
@@ -102,7 +102,7 @@ index c927512..921b107 100644
*cpu_id = sched_getcpu();
#endif
return 0;
-@@ -191,15 +204,20 @@ unsigned int set_cpu_affinity(void)
+@@ -191,15 +203,20 @@ unsigned int set_cpu_affinity(void)
cpu_set_t *set;
size_t size;
int nrcpus = 1024;
@@ -123,7 +123,7 @@ index c927512..921b107 100644
#if __GLIBC_PREREQ(2, 7)
size = CPU_ALLOC_SIZE(nrcpus);
CPU_ZERO_S(size, set);
-@@ -207,8 +225,13 @@ realloc:
+@@ -207,8 +224,13 @@ realloc:
size = sizeof(cpu_set_t);
CPU_ZERO(set);
#endif
@@ -137,7 +137,7 @@ index c927512..921b107 100644
#if __GLIBC_PREREQ(2, 7)
if (errno == EINVAL && nrcpus < (1024 << 8)) {
nrcpus = nrcpus << 2;
-@@ -220,10 +243,17 @@ realloc:
+@@ -220,10 +242,17 @@ realloc:
"NR_CPUS of the kernel is more than 1024, so we'd better use a newer glibc(>= 2.7)");
else
#endif
@@ -155,7 +155,7 @@ index c927512..921b107 100644
#if __GLIBC_PREREQ(2, 7)
CPU_ZERO_S(size, set);
CPU_SET_S(cpu_max, size, set);
-@@ -231,6 +261,10 @@ realloc:
+@@ -231,6 +260,10 @@ realloc:
CPU_ZERO(set);
CPU_SET(cpu_max, set);
#endif
@@ -166,7 +166,7 @@ index c927512..921b107 100644
if (sched_setaffinity(0, size, set) < 0) {
CPU_FREE(set);
tst_brkm(TFAIL, NULL, "sched_setaffinity:errno:%d", errno);
-@@ -247,11 +281,15 @@ unsigned int max_cpuid(size_t size, cpu_set_t * set)
+@@ -247,11 +280,15 @@ unsigned int max_cpuid(size_t size, cpu_set_t * set)
{
unsigned int index, max = 0;
for (index = 0; index < size * BITS_PER_BYTE; index++)
@@ -186,7 +186,7 @@ diff --git a/testcases/kernel/syscalls/sched_getaffinity/sched_getaffinity01.c b
index 9d6a81a..4ed13b2 100644
--- a/testcases/kernel/syscalls/sched_getaffinity/sched_getaffinity01.c
+++ b/testcases/kernel/syscalls/sched_getaffinity/sched_getaffinity01.c
-@@ -66,9 +66,11 @@ do { \
+@@ -67,9 +67,11 @@ do { \
tst_resm((TEST_RETURN == -1 ? TPASS : TFAIL) | TTERRNO, #t); \
} while (0)
@@ -198,7 +198,7 @@ index 9d6a81a..4ed13b2 100644
int main(int ac, char **av)
{
-@@ -95,14 +97,19 @@ static void do_test(void)
+@@ -96,14 +98,19 @@ static void do_test(void)
pid_t unused_pid;
unsigned len;
@@ -218,7 +218,7 @@ index 9d6a81a..4ed13b2 100644
#if __GLIBC_PREREQ(2, 7)
len = CPU_ALLOC_SIZE(nrcpus);
CPU_ZERO_S(len, mask);
-@@ -110,10 +117,15 @@ realloc:
+@@ -111,10 +118,15 @@ realloc:
len = sizeof(cpu_set_t);
CPU_ZERO(mask);
#endif
@@ -234,7 +234,7 @@ index 9d6a81a..4ed13b2 100644
#if __GLIBC_PREREQ(2, 7)
if (errno == EINVAL && nrcpus < (1024 << 8)) {
nrcpus = nrcpus << 2;
-@@ -125,17 +137,27 @@ realloc:
+@@ -126,17 +138,27 @@ realloc:
"newer glibc(>= 2.7)");
else
#endif
@@ -262,7 +262,7 @@ index 9d6a81a..4ed13b2 100644
if (TEST_RETURN != -1)
tst_resm(TPASS, "sched_getaffinity() succeed, "
"this process %d is running "
-@@ -143,11 +165,15 @@ realloc:
+@@ -144,11 +166,15 @@ realloc:
}
}
OpenPOWER on IntegriCloud