提交 51d36de8 编写于 作者: L Li Lingfeng 提交者: Jialin Zhang

fix kabi broken due to import of 5.15-stable io_uring

Offering: HULK
hulk inclusion
category: bugfix
bugzilla: https://gitee.com/src-openeuler/kernel/issues/I6BTWC

-------------------

Commit 5125c6de8709("[Backport] io_uring: import 5.15-stable io_uring")
changes some structs, so we need to fix kabi broken problem.
Signed-off-by: NLi Lingfeng <lilingfeng3@huawei.com>
Reviewed-by: NZhang Yi <yi.zhang@huawei.com>
Reviewed-by: NWang Weiyang <wangweiyang2@huawei.com>
Signed-off-by: NJialin Zhang <zhangjialin11@huawei.com>
上级 3f5e2ba9
...@@ -5,6 +5,37 @@ ...@@ -5,6 +5,37 @@
#include <linux/sched.h> #include <linux/sched.h>
#include <linux/xarray.h> #include <linux/xarray.h>
struct io_identity {
struct files_struct *files;
struct mm_struct *mm;
#ifdef CONFIG_BLK_CGROUP
struct cgroup_subsys_state *blkcg_css;
#endif
const struct cred *creds;
struct nsproxy *nsproxy;
struct fs_struct *fs;
unsigned long fsize;
#ifdef CONFIG_AUDIT
kuid_t loginuid;
unsigned int sessionid;
#endif
refcount_t count;
};
#ifdef __GENKSYMS__
struct io_uring_task {
/* submission side */
struct xarray xa;
struct wait_queue_head wait;
struct file *last;
struct percpu_counter inflight;
struct io_identity __identity;
struct io_identity *identity;
atomic_t in_idle;
bool sqpoll;
};
#endif
#if defined(CONFIG_IO_URING) #if defined(CONFIG_IO_URING)
struct sock *io_uring_get_socket(struct file *file); struct sock *io_uring_get_socket(struct file *file);
void __io_uring_cancel(bool cancel_all); void __io_uring_cancel(bool cancel_all);
......
...@@ -925,9 +925,6 @@ struct task_struct { ...@@ -925,9 +925,6 @@ struct task_struct {
/* CLONE_CHILD_CLEARTID: */ /* CLONE_CHILD_CLEARTID: */
int __user *clear_child_tid; int __user *clear_child_tid;
/* PF_IO_WORKER */
void *pf_io_worker;
u64 utime; u64 utime;
u64 stime; u64 stime;
#ifdef CONFIG_ARCH_HAS_SCALED_CPUTIME #ifdef CONFIG_ARCH_HAS_SCALED_CPUTIME
...@@ -1424,7 +1421,7 @@ struct task_struct { ...@@ -1424,7 +1421,7 @@ struct task_struct {
#else #else
KABI_RESERVE(6) KABI_RESERVE(6)
#endif #endif
KABI_RESERVE(7) KABI_USE(7, void *pf_io_worker)
KABI_RESERVE(8) KABI_RESERVE(8)
KABI_RESERVE(9) KABI_RESERVE(9)
KABI_RESERVE(10) KABI_RESERVE(10)
......
...@@ -341,7 +341,7 @@ asmlinkage long sys_io_uring_setup(u32 entries, ...@@ -341,7 +341,7 @@ asmlinkage long sys_io_uring_setup(u32 entries,
struct io_uring_params __user *p); struct io_uring_params __user *p);
asmlinkage long sys_io_uring_enter(unsigned int fd, u32 to_submit, asmlinkage long sys_io_uring_enter(unsigned int fd, u32 to_submit,
u32 min_complete, u32 flags, u32 min_complete, u32 flags,
const void __user *argp, size_t argsz); const sigset_t __user *sig, size_t sigsz);
asmlinkage long sys_io_uring_register(unsigned int fd, unsigned int op, asmlinkage long sys_io_uring_register(unsigned int fd, unsigned int op,
void __user *arg, unsigned int nr_args); void __user *arg, unsigned int nr_args);
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
#define INTERNAL_IO_WQ_H #define INTERNAL_IO_WQ_H
#include <linux/refcount.h> #include <linux/refcount.h>
#include <linux/io_uring.h>
struct io_wq; struct io_wq;
enum { enum {
......
...@@ -461,6 +461,7 @@ struct io_ring_ctx { ...@@ -461,6 +461,7 @@ struct io_ring_ctx {
}; };
}; };
#ifndef __GENKSYMS__
struct io_uring_task { struct io_uring_task {
/* submission side */ /* submission side */
int cached_refs; int cached_refs;
...@@ -477,6 +478,7 @@ struct io_uring_task { ...@@ -477,6 +478,7 @@ struct io_uring_task {
struct callback_head task_work; struct callback_head task_work;
bool task_running; bool task_running;
}; };
#endif
/* /*
* First field must be the file pointer in all the * First field must be the file pointer in all the
...@@ -9850,13 +9852,15 @@ static int io_get_ext_arg(unsigned flags, const void __user *argp, size_t *argsz ...@@ -9850,13 +9852,15 @@ static int io_get_ext_arg(unsigned flags, const void __user *argp, size_t *argsz
} }
SYSCALL_DEFINE6(io_uring_enter, unsigned int, fd, u32, to_submit, SYSCALL_DEFINE6(io_uring_enter, unsigned int, fd, u32, to_submit,
u32, min_complete, u32, flags, const void __user *, argp, u32, min_complete, u32, flags, const sigset_t __user *, sig,
size_t, argsz) size_t, sigsz)
{ {
struct io_ring_ctx *ctx; struct io_ring_ctx *ctx;
int submitted = 0; int submitted = 0;
struct fd f; struct fd f;
long ret; long ret;
const void __user *argp = (const void __user *) sig;
size_t argsz = sigsz;
io_run_task_work(); io_run_task_work();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册