Re: [PATCH v8 2/9] block/mq-deadline: Only use zone locking if necessary

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

 



On 8/15/23 02:00, Bart Van Assche wrote:
> On 8/14/23 05:33, Damien Le Moal wrote:
>> On 8/12/23 06:35, Bart Van Assche wrote:
>>> @@ -934,7 +936,7 @@ static void dd_finish_request(struct request *rq)
>>>   
>>>   	atomic_inc(&per_prio->stats.completed);
>>>   
>>> -	if (blk_queue_is_zoned(q)) {
>>> +	if (rq->q->limits.use_zone_write_lock) {
>>
>> This is all nice and simple ! However, an inline helper to check
>> rq->q->limits.use_zone_write_lock would be nice. E.g.
>> blk_queue_use_zone_write_lock() ?
> 
> Hi Damien,
> 
> Do you perhaps want me to introduce a function that does nothing else than
> returning the value of q->limits.use_zone_write_lock? I'm asking this because
> recently I have seen a fair number of patches that remove functions that do
> nothing else than returning the value of a single member variable.

I think that what you proposed in your other email (modify
blk_req_needs_zone_write_lock) is better when you need to test
use_zone_write_lock using a request.
Not sure about the cases where we need to test that limit using the queue only.
I personally like helpers that avoid hardcoding accesses to the queue limits,
but if such helpers are not OK, that is fine. No strong opinion.

> 
> Thanks,
> 
> Bart.
> 

-- 
Damien Le Moal
Western Digital Research




[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