Skip to content

Commit

Permalink
io-wq: remove unused io_wqe_need_worker() function
Browse files Browse the repository at this point in the history
A previous commit removed the need for this, but overlooked that we no
longer use it at all. Get rid of it.

Fixes: 685fe7f ("io-wq: eliminate the need for a manager thread")
Reported-by: kernel test robot <lkp@intel.com>
Signed-off-by: Jens Axboe <axboe@kernel.dk>
  • Loading branch information
Jens Axboe committed Apr 20, 2021
1 parent 734551d commit eb37267
Showing 1 changed file with 0 additions and 13 deletions.
13 changes: 0 additions & 13 deletions fs/io-wq.c
Original file line number Diff line number Diff line change
Expand Up @@ -661,19 +661,6 @@ static void create_io_worker(struct io_wq *wq, struct io_wqe *wqe, int index)
wake_up_new_task(tsk);
}

static inline bool io_wqe_need_worker(struct io_wqe *wqe, int index)
__must_hold(wqe->lock)
{
struct io_wqe_acct *acct = &wqe->acct[index];

if (acct->nr_workers && test_bit(IO_WQ_BIT_EXIT, &wqe->wq->state))
return false;
/* if we have available workers or no work, no need */
if (!hlist_nulls_empty(&wqe->free_list) || !io_wqe_run_queue(wqe))
return false;
return acct->nr_workers < acct->max_workers;
}

/*
* Iterate the passed in list and call the specific function for each
* worker that isn't exiting
Expand Down

0 comments on commit eb37267

Please sign in to comment.