On Tue 25-10-16 14:41:41, Josef Bacik wrote:
> diff --git a/mm/page-writeback.c b/mm/page-writeback.c
> index 121a6e3..e09b3ad 100644
> --- a/mm/page-writeback.c
> +++ b/mm/page-writeback.c
> @@ -596,11 +596,11 @@ static void wb_domain_writeout_inc(struct wb_domain *dom,
> * Increment @wb's writeout completion count and the global writeout
> * completion count. Called from test_clear_page_writeback().
> */
> -static inline void __wb_writeout_inc(struct bdi_writeback *wb)
> +static inline void __wb_writeout_inc(struct bdi_writeback *wb, long bytes)
Please keep the names consistent - i.e. when you rename wb_writeout_inc to
wb_writeout_add, then you should do the same with __wb_writeout_inc...
> {
> struct wb_domain *cgdom;
>
> - __inc_wb_stat(wb, WB_WRITTEN);
> + __add_wb_stat(wb, WB_WRITTEN_BYTES, bytes);
> wb_domain_writeout_inc(&global_wb_domain, &wb->completions,
> wb->bdi->max_prop_frac);
Also I think you will need to change the per-domain writeback statistics to
bytes as well. Otherwise the proportions can get skewed.
Other than that the patch looks good to me.
Honza
--
Jan Kara <jack@xxxxxxxx>
SUSE Labs, CR
--
To unsubscribe from this list: send the line "unsubscribe linux-btrfs" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html