[PATCH v2 2/2] blk-mq: Add a polling specific stats function

Stephen Bates sbates at raithlin.com
Fri Apr 7 05:11:06 PDT 2017


On 2017-04-05, 7:14 PM, "Jens Axboe" <axboe at kernel.dk> wrote:

> Why not just have 8 buckets, and make it:
>
>	bucket = ddir + ilog2(bytes) - 9;
>
> and cap it at MAX_BUCKET (8) and put all those above into the top
> bucket.

Thanks. However, that equation does not differentiate between direction and size. Instead we can use

bucket = ddir + 2*(ilog2(bytes) - 9);

and then bin any IO over 64K in the largest of the two buckets based on direction. I’ll implement this in a v3….

Cheers

Stephen






More information about the Linux-nvme mailing list