The find_multipath_jbod is intended to return the alternate path
for the same device in a multipath configuration. However, it was
simply returning the first device that matched the device_id which
may have been the same device as the function parameter. This fixes
some issues and errors that can be seen when formatting JBOD disks.

Signed-off-by: Brian King <brk...@linux.vnet.ibm.com>
---

 iprlib.c |    3 +++
 1 file changed, 3 insertions(+)

diff -puN iprlib.c~iprutils_mpath_format_fix iprlib.c
--- iprutils.patched/iprlib.c~iprutils_mpath_format_fix 2016-07-20 
10:52:01.754919456 -0500
+++ iprutils.patched-bjking1/iprlib.c   2016-07-20 10:56:30.914265263 -0500
@@ -3736,6 +3736,9 @@ static struct ipr_dev *find_multipath_jb
                        continue;
 
                for_each_dev(ioa, multipath_dev) {
+                       if (multipath_dev == dev)
+                               continue;
+
                        if (multipath_dev->scsi_dev_data &&
                            id == multipath_dev->scsi_dev_data->device_id)
                                return multipath_dev;
_


------------------------------------------------------------------------------
What NetFlow Analyzer can do for you? Monitors network bandwidth and traffic
patterns at an interface-level. Reveals which users, apps, and protocols are 
consuming the most bandwidth. Provides multi-vendor support for NetFlow, 
J-Flow, sFlow and other flows. Make informed decisions using capacity planning
reports.http://sdm.link/zohodev2dev
_______________________________________________
Iprdd-devel mailing list
Iprdd-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/iprdd-devel

Reply via email to