提交 7552750d 编写于 作者: M Michał Mirosław 提交者: Mike Snitzer

dm table: log table creation error code

Help debugging table creation errors by adding the error name in the log.
Signed-off-by: NMichał Mirosław <mirq-linux@rere.qmqm.pl>
Signed-off-by: NMike Snitzer <snitzer@redhat.com>
上级 c7c879ee
......@@ -706,7 +706,7 @@ int dm_table_add_target(struct dm_table *t, const char *type,
r = dm_split_args(&argc, &argv, params);
if (r) {
tgt->error = "couldn't split parameters (insufficient memory)";
tgt->error = "couldn't split parameters";
goto bad;
}
......@@ -724,7 +724,7 @@ int dm_table_add_target(struct dm_table *t, const char *type,
return 0;
bad:
DMERR("%s: %s: %s", dm_device_name(t->md), type, tgt->error);
DMERR("%s: %s: %s (%pe)", dm_device_name(t->md), type, tgt->error, ERR_PTR(r));
dm_put_target_type(tgt->type);
return r;
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册