Cleaning up the code a little bit. attempt_plug_merge() traverses the plug list anyway, we can do the request counting there, so stack size is reduced a little bit. The motivation here is I suspect if we should count the requests for each queue (task could handle multiple disks in the meantime), but my test doesn't show it's worthy doing. If somebody proves we should do it, below change will make that more easier.
Showing the changes to include/linux (1 of 2 files). Show all
Unified · Split
| @@ -873,7 +873,6 @@ struct blk_plug { · 872 unmodified lines | ||
| 873 | 873 | struct list_head list; |
| 874 | 874 | struct list_head cb_list; |
| 875 | 875 | unsigned int should_sort; |
| 876 | − unsigned int count; | |
| 877 | 876 | }; |
| 878 | 877 | #define BLK_MAX_REQUEST_COUNT 16 |
| 879 | 878 | |