aboutsummaryrefslogtreecommitdiff
path: root/sys/geom
diff options
context:
space:
mode:
authorXin LI <delphij@FreeBSD.org>2020-07-09 08:00:46 +0000
committerXin LI <delphij@FreeBSD.org>2020-07-09 08:00:46 +0000
commitb23a7fbaab633193caf11799f36eed4dc86b3fb0 (patch)
tree70bc4685e449f51f4ec73f95b0c3558f7e298483 /sys/geom
parent9093286b6ab680505bf26c92d5c7fdf65607f40c (diff)
downloadsrc-b23a7fbaab633193caf11799f36eed4dc86b3fb0.tar.gz
src-b23a7fbaab633193caf11799f36eed4dc86b3fb0.zip
g_concat_find_device: trim /dev/ if it is present, like other GEOM
classes. Reviewed by: cem MFC after: 2 weeks Differential Revision: https://reviews.freebsd.org/D25596
Notes
Notes: svn path=/head/; revision=363036
Diffstat (limited to 'sys/geom')
-rw-r--r--sys/geom/concat/g_concat.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/sys/geom/concat/g_concat.c b/sys/geom/concat/g_concat.c
index 8e5f3c551dd0..63f3cbee82b7 100644
--- a/sys/geom/concat/g_concat.c
+++ b/sys/geom/concat/g_concat.c
@@ -897,6 +897,9 @@ g_concat_find_device(struct g_class *mp, const char *name)
struct g_concat_softc *sc;
struct g_geom *gp;
+ if (strncmp(name, _PATH_DEV, strlen(_PATH_DEV)) == 0)
+ name += strlen(_PATH_DEV);
+
LIST_FOREACH(gp, &mp->geom, geom) {
sc = gp->softc;
if (sc == NULL)