Message ID | 20220512030442.2530552-4-joel@joelfernandes.org (mailing list archive) |
---|---|
State | Superseded |
Headers | show |
Series | Implement call_rcu_lazy() and miscellaneous fixes | expand |
On Thu, May 12, 2022 at 03:04:31AM +0000, Joel Fernandes (Google) wrote: > This is required to prevent callbacks triggering RCU machinery too > quickly and too often, which adds more power to the system. > > Signed-off-by: Joel Fernandes (Google) <joel@joelfernandes.org> Hard to argue with this one given that icq_free_icq_rcu() just does a kmem_cache_free(). ;-) Thanx, Paul > --- > block/blk-ioc.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/block/blk-ioc.c b/block/blk-ioc.c > index 11f49f78db32..96d5de5df0b6 100644 > --- a/block/blk-ioc.c > +++ b/block/blk-ioc.c > @@ -98,7 +98,7 @@ static void ioc_destroy_icq(struct io_cq *icq) > */ > icq->__rcu_icq_cache = et->icq_cache; > icq->flags |= ICQ_DESTROYED; > - call_rcu(&icq->__rcu_head, icq_free_icq_rcu); > + call_rcu_lazy(&icq->__rcu_head, icq_free_icq_rcu); > } > > /* > -- > 2.36.0.550.gb090851708-goog >
diff --git a/block/blk-ioc.c b/block/blk-ioc.c index 11f49f78db32..96d5de5df0b6 100644 --- a/block/blk-ioc.c +++ b/block/blk-ioc.c @@ -98,7 +98,7 @@ static void ioc_destroy_icq(struct io_cq *icq) */ icq->__rcu_icq_cache = et->icq_cache; icq->flags |= ICQ_DESTROYED; - call_rcu(&icq->__rcu_head, icq_free_icq_rcu); + call_rcu_lazy(&icq->__rcu_head, icq_free_icq_rcu); } /*
This is required to prevent callbacks triggering RCU machinery too quickly and too often, which adds more power to the system. Signed-off-by: Joel Fernandes (Google) <joel@joelfernandes.org> --- block/blk-ioc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)