diff options
author | Kent Overstreet <kent.overstreet@linux.dev> | 2023-12-23 22:55:05 -0500 |
---|---|---|
committer | Kent Overstreet <kent.overstreet@linux.dev> | 2024-01-01 11:47:42 -0500 |
commit | ef23397c301900e9e7050f8245e2a25b5eea1589 (patch) | |
tree | ffe4762b81f2b4ae0f4bbdaeb779f3d67902ec77 /fs/bcachefs/util.c | |
parent | e34ec13a56a02695458f6296daa9239c70b4cd29 (diff) | |
download | linux-stable-ef23397c301900e9e7050f8245e2a25b5eea1589.tar.gz linux-stable-ef23397c301900e9e7050f8245e2a25b5eea1589.tar.bz2 linux-stable-ef23397c301900e9e7050f8245e2a25b5eea1589.zip |
bcachefs: fix warning about uninitialized time_stats
Signed-off-by: Kent Overstreet <kent.overstreet@linux.dev>
Diffstat (limited to 'fs/bcachefs/util.c')
-rw-r--r-- | fs/bcachefs/util.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/fs/bcachefs/util.c b/fs/bcachefs/util.c index 00ddd91ddfcc..d530277f9017 100644 --- a/fs/bcachefs/util.c +++ b/fs/bcachefs/util.c @@ -447,9 +447,9 @@ void __bch2_time_stats_update(struct bch2_time_stats *stats, u64 start, u64 end) { unsigned long flags; - WARN_RATELIMIT(!stats->min_duration || !stats->min_freq, - "time_stats: min_duration = %llu, min_freq = %llu", - stats->min_duration, stats->min_freq); + WARN_ONCE(!stats->duration_stats_weighted.weight || + !stats->freq_stats_weighted.weight, + "uninitialized time_stats"); if (!stats->buffer) { spin_lock_irqsave(&stats->lock, flags); |