From: Martin Wilck <[email protected]>

Recent changes in sg3_utils have changed the way certain WWIDs are presented to
the system. This may lead to maps not being set up or even being destroyed
or removed. Fix this by "unmangling" the WWIDs similar to libdevmapper.

The main part of this series is patch 2/4, it's commit message contains
detailed information. Patch 3 adds tests for the unmangling functionality.

Patch 1 is a small prerequisite. Patch 4 is an optimization that occured
to me while looking at wwids.c.

Comments and questions welcome!

Martin

Martin Wilck (4):
  libmultipath: constify functions in wwid.c
  libmultipath: unmangle WWIDs if necessary
  multipath-tools tests: add test for WWID unmangling
  libmultipath: use mmap in lookup_wwid()

 libmultipath/discovery.c | 103 ++++++++++-
 libmultipath/discovery.h |   1 +
 libmultipath/wwids.c     |  82 ++++-----
 libmultipath/wwids.h     |   6 +-
 tests/Makefile           |   5 +-
 tests/cmocka-compat.h    |   1 +
 tests/wwid-unmangle.c    | 375 +++++++++++++++++++++++++++++++++++++++
 7 files changed, 523 insertions(+), 50 deletions(-)
 create mode 100644 tests/wwid-unmangle.c

-- 
2.55.0


Reply via email to