mirror of
https://gitee.com/bianbu-linux/linux-6.6
synced 2025-07-01 23:53:16 -04:00
bdi: Provide bdi_register_va() and bdi_alloc()
Add function that registers bdi and takes va_list instead of variable number of arguments. Add bdi_alloc() as simple wrapper for NUMA-unaware users allocating BDI. Reviewed-by: Christoph Hellwig <hch@lst.de> Signed-off-by: Jan Kara <jack@suse.cz> Signed-off-by: Jens Axboe <axboe@fb.com>
This commit is contained in:
parent
2bc19cd5fd
commit
baf7a616d5
2 changed files with 21 additions and 5 deletions
|
@ -30,6 +30,8 @@ void bdi_put(struct backing_dev_info *bdi);
|
|||
__printf(3, 4)
|
||||
int bdi_register(struct backing_dev_info *bdi, struct device *parent,
|
||||
const char *fmt, ...);
|
||||
int bdi_register_va(struct backing_dev_info *bdi, struct device *parent,
|
||||
const char *fmt, va_list args);
|
||||
int bdi_register_dev(struct backing_dev_info *bdi, dev_t dev);
|
||||
int bdi_register_owner(struct backing_dev_info *bdi, struct device *owner);
|
||||
void bdi_unregister(struct backing_dev_info *bdi);
|
||||
|
@ -37,6 +39,10 @@ void bdi_unregister(struct backing_dev_info *bdi);
|
|||
int __must_check bdi_setup_and_register(struct backing_dev_info *, char *);
|
||||
void bdi_destroy(struct backing_dev_info *bdi);
|
||||
struct backing_dev_info *bdi_alloc_node(gfp_t gfp_mask, int node_id);
|
||||
static inline struct backing_dev_info *bdi_alloc(gfp_t gfp_mask)
|
||||
{
|
||||
return bdi_alloc_node(gfp_mask, NUMA_NO_NODE);
|
||||
}
|
||||
|
||||
void wb_start_writeback(struct bdi_writeback *wb, long nr_pages,
|
||||
bool range_cyclic, enum wb_reason reason);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue