From: mwilck@suse.com
To: lixiaokeng@huawei.com
Cc: Martin Wilck <mwilck@suse.com>,
dm-devel@redhat.com, Zhiqiang Liu <liuzhiqiang26@huawei.com>
Subject: [PATCH 1/3] libmultipath: update_multipath_table(): add flags argument
Date: Fri, 21 Aug 2020 15:54:16 +0200 [thread overview]
Message-ID: <20200821135418.28138-2-mwilck@suse.com> (raw)
In-Reply-To: <20200821135418.28138-1-mwilck@suse.com>
From: Martin Wilck <mwilck@suse.com>
... to be passed to update_pathvec_from_dm().
Signed-off-by: Martin Wilck <mwilck@suse.com>
---
libmultipath/structs_vec.c | 6 +++---
libmultipath/structs_vec.h | 2 +-
multipathd/main.c | 4 ++--
3 files changed, 6 insertions(+), 6 deletions(-)
diff --git a/libmultipath/structs_vec.c b/libmultipath/structs_vec.c
index cc2dafa..3d4f855 100644
--- a/libmultipath/structs_vec.c
+++ b/libmultipath/structs_vec.c
@@ -406,7 +406,7 @@ extract_hwe_from_path(struct multipath * mpp)
}
int
-update_multipath_table (struct multipath *mpp, vector pathvec)
+update_multipath_table (struct multipath *mpp, vector pathvec, int flags)
{
int r = DMP_ERR;
char params[PARAMS_SIZE] = {0};
@@ -426,7 +426,7 @@ update_multipath_table (struct multipath *mpp, vector pathvec)
}
/* FIXME: we should deal with the return value here */
- update_pathvec_from_dm(pathvec, mpp, 0);
+ update_pathvec_from_dm(pathvec, mpp, flags);
return DMP_OK;
}
@@ -532,7 +532,7 @@ update_multipath_strings(struct multipath *mpp, vector pathvec)
free_pgvec(mpp->pg, KEEP_PATHS);
mpp->pg = NULL;
- r = update_multipath_table(mpp, pathvec);
+ r = update_multipath_table(mpp, pathvec, 0);
if (r != DMP_OK)
return r;
sync_paths(mpp, pathvec);
diff --git a/libmultipath/structs_vec.h b/libmultipath/structs_vec.h
index 39cb074..478168f 100644
--- a/libmultipath/structs_vec.h
+++ b/libmultipath/structs_vec.h
@@ -39,7 +39,7 @@ struct multipath * add_map_with_path (struct vectors * vecs,
struct path * pp, int add_vec);
void update_queue_mode_del_path(struct multipath *mpp);
void update_queue_mode_add_path(struct multipath *mpp);
-int update_multipath_table (struct multipath *mpp, vector pathvec);
+int update_multipath_table (struct multipath *mpp, vector pathvec, int flags);
int update_multipath_status (struct multipath *mpp);
vector get_used_hwes(const struct _vector *pathvec);
diff --git a/multipathd/main.c b/multipathd/main.c
index 9f12a57..b8019ec 100644
--- a/multipathd/main.c
+++ b/multipathd/main.c
@@ -552,7 +552,7 @@ add_map_without_path (struct vectors *vecs, const char *alias)
mpp->mpe = find_mpe(conf->mptable, mpp->wwid);
put_multipath_config(conf);
- if (update_multipath_table(mpp, vecs->pathvec) != DMP_OK)
+ if (update_multipath_table(mpp, vecs->pathvec, 0) != DMP_OK)
goto out;
if (update_multipath_status(mpp) != DMP_OK)
goto out;
@@ -1412,7 +1412,7 @@ map_discovery (struct vectors * vecs)
return 1;
vector_foreach_slot (vecs->mpvec, mpp, i)
- if (update_multipath_table(mpp, vecs->pathvec) != DMP_OK ||
+ if (update_multipath_table(mpp, vecs->pathvec, 0) != DMP_OK ||
update_multipath_status(mpp) != DMP_OK) {
remove_map(mpp, vecs, 1);
i--;
--
2.28.0
next prev parent reply other threads:[~2020-08-21 13:54 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-08-21 13:54 [PATCH 0/3] discard broken maps in get_dm_mpvec mwilck
2020-08-21 13:54 ` mwilck [this message]
2020-08-21 13:54 ` [PATCH 2/3] libmultipath: remove_map(): separate pathvec and mpvec arguments mwilck
2020-08-21 13:54 ` [PATCH 3/3] multipath: get_dm_mpvec: discard broken maps mwilck
2020-09-28 6:54 ` lixiaokeng
2020-08-21 18:57 ` [PATCH 0/3] discard broken maps in get_dm_mpvec Benjamin Marzinski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20200821135418.28138-2-mwilck@suse.com \
--to=mwilck@suse.com \
--cc=dm-devel@redhat.com \
--cc=liuzhiqiang26@huawei.com \
--cc=lixiaokeng@huawei.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).