Searched hist:"6 fc4dbcf" (Results 1 – 2 of 2) sorted by relevance
/openbmc/linux/include/linux/ |
H A D | padata.h | 6fc4dbcf Thu Jul 18 10:01:46 CDT 2019 Herbert Xu <herbert@gondor.apana.org.au> padata: Replace delayed timer with immediate workqueue in padata_reorder
The function padata_reorder will use a timer when it cannot progress while completed jobs are outstanding (pd->reorder_objects > 0). This is suboptimal as if we do end up using the timer then it would have introduced a gratuitous delay of one second.
In fact we can easily distinguish between whether completed jobs are outstanding and whether we can make progress. All we have to do is look at the next pqueue list.
This patch does that by replacing pd->processed with pd->cpu so that the next pqueue is more accessible.
A work queue is used instead of the original try_again to avoid hogging the CPU.
Note that we don't bother removing the work queue in padata_flush_queues because the whole premise is broken. You cannot flush async crypto requests so it makes no sense to even try. A subsequent patch will fix it by replacing it with a ref counting scheme.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au> 6fc4dbcf Thu Jul 18 10:01:46 CDT 2019 Herbert Xu <herbert@gondor.apana.org.au> padata: Replace delayed timer with immediate workqueue in padata_reorder The function padata_reorder will use a timer when it cannot progress while completed jobs are outstanding (pd->reorder_objects > 0). This is suboptimal as if we do end up using the timer then it would have introduced a gratuitous delay of one second. In fact we can easily distinguish between whether completed jobs are outstanding and whether we can make progress. All we have to do is look at the next pqueue list. This patch does that by replacing pd->processed with pd->cpu so that the next pqueue is more accessible. A work queue is used instead of the original try_again to avoid hogging the CPU. Note that we don't bother removing the work queue in padata_flush_queues because the whole premise is broken. You cannot flush async crypto requests so it makes no sense to even try. A subsequent patch will fix it by replacing it with a ref counting scheme. Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
|
/openbmc/linux/kernel/ |
H A D | padata.c | 6fc4dbcf Thu Jul 18 10:01:46 CDT 2019 Herbert Xu <herbert@gondor.apana.org.au> padata: Replace delayed timer with immediate workqueue in padata_reorder
The function padata_reorder will use a timer when it cannot progress while completed jobs are outstanding (pd->reorder_objects > 0). This is suboptimal as if we do end up using the timer then it would have introduced a gratuitous delay of one second.
In fact we can easily distinguish between whether completed jobs are outstanding and whether we can make progress. All we have to do is look at the next pqueue list.
This patch does that by replacing pd->processed with pd->cpu so that the next pqueue is more accessible.
A work queue is used instead of the original try_again to avoid hogging the CPU.
Note that we don't bother removing the work queue in padata_flush_queues because the whole premise is broken. You cannot flush async crypto requests so it makes no sense to even try. A subsequent patch will fix it by replacing it with a ref counting scheme.
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
|