lkml.org 
[lkml]   [2023]   [Jan]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH v3 14/14] blk-mq: correct stale comment of .get_budget
    Date
    Commit 88022d7201e96 ("blk-mq: don't handle failure in .get_budget")
    remove BLK_STS_RESOURCE return value and we only check if we can get
    the budget from .get_budget() now.
    Correct stale comment that ".get_budget() returns BLK_STS_NO_RESOURCE"
    to ".get_budget() fails to get the budget".

    Fixes: 88022d7201e9 ("blk-mq: don't handle failure in .get_budget")
    Signed-off-by: Kemeng Shi <shikemeng@huaweicloud.com>
    ---
    block/blk-mq-sched.c | 4 ++--
    1 file changed, 2 insertions(+), 2 deletions(-)

    diff --git a/block/blk-mq-sched.c b/block/blk-mq-sched.c
    index ae40cdb7a383..06b312c69114 100644
    --- a/block/blk-mq-sched.c
    +++ b/block/blk-mq-sched.c
    @@ -81,7 +81,7 @@ static bool blk_mq_dispatch_hctx_list(struct list_head *rq_list)
    /*
    * Only SCSI implements .get_budget and .put_budget, and SCSI restarts
    * its queue by itself in its completion handler, so we don't need to
    - * restart queue if .get_budget() returns BLK_STS_NO_RESOURCE.
    + * restart queue if .get_budget() fails to get the budget.
    *
    * Returns -EAGAIN if hctx->dispatch was found non-empty and run_work has to
    * be run again. This is necessary to avoid starving flushes.
    @@ -209,7 +209,7 @@ static struct blk_mq_ctx *blk_mq_next_ctx(struct blk_mq_hw_ctx *hctx,
    /*
    * Only SCSI implements .get_budget and .put_budget, and SCSI restarts
    * its queue by itself in its completion handler, so we don't need to
    - * restart queue if .get_budget() returns BLK_STS_NO_RESOURCE.
    + * restart queue if .get_budget() fails to get the budget.
    *
    * Returns -EAGAIN if hctx->dispatch was found non-empty and run_work has to
    * be run again. This is necessary to avoid starving flushes.
    --
    2.30.0
    \
     
     \ /
      Last update: 2023-03-26 23:36    [W:5.179 / U:0.056 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site