lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <d32276eb-12ee-ef4f-6bc8-2d4da7dbd7f1@linux.dev>
Date:   Tue, 22 Aug 2023 10:21:34 +0800
From:   Chengming Zhou <chengming.zhou@...ux.dev>
To:     Bart Van Assche <bvanassche@....org>, axboe@...nel.dk,
        ming.lei@...hat.com, hch@....de
Cc:     linux-block@...r.kernel.org, linux-kernel@...r.kernel.org,
        zhouchengming@...edance.com
Subject: Re: [PATCH 1/4] blk-mq-tag: support queue filter in bt_tags_iter()

On 2023/8/22 03:58, Bart Van Assche wrote:
> On 8/21/23 00:35, chengming.zhou@...ux.dev wrote:
>> @@ -417,7 +425,23 @@ static void __blk_mq_all_tag_iter(struct blk_mq_tags *tags,
>>   void blk_mq_all_tag_iter(struct blk_mq_tags *tags, busy_tag_iter_fn *fn,
>>           void *priv)
>>   {
>> -    __blk_mq_all_tag_iter(tags, fn, priv, BT_TAG_ITER_STATIC_RQS);
>> +    __blk_mq_all_tag_iter(tags, fn, priv, BT_TAG_ITER_STATIC_RQS, NULL);
>> +}
>> +
>> +static void __blk_mq_tagset_busy_iter(struct blk_mq_tag_set *tagset,
>> +                      busy_tag_iter_fn *fn, void *priv,
>> +                      struct request_queue *q)
>> +{
>> +    unsigned int flags = tagset->flags;
>> +    int i, nr_tags;
>> +
>> +    nr_tags = blk_mq_is_shared_tags(flags) ? 1 : tagset->nr_hw_queues;
>> +
>> +    for (i = 0; i < nr_tags; i++) {
>> +        if (tagset->tags && tagset->tags[i])
>> +            __blk_mq_all_tag_iter(tagset->tags[i], fn, priv,
>> +                          BT_TAG_ITER_STARTED, q);
>> +    }
>>   }
>>     /**
>> @@ -436,16 +460,7 @@ void blk_mq_all_tag_iter(struct blk_mq_tags *tags, busy_tag_iter_fn *fn,
>>   void blk_mq_tagset_busy_iter(struct blk_mq_tag_set *tagset,
>>           busy_tag_iter_fn *fn, void *priv)
>>   {
>> -    unsigned int flags = tagset->flags;
>> -    int i, nr_tags;
>> -
>> -    nr_tags = blk_mq_is_shared_tags(flags) ? 1 : tagset->nr_hw_queues;
>> -
>> -    for (i = 0; i < nr_tags; i++) {
>> -        if (tagset->tags && tagset->tags[i])
>> -            __blk_mq_all_tag_iter(tagset->tags[i], fn, priv,
>> -                          BT_TAG_ITER_STARTED);
>> -    }
>> +    __blk_mq_tagset_busy_iter(tagset, fn, priv, NULL);
>>   }
>>   EXPORT_SYMBOL(blk_mq_tagset_busy_iter);
> 
> One change per patch please. I think the introduction of __blk_mq_tagset_busy_iter()
> should be a separate patch instead of happening in this patch.
> 

Yes, it's better. I will put it in a separate patch.

Thanks.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ