diff --git a/block/blk-iocost.c b/block/blk-iocost.c index b60625613e09..dd7749d59900 100644 --- a/block/blk-iocost.c +++ b/block/blk-iocost.c @@ -3093,23 +3093,23 @@ static void ioc_pd_stat(struct blkg_policy_data *pd, struct seq_file *s) struct ioc_gq *iocg = pd_to_iocg(pd); struct ioc *ioc = iocg->ioc; - if (!ioc->enabled) + if (!data_race(ioc->enabled)) return; if (iocg->level == 0) { unsigned vp10k = DIV64_U64_ROUND_CLOSEST( - ioc->vtime_base_rate * 10000, + data_race(ioc->vtime_base_rate) * 10000, VTIME_PER_USEC); seq_printf(s, " cost.vrate=%u.%02u", vp10k / 100, vp10k % 100); } - seq_printf(s, " cost.usage=%llu", iocg->last_stat.usage_us); + seq_printf(s, " cost.usage=%llu", data_race(iocg->last_stat.usage_us)); if (blkcg_debug_stats) seq_printf(s, " cost.wait=%llu cost.indebt=%llu cost.indelay=%llu", - iocg->last_stat.wait_us, - iocg->last_stat.indebt_us, - iocg->last_stat.indelay_us); + data_race(iocg->last_stat.wait_us), + data_race(iocg->last_stat.indebt_us), + data_race(iocg->last_stat.indelay_us)); } static u64 ioc_weight_prfill(struct seq_file *sf, struct blkg_policy_data *pd,