All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jens Axboe <axboe@kernel.dk>
To: Mike Snitzer <snitzer@redhat.com>
Cc: Hannes Reinecke <hare@suse.de>,
	linux-block@vger.kernel.org, linux-scsi@vger.kernel.org,
	linux-ide@vger.kernel.org
Subject: Re: [PATCH 23/28] block: kill lld busy
Date: Mon, 29 Oct 2018 10:26:59 -0600	[thread overview]
Message-ID: <7052ebf5-d098-5630-5907-43a87a70e993@kernel.dk> (raw)
In-Reply-To: <20181029155116.GA11161@redhat.com>

On 10/29/18 9:51 AM, Mike Snitzer wrote:
> On Mon, Oct 29 2018 at 10:25am -0400,
> Jens Axboe <axboe@kernel.dk> wrote:
> 
>> On 10/29/18 1:10 AM, Hannes Reinecke wrote:
>>> On 10/25/18 11:10 PM, Jens Axboe wrote:
>>>> Nobody sets the helper, so we always return 0. Kill it.
>>>>
>>>> Signed-off-by: Jens Axboe <axboe@kernel.dk>
>>>> ---
>>>>   block/blk-core.c       | 28 ----------------------------
>>>>   block/blk-settings.c   |  6 ------
>>>>   drivers/md/dm-mpath.c  |  4 +---
>>>>   include/linux/blkdev.h |  4 ----
>>>>   4 files changed, 1 insertion(+), 41 deletions(-)
>>>>
>>>> diff --git a/block/blk-core.c b/block/blk-core.c
>>>> index 4c39c7865f9c..dd1328f4dc31 100644
>>>> --- a/block/blk-core.c
>>>> +++ b/block/blk-core.c
>>>> @@ -1795,34 +1795,6 @@ void rq_flush_dcache_pages(struct request *rq)
>>>>   EXPORT_SYMBOL_GPL(rq_flush_dcache_pages);
>>>>   #endif
>>>>   
>>>> -/**
>>>> - * blk_lld_busy - Check if underlying low-level drivers of a device are busy
>>>> - * @q : the queue of the device being checked
>>>> - *
>>>> - * Description:
>>>> - *    Check if underlying low-level drivers of a device are busy.
>>>> - *    If the drivers want to export their busy state, they must set own
>>>> - *    exporting function using blk_queue_lld_busy() first.
>>>> - *
>>>> - *    Basically, this function is used only by request stacking drivers
>>>> - *    to stop dispatching requests to underlying devices when underlying
>>>> - *    devices are busy.  This behavior helps more I/O merging on the queue
>>>> - *    of the request stacking driver and prevents I/O throughput regression
>>>> - *    on burst I/O load.
>>>> - *
>>>> - * Return:
>>>> - *    0 - Not busy (The request stacking driver should dispatch request)
>>>> - *    1 - Busy (The request stacking driver should stop dispatching request)
>>>> - */
>>>> -int blk_lld_busy(struct request_queue *q)
>>>> -{
>>>> -	if (q->lld_busy_fn)
>>>> -		return q->lld_busy_fn(q);
>>>> -
>>>> -	return 0;
>>>> -}
>>>> -EXPORT_SYMBOL_GPL(blk_lld_busy);
>>>> -
>>>>   /**
>>>>    * blk_rq_unprep_clone - Helper function to free all bios in a cloned request
>>>>    * @rq: the clone request to be cleaned up
>>>> diff --git a/block/blk-settings.c b/block/blk-settings.c
>>>> index 3c5da75c2def..1895f499bbe5 100644
>>>> --- a/block/blk-settings.c
>>>> +++ b/block/blk-settings.c
>>>> @@ -32,12 +32,6 @@ void blk_queue_rq_timeout(struct request_queue *q, unsigned int timeout)
>>>>   }
>>>>   EXPORT_SYMBOL_GPL(blk_queue_rq_timeout);
>>>>   
>>>> -void blk_queue_lld_busy(struct request_queue *q, lld_busy_fn *fn)
>>>> -{
>>>> -	q->lld_busy_fn = fn;
>>>> -}
>>>> -EXPORT_SYMBOL_GPL(blk_queue_lld_busy);
>>>> -
>>>>   /**
>>>>    * blk_set_default_limits - reset limits to default values
>>>>    * @lim:  the queue_limits structure to reset
>>>> diff --git a/drivers/md/dm-mpath.c b/drivers/md/dm-mpath.c
>>>> index a24ed3973e7c..4d736e0fd67f 100644
>>>> --- a/drivers/md/dm-mpath.c
>>>> +++ b/drivers/md/dm-mpath.c
>>>> @@ -1936,9 +1936,7 @@ static int multipath_iterate_devices(struct dm_target *ti,
>>>>   
>>>>   static int pgpath_busy(struct pgpath *pgpath)
>>>>   {
>>>> -	struct request_queue *q = bdev_get_queue(pgpath->path.dev->bdev);
>>>> -
>>>> -	return blk_lld_busy(q);
>>>> +	return 0;
>>>>   }
>>>>   
>>>>   /*
>>> Actually, I'm not quite sure this is correct; dm-mpath needs to return a 
>>> busy status (via the '->busy' callback) to allow for back-pressure on 
>>> the upper layers.
>>> Just disabling the callback will disable this.
>>> Shouldn't we check if the tagmap is busy here?
>>
>> Mike? We can pretty easily make it just check for busy tags.
> 
> OK, please feel free to do so.
> 
> Happy to pick the patch up or provide review so you can stage it in your
> 4.21 oriented tree.

I reshuffled a bit and made SCSI provide an mq variant of the target
busy. So blk_lld_busy() remains, just with an mq handler instead.
This means that dm-mpath won't need any changing, I think we're good.

-- 
Jens Axboe

  reply	other threads:[~2018-10-29 16:26 UTC|newest]

Thread overview: 90+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-25 21:10 [PATCHSET 0/28] blk-mq driver conversions and legacy path removal Jens Axboe
2018-10-25 21:10 ` [PATCH 01/28] sunvdc: convert to blk-mq Jens Axboe
2018-10-27 10:42   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 02/28] ms_block: " Jens Axboe
2018-10-27 10:43   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 03/28] mspro_block: " Jens Axboe
2018-10-27 10:44   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 04/28] ide: " Jens Axboe
2018-10-27 10:51   ` Hannes Reinecke
2018-10-27 16:51     ` Jens Axboe
2018-10-25 21:10 ` [PATCH 05/28] IB/srp: remove old request_fn_active check Jens Axboe
2018-10-25 21:23   ` Bart Van Assche
2018-10-25 21:24     ` Jens Axboe
2018-10-26  7:08   ` Hannes Reinecke
2018-10-26 14:32     ` Jens Axboe
2018-10-26 15:03       ` Bart Van Assche
2018-10-25 21:10 ` [PATCH 06/28] blk-mq: remove the request_list usage Jens Axboe
2018-10-27 10:52   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 07/28] blk-mq: remove legacy check in queue blk_freeze_queue() Jens Axboe
2018-10-27 10:52   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 08/28] scsi: kill off the legacy IO path Jens Axboe
2018-10-25 21:36   ` Bart Van Assche
2018-10-25 22:18     ` Jens Axboe
2018-10-25 22:44       ` Madhani, Himanshu
2018-10-25 23:00         ` Jens Axboe
2018-10-25 23:06           ` Madhani, Himanshu
2018-10-29  6:48   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 09/28] dm: remove " Jens Axboe
2018-10-29  6:53   ` Hannes Reinecke
2018-10-29 14:17     ` Jens Axboe
2018-10-25 21:10 ` [PATCH 10/28] dasd: remove dead code Jens Axboe
2018-10-29  6:54   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 11/28] bsg: pass in desired timeout handler Jens Axboe
2018-10-28 15:53   ` Christoph Hellwig
2018-10-28 23:05     ` Jens Axboe
2018-10-29  6:55   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 12/28] bsg: provide bsg_remove_queue() helper Jens Axboe
2018-10-28 15:53   ` Christoph Hellwig
2018-10-29  6:55   ` Hannes Reinecke
2018-10-29 10:16   ` Johannes Thumshirn
2018-10-29 14:15     ` Jens Axboe
2018-10-25 21:10 ` [PATCH 13/28] bsg: convert to use blk-mq Jens Axboe
2018-10-28 16:07   ` Christoph Hellwig
2018-10-28 23:25     ` Jens Axboe
2018-10-29  6:57   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 14/28] block: remove blk_complete_request() Jens Axboe
2018-10-29  6:59   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 15/28] blk-wbt: kill check for legacy queue type Jens Axboe
2018-10-29  6:59   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 16/28] blk-cgroup: remove legacy queue bypassing Jens Axboe
2018-10-29  7:00   ` Hannes Reinecke
2018-10-29 11:00   ` Johannes Thumshirn
2018-10-29 14:23     ` Jens Axboe
2018-10-29 14:25       ` Johannes Thumshirn
2018-10-29 14:59         ` Jens Axboe
2018-10-25 21:10 ` [PATCH 17/28] block: remove legacy rq tagging Jens Axboe
2018-10-29  7:01   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 18/28] block: remove non mq parts from the flush code Jens Axboe
2018-10-29  7:02   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 19/28] block: remove legacy IO schedulers Jens Axboe
2018-10-25 21:10 ` [PATCH 20/28] block: remove dead elevator code Jens Axboe
2018-10-25 21:10 ` [PATCH 21/28] block: remove __blk_put_request() Jens Axboe
2018-10-29  7:03   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 22/28] block: kill legacy parts of timeout handling Jens Axboe
2018-10-29  7:04   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 23/28] block: kill lld busy Jens Axboe
2018-10-25 21:42   ` Bart Van Assche
2018-10-25 22:18     ` Jens Axboe
2018-10-29  7:10   ` Hannes Reinecke
2018-10-29 14:25     ` Jens Axboe
2018-10-29 15:51       ` Mike Snitzer
2018-10-29 16:26         ` Jens Axboe [this message]
2018-10-25 21:10 ` [PATCH 24/28] block: remove request_list code Jens Axboe
2018-10-29  7:10   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 25/28] block: kill request slab cache Jens Axboe
2018-10-29  7:11   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 26/28] block: remove req_no_special_merge() from merging code Jens Axboe
2018-10-29  7:12   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 27/28] blk-merge: kill dead queue lock held check Jens Axboe
2018-10-29  7:12   ` Hannes Reinecke
2018-10-25 21:10 ` [PATCH 28/28] block: get rid of blk_queued_rq() Jens Axboe
2018-10-29  7:12   ` Hannes Reinecke
2018-10-25 23:09 ` [PATCHSET 0/28] blk-mq driver conversions and legacy path removal Bart Van Assche
2018-10-25 23:11   ` Jens Axboe
2018-10-29 12:00 ` Ming Lei
2018-10-29 14:50   ` Jens Axboe
2018-10-29 15:04     ` Jens Axboe
2018-10-30  9:41       ` Ming Lei
2018-10-30 14:13         ` Jens Axboe
2018-10-29 15:05     ` Ming Lei

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=7052ebf5-d098-5630-5907-43a87a70e993@kernel.dk \
    --to=axboe@kernel.dk \
    --cc=hare@suse.de \
    --cc=linux-block@vger.kernel.org \
    --cc=linux-ide@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=snitzer@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.