* [PATCH 1/2] io_uring: remove parameter ctx of io_submit_state_start
@ 2019-12-02 9:14 Jackie Liu
2019-12-02 9:14 ` [PATCH 2/2] io_uring: remove io_wq_current_is_worker Jackie Liu
2019-12-03 3:03 ` [PATCH 1/2] io_uring: remove parameter ctx of io_submit_state_start Jens Axboe
0 siblings, 2 replies; 3+ messages in thread
From: Jackie Liu @ 2019-12-02 9:14 UTC (permalink / raw)
To: axboe; +Cc: io-uring
From: Jackie Liu <[email protected]>
Parameter ctx we have never used, clean it up.
checkpatch.pl said:
WARNING: Prefer 'unsigned int' to bare use of 'unsigned'
Signed-off-by: Jackie Liu <[email protected]>
---
fs/io_uring.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/fs/io_uring.c b/fs/io_uring.c
index 2c2e8c25da01..9c55af1c1f22 100644
--- a/fs/io_uring.c
+++ b/fs/io_uring.c
@@ -3112,7 +3112,7 @@ static void io_submit_state_end(struct io_submit_state *state)
* Start submission side cache.
*/
static void io_submit_state_start(struct io_submit_state *state,
- struct io_ring_ctx *ctx, unsigned max_ios)
+ unsigned int max_ios)
{
blk_start_plug(&state->plug);
state->free_reqs = 0;
@@ -3196,7 +3196,7 @@ static int io_submit_sqes(struct io_ring_ctx *ctx, unsigned int nr,
return -EBUSY;
if (nr > IO_PLUG_THRESHOLD) {
- io_submit_state_start(&state, ctx, nr);
+ io_submit_state_start(&state, nr);
statep = &state;
}
--
2.17.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* [PATCH 2/2] io_uring: remove io_wq_current_is_worker
2019-12-02 9:14 [PATCH 1/2] io_uring: remove parameter ctx of io_submit_state_start Jackie Liu
@ 2019-12-02 9:14 ` Jackie Liu
2019-12-03 3:03 ` [PATCH 1/2] io_uring: remove parameter ctx of io_submit_state_start Jens Axboe
1 sibling, 0 replies; 3+ messages in thread
From: Jackie Liu @ 2019-12-02 9:14 UTC (permalink / raw)
To: axboe; +Cc: io-uring
From: Jackie Liu <[email protected]>
Since commit b18fdf71e01f ("io_uring: simplify io_req_link_next()"),
the io_wq_current_is_worker function is no longer needed, clean it
up.
Signed-off-by: Jackie Liu <[email protected]>
---
fs/io-wq.h | 8 ++------
1 file changed, 2 insertions(+), 6 deletions(-)
diff --git a/fs/io-wq.h b/fs/io-wq.h
index 600e0158cba7..771f3cda5ffd 100644
--- a/fs/io-wq.h
+++ b/fs/io-wq.h
@@ -118,10 +118,6 @@ static inline void io_wq_worker_sleeping(struct task_struct *tsk)
static inline void io_wq_worker_running(struct task_struct *tsk)
{
}
-#endif
+#endif /* CONFIG_IO_WQ */
-static inline bool io_wq_current_is_worker(void)
-{
- return in_task() && (current->flags & PF_IO_WORKER);
-}
-#endif
+#endif /* INTERNAL_IO_WQ_H */
--
2.17.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH 1/2] io_uring: remove parameter ctx of io_submit_state_start
2019-12-02 9:14 [PATCH 1/2] io_uring: remove parameter ctx of io_submit_state_start Jackie Liu
2019-12-02 9:14 ` [PATCH 2/2] io_uring: remove io_wq_current_is_worker Jackie Liu
@ 2019-12-03 3:03 ` Jens Axboe
1 sibling, 0 replies; 3+ messages in thread
From: Jens Axboe @ 2019-12-03 3:03 UTC (permalink / raw)
To: Jackie Liu; +Cc: io-uring
On 12/2/19 1:14 AM, Jackie Liu wrote:
> From: Jackie Liu <[email protected]>
>
> Parameter ctx we have never used, clean it up.
Thanks, applied 1-2.
> checkpatch.pl said:
> WARNING: Prefer 'unsigned int' to bare use of 'unsigned'
That's just checkpatch being annoying imho, they are 100% identical.
--
Jens Axboe
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2019-12-03 3:03 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-12-02 9:14 [PATCH 1/2] io_uring: remove parameter ctx of io_submit_state_start Jackie Liu
2019-12-02 9:14 ` [PATCH 2/2] io_uring: remove io_wq_current_is_worker Jackie Liu
2019-12-03 3:03 ` [PATCH 1/2] io_uring: remove parameter ctx of io_submit_state_start Jens Axboe
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox