Re: [PATCH 08/10] blkcg: implement blk-iocost

From: Tejun Heo
Date: Thu Aug 29 2019 - 11:46:15 EST


Hello,

On Thu, Aug 29, 2019 at 09:39:28PM +0800, Hillf Danton wrote:
> > + on_q_ns = ktime_get_ns() - rq->alloc_time_ns;
> > + rq_wait_ns = rq->start_time_ns - rq->alloc_time_ns;
> > +
> ehm... alloc_time makes no sense wrt start_time if this is their only
> use. What are you trying to measure with the two stamps if they are
> meaningfully apart?

Queue depth depletion.

> > + rq_qos_add(q, rqos);
> > + ret = blkcg_activate_policy(q, &blkcg_policy_iocost);
> > + if (ret) {
> > + rq_qos_del(q, rqos);
>
> free_percpu(ioc->pcpu_stat);

Good catch. Will send a follow up patch.

Thanks.

--
tejun