@@ -125,7 +125,7 @@ find_hwe (vector hwtable, char * vendor, char * product, char * revision)
}
extern struct mpentry *
-find_mpe (char * wwid)
+find_mpe (vector mptable, char * wwid)
{
int i;
struct mpentry * mpe;
@@ -133,7 +133,7 @@ find_mpe (char * wwid)
if (!wwid)
return NULL;
- vector_foreach_slot (conf->mptable, mpe, i)
+ vector_foreach_slot (mptable, mpe, i)
if (mpe->wwid && !strcmp(mpe->wwid, wwid))
return mpe;
@@ -141,7 +141,7 @@ find_mpe (char * wwid)
}
extern char *
-get_mpe_wwid (char * alias)
+get_mpe_wwid (vector mptable, char * alias)
{
int i;
struct mpentry * mpe;
@@ -149,7 +149,7 @@ get_mpe_wwid (char * alias)
if (!alias)
return NULL;
- vector_foreach_slot (conf->mptable, mpe, i)
+ vector_foreach_slot (mptable, mpe, i)
if (mpe->alias && strcmp(mpe->alias, alias) == 0)
return mpe->wwid;
@@ -179,8 +179,8 @@ struct config {
struct config * conf;
struct hwentry * find_hwe (vector hwtable, char * vendor, char * product, char *revision);
-struct mpentry * find_mpe (char * wwid);
-char * get_mpe_wwid (char * alias);
+struct mpentry * find_mpe (vector mptable, char * wwid);
+char * get_mpe_wwid (vector mptable, char * alias);
struct hwentry * alloc_hwe (void);
struct mpentry * alloc_mpe (void);
@@ -1042,7 +1042,7 @@ get_refwwid (char * dev, enum devtypes dev_type, vector pathvec, char **wwid)
/*
* or may be an alias
*/
- refwwid = get_mpe_wwid(dev);
+ refwwid = get_mpe_wwid(conf->mptable, dev);
/*
* or directly a wwid
@@ -409,7 +409,7 @@ select_prio (struct path * pp)
goto out;
}
}
- mpe = find_mpe(pp->wwid);
+ mpe = find_mpe(conf->mptable, pp->wwid);
set_prio(mpe, "(LUN setting)");
set_prio(conf->overrides, "(overrides setting)");
set_prio(pp->hwe, "controller setting)");
@@ -385,7 +385,7 @@ __setup_multipath (struct vectors * vecs, struct multipath * mpp, int reset)
}
set_multipath_wwid(mpp);
- mpp->mpe = find_mpe(mpp->wwid);
+ mpp->mpe = find_mpe(conf->mptable, mpp->wwid);
condlog(3, "%s: discover", mpp->alias);
if (!mpp->hwe)
@@ -469,7 +469,7 @@ add_map_with_path (struct vectors * vecs,
if (!(mpp = alloc_multipath()))
return NULL;
- mpp->mpe = find_mpe(pp->wwid);
+ mpp->mpe = find_mpe(conf->mptable, pp->wwid);
mpp->hwe = pp->hwe;
strcpy(mpp->wwid, pp->wwid);
Signed-off-by: Hannes Reinecke <hare@suse.com> --- libmultipath/config.c | 8 ++++---- libmultipath/config.h | 4 ++-- libmultipath/configure.c | 2 +- libmultipath/propsel.c | 2 +- libmultipath/structs_vec.c | 4 ++-- 5 files changed, 10 insertions(+), 10 deletions(-)