Skip to contentSkip to conversation

multipath: fix select_no_path_retry for flushing devices.

PATCH Applied Benjamin Marzinski 2 participants 2 messages May 18, 2012 – May 20, 2012 Device mapper

lore
Share & tools
lore

Benjamin Marzinski

author maintainer
#0 lore raw

PATCH 1/1 multipath: fix select_no_path_retry for flushing devices.

The select_no_path_retry code was falling through if a flush was in progress, and so it wasn't honoring flush_on_last_del.

---
 libmultipath/propsel.c |    1 +
 1 file changed, 1 insertion(+)
libmultipath/propsel.c +1 -0
Index: multipath-tools-120403/libmultipath/propsel.c
===================================================================
@@ -415,6 +415,7 @@ select_no_path_retry(struct multipath *m
 	if (mp->flush_on_last_del == FLUSH_IN_PROGRESS) {
 		condlog(0, "flush_on_last_del in progress");
 		mp->no_path_retry = NO_PATH_RETRY_FAIL;
+		return 0;
 	}
 	if (mp->mpe && mp->mpe->no_path_retry != NO_PATH_RETRY_UNDEF) {
 		mp->no_path_retry = mp->mpe->no_path_retry;
#1 lore raw
Quoted 3 lines · Benjamin Marzinski

The select_no_path_retry code was falling through if a flush was in progress, and so it wasn't honoring flush_on_last_del.

Applied.

Quoted 17 lines
---
 libmultipath/propsel.c |    1 +
 1 file changed, 1 insertion(+)

Index: multipath-tools-120403/libmultipath/propsel.c
===================================================================

libmultipath/propsel.c +1 -0
@@ -415,6 +415,7 @@ select_no_path_retry(struct multipath *m
 	if (mp->flush_on_last_del == FLUSH_IN_PROGRESS) {
 		condlog(0, "flush_on_last_del in progress");
 		mp->no_path_retry = NO_PATH_RETRY_FAIL;
+		return 0;
 	}
 	if (mp->mpe && mp->mpe->no_path_retry != NO_PATH_RETRY_UNDEF) {
 		mp->no_path_retry = mp->mpe->no_path_retry;