All of lore.kernel.org
 help / color / mirror / Atom feed
* [2.6.22-rc1 PATCH] dm-mpath: Add MP_RETRY_PG_INIT flag for hw handlers to tell dm-mpath to retry pg_init.
@ 2007-05-24  3:38 Dave Wysochanski
  0 siblings, 0 replies; only message in thread
From: Dave Wysochanski @ 2007-05-24  3:38 UTC (permalink / raw)
  To: device-mapper development

Add MP_RETRY_PG_INIT flag for hw handlers to tell dm-mpath to retry pg_init.
Useful for cases where a hw handler sends a path initialization command to
the storage and it completes with an error code indicating the command should
be retried.

Index: linux-2.6.22-rc1/drivers/md/dm-hw-handler.h
===================================================================
--- linux-2.6.22-rc1.orig/drivers/md/dm-hw-handler.h
+++ linux-2.6.22-rc1/drivers/md/dm-hw-handler.h
@@ -58,5 +58,6 @@ unsigned dm_scsi_err_handler(struct hw_h
 #define MP_FAIL_PATH 1
 #define MP_BYPASS_PG 2
 #define MP_ERROR_IO  4	/* Don't retry this I/O */
+#define MP_RETRY_PG_INIT 8
 
 #endif
Index: linux-2.6.22-rc1/drivers/md/dm-mpath.c
===================================================================
--- linux-2.6.22-rc1.orig/drivers/md/dm-mpath.c
+++ linux-2.6.22-rc1/drivers/md/dm-mpath.c
@@ -999,7 +999,9 @@ void dm_pg_init_complete(struct dm_path 
 		bypass_pg(m, pg, 1);
 
 	spin_lock_irqsave(&m->lock, flags);
-	if (err_flags) {
+	if (err_flags & MP_RETRY_PG_INIT)
+		m->pg_init_required = 1;
+	else if (err_flags) {
 		m->current_pgpath = NULL;
 		m->current_pg = NULL;
 	} else if (!m->pg_init_required)

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2007-05-24  3:38 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2007-05-24  3:38 [2.6.22-rc1 PATCH] dm-mpath: Add MP_RETRY_PG_INIT flag for hw handlers to tell dm-mpath to retry pg_init Dave Wysochanski

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.