+ if (path_discovery(pathvec, conf, DI_SYSFS | DI_CHECKER))
+ goto out1;
+
/* get info of all paths from the dm device */
if (get_mpvec (curmp, pathvec, alias)){
condlog(0, "%s: failed to get device info.", alias);
@@ -260,11 +263,14 @@ int mpath_persistent_reserve_out ( int f
goto out;
}
+ if (path_discovery(pathvec, conf, DI_SYSFS | DI_CHECKER))
+ goto out1;
+
/* get info of all paths from the dm device */
if (get_mpvec(curmp, pathvec, alias)){
condlog(0, "%s: failed to get device info.", alias);
ret = MPATH_PR_DMMP_ERROR;
- goto out;
+ goto out1;
}
int
-set_handler_callback (int fp, int (*fn)(void *, char **, int *, void *))
+set_handler_callback (unsigned long fp, int (*fn)(void *, char **, int *, void *))
{
struct handler * h = find_handler(fp);
@@ -291,11 +291,11 @@ out:
return r;
}
-static int
+static unsigned long
fingerprint(vector vec)
{
int i;
- int fp = 0;
+ unsigned long fp = 0;
struct key * kw;
if (!vec)
@@ -335,7 +335,7 @@ static char *
genhelp_handler (void)
{
int i, j;
- int fp;
+ unsigned long fp;
struct handler * h;
struct key * kw;
char * reply;
@@ -402,7 +402,7 @@ parse_cmd (char * cmd, char ** reply, in
}
char *
-get_keyparam (vector v, int code)
+get_keyparam (vector v, unsigned long code)
{
struct key * kw;
int i;
@@ -471,7 +471,7 @@ void cli_exit(void)
}
static int
-key_match_fingerprint (struct key * kw, int fp)
+key_match_fingerprint (struct key * kw, unsigned long fp)
{
if (!fp)
return 0;
@@ -485,7 +485,8 @@ key_match_fingerprint (struct key * kw,
char *
key_generator (const char * str, int state)
{
- static int index, len, rlfp, has_param;
+ static int index, len, has_param;
+ static unsigned long rlfp;
struct key * kw;
int i;
struct handler *h;
@@ -555,7 +556,7 @@ key_generator (const char * str, int sta
* nfp is the candidate fingerprint we try to
* validate against all known command fingerprints.
*/
- int nfp = rlfp | kw->code;
+ unsigned long nfp = rlfp | kw->code;
vector_foreach_slot(handlers, h, i) {
if (!rlfp || ((h->fingerprint & nfp) == nfp)) {
/*
diff -uprN multipath-tools-14jan-upstream-patchedall-2nd/multipathd/cli.h multipath-tools/multipathd/cli.h
--- multipath-tools-14jan-upstream-patchedall-2nd/multipathd/cli.h 2012-01-12 12:24:09.000000000 -0500
+++ multipath-tools/multipathd/cli.h 2012-01-16 09:33:49.000000000 -0500
@@ -65,16 +65,16 @@ enum {
#define WILDCARDS (1 << __WILDCARDS)
#define QUIT (1 << __QUIT)
#define SHUTDOWN (1 << __SHUTDOWN)
-#define GETPRSTATUS (1 << __GETPRSTATUS)
-#define SETPRSTATUS (1 << __SETPRSTATUS)
-#define UNSETPRSTATUS (1 << __UNSETPRSTATUS)
+#define GETPRSTATUS (1UL << __GETPRSTATUS)
+#define SETPRSTATUS (1UL << __SETPRSTATUS)
+#define UNSETPRSTATUS (1UL << __UNSETPRSTATUS)