4728c8
---
4728c8
 libmultipath/print.c |   11 +++++++++++
4728c8
 1 file changed, 11 insertions(+)
4728c8
4728c8
Index: multipath-tools-130222/libmultipath/print.c
4728c8
===================================================================
4728c8
--- multipath-tools-130222.orig/libmultipath/print.c
4728c8
+++ multipath-tools-130222/libmultipath/print.c
4728c8
@@ -422,6 +422,16 @@ snprint_path_serial (char * buff, size_t
4728c8
 }
4728c8
 
4728c8
 static int
4728c8
+snprint_path_mpp (char * buff, size_t len, struct path * pp)
4728c8
+{
4728c8
+	if (!pp->mpp)
4728c8
+		return snprintf(buff, len, "[orphan]");
4728c8
+	if (!pp->mpp->alias)
4728c8
+		return snprintf(buff, len, "[unknown]");
4728c8
+	return snprint_str(buff, len, pp->mpp->alias);
4728c8
+}
4728c8
+
4728c8
+static int
4728c8
 snprint_path_checker (char * buff, size_t len, struct path * pp)
4728c8
 {
4728c8
 	struct checker * c = &pp->checker;
4728c8
@@ -464,6 +474,7 @@ struct path_data pd[] = {
4728c8
 	{'p', "pri",           0, snprint_pri},
4728c8
 	{'S', "size",          0, snprint_path_size},
4728c8
 	{'z', "serial",        0, snprint_path_serial},
4728c8
+	{'m', "multipath",     0, snprint_path_mpp},
4728c8
 	{0, NULL, 0 , NULL}
4728c8
 };
4728c8