linux-block.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2] bdi: show error log when fail to create bdi debugfs entry
@ 2018-01-10 16:36 weiping zhang
  2018-01-19 17:36 ` weiping zhang
  0 siblings, 1 reply; 4+ messages in thread
From: weiping zhang @ 2018-01-10 16:36 UTC (permalink / raw)
  To: axboe, jack, Bart.VanAssche; +Cc: linux-block

bdi debugfs dir/file may create fail, add error log here.

Signed-off-by: weiping zhang <zhangweiping@didichuxing.com>
---
V1->V2:
fix indentation and make log message more clear

 mm/backing-dev.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/mm/backing-dev.c b/mm/backing-dev.c
index b5f940c..0a49665 100644
--- a/mm/backing-dev.c
+++ b/mm/backing-dev.c
@@ -885,7 +885,9 @@ int bdi_register_va(struct backing_dev_info *bdi, const char *fmt, va_list args)
 	cgwb_bdi_register(bdi);
 	bdi->dev = dev;
 
-	bdi_debug_register(bdi, dev_name(dev));
+	if (bdi_debug_register(bdi, dev_name(dev)))
+		pr_warn("blkdev %s: creation of bdi debugfs entries failed.\n",
+			dev_name(dev));
 	set_bit(WB_registered, &bdi->wb.state);
 
 	spin_lock_bh(&bdi_lock);
-- 
2.9.4

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2018-01-20  0:09 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-01-10 16:36 [PATCH v2] bdi: show error log when fail to create bdi debugfs entry weiping zhang
2018-01-19 17:36 ` weiping zhang
2018-01-19 19:54   ` Jens Axboe
2018-01-20  0:09     ` weiping zhang

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).