Re: [PATCH 2/3] blk-mq: remove RQF_ELVPRIV

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On 5/18/23 7:20 AM, Ming Lei wrote:
> On Thu, May 18, 2023 at 03:06:32PM +0200, Christoph Hellwig wrote:
>> On Thu, May 18, 2023 at 03:11:12PM +0800, Ming Lei wrote:
>>>> -		if ((rq->rq_flags & RQF_ELVPRIV) && e->type->ops.requeue_request)
>>>> +		if (e->type->ops.requeue_request)
>>>>  			e->type->ops.requeue_request(rq);
>>>
>>> The above actually changes current behavior since RQF_ELVPRIV is only set
>>> iff the following condition is true:
>>>
>>> 	(rq->rq_flags & RQF_ELV) && !op_is_flush(rq->cmd_flags) &&
>>> 		e->type->ops.prepare_request.
>>
>> It would require an I/O scheduler that implements .requeue_request but
>> not .prepare_request, which doesn't exist and also is rather pointless as
>> this .requeue_request method would never get called in the current code.
>>
>> So no, no behavior change in practice.
> 
> Fair enough, just found that all three schedulers have implemented
> e->type->ops.prepare_request.

We should probably make this requirement explicit though, seems
very fragile to depend on it just because it's the status quo.

-- 
Jens Axboe





[Index of Archives]     [Linux RAID]     [Linux SCSI]     [Linux ATA RAID]     [IDE]     [Linux Wireless]     [Linux Kernel]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Device Mapper]

  Powered by Linux