lkml.org 
[lkml]   [2022]   [Aug]   [17]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH v7 4/9] blk-throttle: fix io hung due to configuration updates
On Wed, Aug 17, 2022 at 09:30:30AM +0800, Yu Kuai wrote:
> > Would it be easier if the fields were signed? It's fragile and odd to
> > explain "these are unsigned but if they underflow they behave just like
> > signed when added" when they can just be signed. Also, I have a hard time
> > understand what "preempt" means above.
>
> I think preempt shound never happen based on current FIFO
> implementation, perhaps

Can you elaborate what "preempt" is?

> > > + if (bps_limit != U64_MAX)
> > > + tg->bytes_skipped[rw] +=
> > > + calculate_bytes_allowed(bps_limit, jiffy_elapsed) -
> > > + tg->bytes_disp[rw];
> > > + if (iops_limit != UINT_MAX)
> > > + tg->io_skipped[rw] +=
> > > + calculate_io_allowed(iops_limit, jiffy_elapsed) -
> > > + tg->io_disp[rw];
> >
> > So, this is calculating the budgets to carry over. Can we name them
> > accordingly? I don't know what "skipped" means.
>
> Yeah, thanks for you advice, art of naming is a little hard for me...
> How do you think about these name: extended_bytes/io_budget?

How about carryover_{ios|bytes}?

Thanks.

--
tejun

\
 
 \ /
  Last update: 2022-08-17 19:53    [W:0.131 / U:0.784 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site