Skip to content

Commit 53e043b

Browse files
metze-sambaaxboe
authored andcommitted
io_uring: remove structures from include/linux/io_uring.h
Link: https://lore.kernel.org/r/8c1d14f3748105f4caeda01716d47af2fa41d11c.1615809009.git.metze@samba.org Signed-off-by: Stefan Metzmacher <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
1 parent 76cd979 commit 53e043b

File tree

3 files changed

+25
-26
lines changed

3 files changed

+25
-26
lines changed

fs/io-wq.h

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,6 @@
22
#define INTERNAL_IO_WQ_H
33

44
#include <linux/refcount.h>
5-
#include <linux/io_uring.h>
65

76
struct io_wq;
87

@@ -21,6 +20,15 @@ enum io_wq_cancel {
2120
IO_WQ_CANCEL_NOTFOUND, /* work not found */
2221
};
2322

23+
struct io_wq_work_node {
24+
struct io_wq_work_node *next;
25+
};
26+
27+
struct io_wq_work_list {
28+
struct io_wq_work_node *first;
29+
struct io_wq_work_node *last;
30+
};
31+
2432
static inline void wq_list_add_after(struct io_wq_work_node *node,
2533
struct io_wq_work_node *pos,
2634
struct io_wq_work_list *list)

fs/io_uring.c

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -456,6 +456,22 @@ struct io_ring_ctx {
456456
struct list_head tctx_list;
457457
};
458458

459+
struct io_uring_task {
460+
/* submission side */
461+
struct xarray xa;
462+
struct wait_queue_head wait;
463+
void *last;
464+
void *io_wq;
465+
struct percpu_counter inflight;
466+
atomic_t in_idle;
467+
bool sqpoll;
468+
469+
spinlock_t task_lock;
470+
struct io_wq_work_list task_list;
471+
unsigned long task_state;
472+
struct callback_head task_work;
473+
};
474+
459475
/*
460476
* First field must be the file pointer in all the
461477
* iocb unions! See also 'struct kiocb' in <linux/fs.h>

include/linux/io_uring.h

Lines changed: 0 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -5,31 +5,6 @@
55
#include <linux/sched.h>
66
#include <linux/xarray.h>
77

8-
struct io_wq_work_node {
9-
struct io_wq_work_node *next;
10-
};
11-
12-
struct io_wq_work_list {
13-
struct io_wq_work_node *first;
14-
struct io_wq_work_node *last;
15-
};
16-
17-
struct io_uring_task {
18-
/* submission side */
19-
struct xarray xa;
20-
struct wait_queue_head wait;
21-
void *last;
22-
void *io_wq;
23-
struct percpu_counter inflight;
24-
atomic_t in_idle;
25-
bool sqpoll;
26-
27-
spinlock_t task_lock;
28-
struct io_wq_work_list task_list;
29-
unsigned long task_state;
30-
struct callback_head task_work;
31-
};
32-
338
#if defined(CONFIG_IO_URING)
349
struct sock *io_uring_get_socket(struct file *file);
3510
void __io_uring_task_cancel(void);

0 commit comments

Comments
 (0)