[dm-devel] [PATCH v3 1/2] libmultipath: support host adapter name lookup for s390x ccw bus

Martin Wilck martin.wilck at suse.com
Tue Feb 15 20:43:55 UTC 2022


On Tue, 2022-02-15 at 20:45 +0100, Steffen Maier wrote:
> There are also (FCP) HBAs that appear on a bus different from PCI.
> 
> Complements v0.6.0 commit
> 01ab2a468ea2 ("libmultipath: Add additional path wildcards").
> 
> With that we can easily get the full FCP addressing triplet
> (HBA, WWPN, LUN) from multipath tools without additional tools
> and correlation:
> 
> $ multipathd -k'show paths format "%w|%i|%a|%r"'
> uuid                             |hcil       |host adapter|target
> WWPN
> 36005076400820293e8000000000000a0|1:0:3:160  |0.0.5080   
> |0x500507680b25c449
> 36005076400820293e8000000000000a0|1:0:4:160  |0.0.5080   
> |0x500507680b25c448
> 36005076400820293e8000000000000a0|58:0:3:160 |0.0.50c0   
> |0x500507680b26c449
> 36005076400820293e8000000000000a0|58:0:4:160 |0.0.50c0   
> |0x500507680b26c448
> 
>                                               ^^^^^^^^
>                                    instead of [undef]
> 
> Make helper function static and generalize it to also cover CCW bus
> in addition to the already supported PCI bus. Had to move now static
> helper in front of its only user.
> While at it, use string functions that are safe against buffer
> overflows.
> 
> As a side effect this patch theoretically also enables group by
> host adapter for s390x based on v0.6.0 commit a28e61e5cc9a
> ("Crafted ordering of child paths for round robin path selector").
> 
> Reviewed-by: Benjamin Block <bblock at linux.ibm.com>
> Signed-off-by: Steffen Maier <maier at linux.ibm.com>

Reviewed-by: Martin Wilck <mwilck at suse.com>






More information about the dm-devel mailing list