diff options
author | Alexander Motin <mav@FreeBSD.org> | 2017-01-20 13:49:04 +0000 |
---|---|---|
committer | Alexander Motin <mav@FreeBSD.org> | 2017-01-20 13:49:04 +0000 |
commit | d3fef0a0924fbb7ff7e29e208641e2993464dd40 (patch) | |
tree | 401c3855b61eba5976d45a43b5b9cd73554f5177 /sys/geom | |
parent | c468ff880a34801a99937c4b1e8dad1aeb5a134d (diff) | |
download | src-d3fef0a0924fbb7ff7e29e208641e2993464dd40.tar.gz src-d3fef0a0924fbb7ff7e29e208641e2993464dd40.zip |
Report disk addition errors on `add` or `create` subcommand.
MFC after: 1 week
Notes
Notes:
svn path=/head/; revision=312533
Diffstat (limited to 'sys/geom')
-rw-r--r-- | sys/geom/multipath/g_multipath.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/sys/geom/multipath/g_multipath.c b/sys/geom/multipath/g_multipath.c index b461747bf356..0c24cd35891b 100644 --- a/sys/geom/multipath/g_multipath.c +++ b/sys/geom/multipath/g_multipath.c @@ -923,6 +923,7 @@ g_multipath_ctl_add_name(struct gctl_req *req, struct g_class *mp, struct g_provider *pp; const char *mpname; static const char devpf[6] = "/dev/"; + int error; g_topology_assert(); @@ -972,10 +973,9 @@ g_multipath_ctl_add_name(struct gctl_req *req, struct g_class *mp, return; } - /* - * Now add.... - */ - (void) g_multipath_add_disk(gp, pp); + error = g_multipath_add_disk(gp, pp); + if (error != 0) + gctl_error(req, "Provider addition error: %d", error); } static void |