linux-block.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] block/bfq: the delta_from_first should be ns rather than us
@ 2021-07-21  6:30 liubaozhu
  2021-07-21  7:56 ` Paolo Valente
       [not found] ` <3A3B282C-FA5D-43F3-9C78-5E257C93A835@linaro.org>
  0 siblings, 2 replies; 3+ messages in thread
From: liubaozhu @ 2021-07-21  6:30 UTC (permalink / raw)
  To: paolo.valente; +Cc: axboe, linux-block, linux-kernel, liubaozhu

In the block/bfq-iosched.c,the function bfq_update_peak_rate(),
bfqd->delta_from_first = now_ns - bfqd->first_dispatch,
according to the subtraction operation here,now_ns is ns,
and bfqd->first_dispatch is also ns,so bfqd->delta_from_first should be ns.

Signed-off-by: liubaozhu <liubaozhu@uniontech.com>
---
 block/bfq-iosched.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/block/bfq-iosched.h b/block/bfq-iosched.h
index 99c2a3cb0..7cf4fc8c3 100644
--- a/block/bfq-iosched.h
+++ b/block/bfq-iosched.h
@@ -632,7 +632,7 @@ struct bfq_data {
 	u64 tot_sectors_dispatched;
 	/* max rq size seen during current observation interval (sectors) */
 	u32 last_rq_max_size;
-	/* time elapsed from first dispatch in current observ. interval (us) */
+	/* time elapsed from first dispatch in current observ. interval (ns) */
 	u64 delta_from_first;
 	/*
 	 * Current estimate of the device peak rate, measured in
-- 
2.20.1




^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH] block/bfq: the delta_from_first should be ns rather than us
  2021-07-21  6:30 [PATCH] block/bfq: the delta_from_first should be ns rather than us liubaozhu
@ 2021-07-21  7:56 ` Paolo Valente
       [not found] ` <3A3B282C-FA5D-43F3-9C78-5E257C93A835@linaro.org>
  1 sibling, 0 replies; 3+ messages in thread
From: Paolo Valente @ 2021-07-21  7:56 UTC (permalink / raw)
  To: liubaozhu; +Cc: axboe, linux-block, linux-kernel

[RESENDING ...]

> Il giorno 21 lug 2021, alle ore 08:30, liubaozhu <liubaozhu@uniontech.com> ha scritto:
> 
> In the block/bfq-iosched.c,the function bfq_update_peak_rate(),
> bfqd->delta_from_first = now_ns - bfqd->first_dispatch,
> according to the subtraction operation here,now_ns is ns,
> and bfqd->first_dispatch is also ns,so bfqd->delta_from_first should be ns.
> 

Correct!

Acked-by: Paolo Valente <paolo.valente@linaro.org>

Thank you,
Paolo

> Signed-off-by: liubaozhu <liubaozhu@uniontech.com>
> ---
> block/bfq-iosched.h | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/block/bfq-iosched.h b/block/bfq-iosched.h
> index 99c2a3cb0..7cf4fc8c3 100644
> --- a/block/bfq-iosched.h
> +++ b/block/bfq-iosched.h
> @@ -632,7 +632,7 @@ struct bfq_data {
> 	u64 tot_sectors_dispatched;
> 	/* max rq size seen during current observation interval (sectors) */
> 	u32 last_rq_max_size;
> -	/* time elapsed from first dispatch in current observ. interval (us) */
> +	/* time elapsed from first dispatch in current observ. interval (ns) */
> 	u64 delta_from_first;
> 	/*
> 	 * Current estimate of the device peak rate, measured in
> -- 
> 2.20.1
> 
> 
> 


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] block/bfq: the delta_from_first should be ns rather than us
       [not found] ` <3A3B282C-FA5D-43F3-9C78-5E257C93A835@linaro.org>
@ 2021-07-21 16:19   ` Jens Axboe
  0 siblings, 0 replies; 3+ messages in thread
From: Jens Axboe @ 2021-07-21 16:19 UTC (permalink / raw)
  To: Paolo Valente, liubaozhu; +Cc: linux-block, linux-kernel

On 7/21/21 1:54 AM, Paolo Valente wrote:
> 
> 
>> Il giorno 21 lug 2021, alle ore 08:30, liubaozhu <liubaozhu@uniontech.com <mailto:liubaozhu@uniontech.com>> ha scritto:
>>
>> In the block/bfq-iosched.c,the function bfq_update_peak_rate(),
>> bfqd->delta_from_first = now_ns - bfqd->first_dispatch,
>> according to the subtraction operation here,now_ns is ns,
>> and bfqd->first_dispatch is also ns,so bfqd->delta_from_first should be ns.
>>
> 
> Correct!
> 
> Acked-by: Paolo Valente <paolo.valente@linaro.org <mailto:paolo.valente@linaro.org>>

Just pick this up for your 5.15 series and include it in that.

-- 
Jens Axboe


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2021-07-21 16:19 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-07-21  6:30 [PATCH] block/bfq: the delta_from_first should be ns rather than us liubaozhu
2021-07-21  7:56 ` Paolo Valente
     [not found] ` <3A3B282C-FA5D-43F3-9C78-5E257C93A835@linaro.org>
2021-07-21 16:19   ` Jens Axboe

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).