Commit c349b38
io_wq: add per-wq work handler instead of per work
to #28736503
commit f5fa38c upstream
io_uring is the only user of io-wq, and now it uses only io-wq callback
for all its requests, namely io_wq_submit_work(). Instead of storing
work->runner callback in each instance of io_wq_work, keep it in io-wq
itself.
pros:
- reduces io_wq_work size
- more robust -- ->func won't be invalidated with mem{cpy,set}(req)
- helps other work
Signed-off-by: Pavel Begunkov <asml.silence@gmail.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
Signed-off-by: Xiaoguang Wang <xiaoguang.wang@linux.alibaba.com>
Acked-by: Joseph Qi <joseph.qi@linux.alibaba.com>1 parent efc0728 commit c349b38
3 files changed
+12
-8
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
113 | 113 | | |
114 | 114 | | |
115 | 115 | | |
| 116 | + | |
116 | 117 | | |
117 | 118 | | |
118 | 119 | | |
| |||
529 | 530 | | |
530 | 531 | | |
531 | 532 | | |
532 | | - | |
| 533 | + | |
533 | 534 | | |
534 | 535 | | |
535 | 536 | | |
| |||
786 | 787 | | |
787 | 788 | | |
788 | 789 | | |
789 | | - | |
| 790 | + | |
790 | 791 | | |
791 | 792 | | |
792 | 793 | | |
| |||
1024 | 1025 | | |
1025 | 1026 | | |
1026 | 1027 | | |
1027 | | - | |
| 1028 | + | |
1028 | 1029 | | |
1029 | 1030 | | |
1030 | 1031 | | |
| |||
1038 | 1039 | | |
1039 | 1040 | | |
1040 | 1041 | | |
| 1042 | + | |
1041 | 1043 | | |
1042 | 1044 | | |
1043 | 1045 | | |
| |||
1094 | 1096 | | |
1095 | 1097 | | |
1096 | 1098 | | |
1097 | | - | |
| 1099 | + | |
1098 | 1100 | | |
1099 | 1101 | | |
1100 | 1102 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
85 | 85 | | |
86 | 86 | | |
87 | 87 | | |
88 | | - | |
89 | 88 | | |
90 | 89 | | |
91 | 90 | | |
| |||
94 | 93 | | |
95 | 94 | | |
96 | 95 | | |
97 | | - | |
| 96 | + | |
98 | 97 | | |
99 | | - | |
| 98 | + | |
100 | 99 | | |
101 | 100 | | |
102 | 101 | | |
| |||
108 | 107 | | |
109 | 108 | | |
110 | 109 | | |
| 110 | + | |
111 | 111 | | |
112 | 112 | | |
113 | 113 | | |
114 | 114 | | |
| 115 | + | |
115 | 116 | | |
116 | 117 | | |
117 | 118 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5695 | 5695 | | |
5696 | 5696 | | |
5697 | 5697 | | |
5698 | | - | |
| 5698 | + | |
5699 | 5699 | | |
5700 | 5700 | | |
5701 | 5701 | | |
| |||
6695 | 6695 | | |
6696 | 6696 | | |
6697 | 6697 | | |
| 6698 | + | |
6698 | 6699 | | |
6699 | 6700 | | |
6700 | 6701 | | |
| |||
0 commit comments