Changeset View
Changeset View
Standalone View
Standalone View
head/sys/geom/multipath/g_multipath.c
Show First 20 Lines • Show All 938 Lines • ▼ Show 20 Lines | |||||
g_multipath_ctl_add_name(struct gctl_req *req, struct g_class *mp, | g_multipath_ctl_add_name(struct gctl_req *req, struct g_class *mp, | ||||
const char *name) | const char *name) | ||||
{ | { | ||||
struct g_multipath_softc *sc; | struct g_multipath_softc *sc; | ||||
struct g_geom *gp; | struct g_geom *gp; | ||||
struct g_consumer *cp; | struct g_consumer *cp; | ||||
struct g_provider *pp; | struct g_provider *pp; | ||||
const char *mpname; | const char *mpname; | ||||
static const char devpf[6] = "/dev/"; | static const char devpf[6] = _PATH_DEV; | ||||
int error; | int error; | ||||
g_topology_assert(); | g_topology_assert(); | ||||
mpname = gctl_get_asciiparam(req, "arg0"); | mpname = gctl_get_asciiparam(req, "arg0"); | ||||
if (mpname == NULL) { | if (mpname == NULL) { | ||||
gctl_error(req, "No 'arg0' argument"); | gctl_error(req, "No 'arg0' argument"); | ||||
return; | return; | ||||
▲ Show 20 Lines • Show All 46 Lines • ▼ Show 20 Lines | |||||
static void | static void | ||||
g_multipath_ctl_prefer(struct gctl_req *req, struct g_class *mp) | g_multipath_ctl_prefer(struct gctl_req *req, struct g_class *mp) | ||||
{ | { | ||||
struct g_geom *gp; | struct g_geom *gp; | ||||
struct g_multipath_softc *sc; | struct g_multipath_softc *sc; | ||||
struct g_consumer *cp; | struct g_consumer *cp; | ||||
const char *name, *mpname; | const char *name, *mpname; | ||||
static const char devpf[6] = "/dev/"; | static const char devpf[6] = _PATH_DEV; | ||||
int *nargs; | int *nargs; | ||||
g_topology_assert(); | g_topology_assert(); | ||||
mpname = gctl_get_asciiparam(req, "arg0"); | mpname = gctl_get_asciiparam(req, "arg0"); | ||||
if (mpname == NULL) { | if (mpname == NULL) { | ||||
gctl_error(req, "No 'arg0' argument"); | gctl_error(req, "No 'arg0' argument"); | ||||
return; | return; | ||||
▲ Show 20 Lines • Show All 543 Lines • Show Last 20 Lines |