On Wed 11-02-26 12:30:54, Kundan Kumar wrote: > Add helper APIs needed by filesystems to avoid poking into writeback > internals. > > Suggested-by: Christoph Hellwig <[email protected]> > Signed-off-by: Kundan Kumar <[email protected]> > Signed-off-by: Anuj Gupta <[email protected]>
Looks sensible. Feel free to add: Reviewed-by: Jan Kara <[email protected]> Honza > --- > include/linux/backing-dev.h | 11 +++++++++++ > 1 file changed, 11 insertions(+) > > diff --git a/include/linux/backing-dev.h b/include/linux/backing-dev.h > index 0c8342747cab..4165ad3ddf00 100644 > --- a/include/linux/backing-dev.h > +++ b/include/linux/backing-dev.h > @@ -78,6 +78,17 @@ static inline s64 wb_stat_sum(struct bdi_writeback *wb, > enum wb_stat_item item) > > extern void wb_writeout_inc(struct bdi_writeback *wb); > > +static inline int bdi_wb_dirty_exceeded(struct backing_dev_info *bdi) > +{ > + return bdi->wb.dirty_exceeded; > +} > + > +static inline void bdi_wb_stat_mod(struct backing_dev_info *bdi, > + enum wb_stat_item item, s64 amount) > +{ > + wb_stat_mod(&bdi->wb, item, amount); > +} > + > /* > * maximal error of a stat counter. > */ > -- > 2.25.1 > -- Jan Kara <[email protected]> SUSE Labs, CR _______________________________________________ Linux-f2fs-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
