mirror of
https://github.com/hardkernel/linux.git
synced 2026-03-25 20:10:23 +09:00
Revert "ANDROID: block/mq-deadline: Only use zone locking if necessary"
Prepare for applying the FROMLIST version of this patch.
This reverts commit f57c245b52.
Bug: 234829282
Change-Id: I34cc27653fc8d22f8e068f2776be285c5e2806f3
Signed-off-by: Bart Van Assche <bvanassche@google.com>
This commit is contained in:
@@ -537,8 +537,7 @@ static int blk_revalidate_zone_cb(struct blk_zone *zone, unsigned int idx,
|
||||
break;
|
||||
case BLK_ZONE_TYPE_SEQWRITE_REQ:
|
||||
case BLK_ZONE_TYPE_SEQWRITE_PREF:
|
||||
if (!blk_queue_pipeline_zoned_writes(q) &&
|
||||
!args->seq_zones_wlock) {
|
||||
if (!args->seq_zones_wlock) {
|
||||
args->seq_zones_wlock =
|
||||
blk_alloc_zone_bitmap(q->node, args->nr_zones);
|
||||
if (!args->seq_zones_wlock)
|
||||
|
||||
@@ -355,8 +355,7 @@ deadline_fifo_request(struct deadline_data *dd, struct dd_per_prio *per_prio,
|
||||
return NULL;
|
||||
|
||||
rq = rq_entry_fifo(per_prio->fifo_list[data_dir].next);
|
||||
if (data_dir == DD_READ || !blk_queue_is_zoned(rq->q) ||
|
||||
blk_queue_pipeline_zoned_writes(rq->q))
|
||||
if (data_dir == DD_READ || !blk_queue_is_zoned(rq->q))
|
||||
return rq;
|
||||
|
||||
/*
|
||||
@@ -401,8 +400,7 @@ deadline_next_request(struct deadline_data *dd, struct dd_per_prio *per_prio,
|
||||
if (!rq)
|
||||
return NULL;
|
||||
|
||||
if (data_dir == DD_READ || !blk_queue_is_zoned(rq->q) ||
|
||||
blk_queue_pipeline_zoned_writes(rq->q))
|
||||
if (data_dir == DD_READ || !blk_queue_is_zoned(rq->q))
|
||||
return rq;
|
||||
|
||||
/*
|
||||
@@ -530,9 +528,8 @@ dispatch_find_request:
|
||||
}
|
||||
|
||||
/*
|
||||
* For a zoned block device that requires write serialization, if we
|
||||
* only have writes queued and none of them can be dispatched, rq will
|
||||
* be NULL.
|
||||
* For a zoned block device, if we only have writes queued and none of
|
||||
* them can be dispatched, rq will be NULL.
|
||||
*/
|
||||
if (!rq)
|
||||
return NULL;
|
||||
@@ -934,8 +931,7 @@ static void dd_finish_request(struct request *rq)
|
||||
|
||||
atomic_inc(&per_prio->stats.completed);
|
||||
|
||||
if (blk_queue_is_zoned(rq->q) &&
|
||||
!blk_queue_pipeline_zoned_writes(q)) {
|
||||
if (blk_queue_is_zoned(q)) {
|
||||
unsigned long flags;
|
||||
|
||||
spin_lock_irqsave(&dd->zone_lock, flags);
|
||||
|
||||
Reference in New Issue
Block a user