diff options
-rw-r--r-- | meta-oe/recipes-support/liburing/liburing/0001-examples-ucontext-cp.c-Do-not-use-SIGSTKSZ.patch | 37 | ||||
-rw-r--r-- | meta-oe/recipes-support/liburing/liburing/0001-tests-fix-portability-issue-when-using-__NR_mmap-sys.patch | 53 | ||||
-rw-r--r-- | meta-oe/recipes-support/liburing/liburing_2.1.bb (renamed from meta-oe/recipes-support/liburing/liburing_2.0.bb) | 7 |
3 files changed, 2 insertions, 95 deletions
diff --git a/meta-oe/recipes-support/liburing/liburing/0001-examples-ucontext-cp.c-Do-not-use-SIGSTKSZ.patch b/meta-oe/recipes-support/liburing/liburing/0001-examples-ucontext-cp.c-Do-not-use-SIGSTKSZ.patch deleted file mode 100644 index a2ba66c3ab..0000000000 --- a/meta-oe/recipes-support/liburing/liburing/0001-examples-ucontext-cp.c-Do-not-use-SIGSTKSZ.patch +++ /dev/null @@ -1,37 +0,0 @@ -From a30d62dfb9ea30af58ef331fae1e6f727d0558c0 Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Tue, 4 May 2021 10:32:08 -0700 -Subject: [PATCH] examples/ucontext-cp.c: Do not use SIGSTKSZ - -glibc 2.34 has removed SIGSTKSZ therefore we replace it - -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - examples/ucontext-cp.c | 6 +----- - 1 file changed, 1 insertion(+), 5 deletions(-) - ---- a/examples/ucontext-cp.c -+++ b/examples/ucontext-cp.c -@@ -3,6 +3,7 @@ - * gcc -Wall -O2 -D_GNU_SOURCE -o ucontext-cp ucontext-cp.c -luring - */ - #define _POSIX_C_SOURCE 199309L -+#include <stddef.h> - #include <stdio.h> - #include <fcntl.h> - #include <string.h> -@@ -22,13 +23,9 @@ - #define QD 64 - #define BS 1024 - --#ifndef SIGSTKSZ --#define SIGSTKSZ 8192 --#endif -- - typedef struct { - struct io_uring *ring; -- unsigned char stack_buf[SIGSTKSZ]; -+ max_align_t stack_buf[(8 * 1024 + sizeof (max_align_t) - 1) / sizeof (max_align_t)]; - ucontext_t ctx_main, ctx_fnew; - } async_context; - diff --git a/meta-oe/recipes-support/liburing/liburing/0001-tests-fix-portability-issue-when-using-__NR_mmap-sys.patch b/meta-oe/recipes-support/liburing/liburing/0001-tests-fix-portability-issue-when-using-__NR_mmap-sys.patch deleted file mode 100644 index f2f03c18b4..0000000000 --- a/meta-oe/recipes-support/liburing/liburing/0001-tests-fix-portability-issue-when-using-__NR_mmap-sys.patch +++ /dev/null @@ -1,53 +0,0 @@ -From 2d3940163e14d183fddc4d8b24cc1d3865bba0b3 Mon Sep 17 00:00:00 2001 -From: Khem Raj <raj.khem@gmail.com> -Date: Wed, 5 May 2021 09:36:36 -0700 -Subject: [PATCH] tests: fix portability issue when using __NR_mmap syscall - -On some architectures e.g. ARM and RISCV32, __NR_mmap does not exist and -libc will then use NR_mmap2 to implement mmap() API, therefore use -system C library mmap() API instead of calling the syscall directly - -Upstream-Status: Partial Backport [https://github.com/axboe/liburing/commit/808b6c72ab753bda0c300b5683cfd31750d1d49b] -Signed-off-by: Khem Raj <raj.khem@gmail.com> ---- - test/double-poll-crash.c | 6 +++--- - test/sqpoll-disable-exit.c | 6 +++--- - 2 files changed, 6 insertions(+), 6 deletions(-) - -diff --git a/test/double-poll-crash.c b/test/double-poll-crash.c -index 1a219c7..6e08285 100644 ---- a/test/double-poll-crash.c -+++ b/test/double-poll-crash.c -@@ -150,9 +150,9 @@ int main(int argc, char *argv[]) - if (argc > 1) - return 0; - -- syscall(__NR_mmap, 0x1ffff000ul, 0x1000ul, 0ul, 0x32ul, -1, 0ul); -- syscall(__NR_mmap, 0x20000000ul, 0x1000000ul, 7ul, 0x32ul, -1, 0ul); -- syscall(__NR_mmap, 0x21000000ul, 0x1000ul, 0ul, 0x32ul, -1, 0ul); -+ mmap((void *) 0x1ffff000, (size_t) 0x1000, PROT_NONE, MAP_FIXED | MAP_ANONYMOUS, -1, 0); -+ mmap((void *) 0x20000000, (size_t) 0x1000000, PROT_READ | PROT_WRITE | PROT_EXEC, MAP_FIXED | MAP_ANONYMOUS, -1, 0); -+ mmap((void *) 0x21000000, (size_t) 0x1000, PROT_NONE, MAP_FIXED | MAP_ANONYMOUS, -1, 0); - intptr_t res = 0; - *(uint32_t*)0x20000484 = 0; - *(uint32_t*)0x20000488 = 0; -diff --git a/test/sqpoll-disable-exit.c b/test/sqpoll-disable-exit.c -index d4e17f8..a0d00cc 100644 ---- a/test/sqpoll-disable-exit.c -+++ b/test/sqpoll-disable-exit.c -@@ -223,9 +223,9 @@ void execute_one(void) - } - int main(void) - { -- syscall(__NR_mmap, 0x1ffff000ul, 0x1000ul, 0ul, 0x32ul, -1, 0ul); -- syscall(__NR_mmap, 0x20000000ul, 0x1000000ul, 7ul, 0x32ul, -1, 0ul); -- syscall(__NR_mmap, 0x21000000ul, 0x1000ul, 0ul, 0x32ul, -1, 0ul); -+ mmap((void *) 0x1ffff000, (size_t) 0x1000, PROT_NONE, MAP_FIXED | MAP_ANONYMOUS, -1, 0); -+ mmap((void *) 0x20000000, (size_t) 0x1000000, PROT_READ | PROT_WRITE | PROT_EXEC, MAP_FIXED | MAP_ANONYMOUS, -1, 0); -+ mmap((void *) 0x21000000, (size_t) 0x1000, PROT_NONE, MAP_FIXED | MAP_ANONYMOUS, -1, 0); - loop(); - return 0; - } --- -2.31.1 - diff --git a/meta-oe/recipes-support/liburing/liburing_2.0.bb b/meta-oe/recipes-support/liburing/liburing_2.1.bb index 7a903e5d4a..b4f0b11f4e 100644 --- a/meta-oe/recipes-support/liburing/liburing_2.0.bb +++ b/meta-oe/recipes-support/liburing/liburing_2.1.bb @@ -9,14 +9,11 @@ SECTION = "libs" LICENSE = "LGPLv2.1 | MIT" LIC_FILES_CHKSUM = "file://README;beginline=41;endline=44;md5=d51b5805e2a675685e6a66ca50904cf9" -SRC_URI = "git://github.com/axboe/liburing.git;branch=master;protocol=https \ - file://0001-examples-ucontext-cp.c-Do-not-use-SIGSTKSZ.patch \ - file://0001-tests-fix-portability-issue-when-using-__NR_mmap-sys.patch \ - " +SRC_URI = "git://github.com/axboe/liburing.git;branch=master;protocol=https" SRC_URI:append:libc-musl:riscv64 = " file://0001-do-not-build-examples.patch " SRC_URI:append:libc-musl:riscv32 = " file://0001-do-not-build-examples.patch " +SRCREV = "41a61c97c2e3df4475c93fdf5026d575ce3f1377" -SRCREV = "b013dfd5a5f65116373d5e0f0bdfb73db9d8816e" S = "${WORKDIR}/git" DEPENDS:append:libc-musl = " libucontext" |