]> git.ipfire.org Git - thirdparty/mdadm.git/commitdiff
imsm: Avoid duplicate entries in --detail-platform
authorRoman Sobanski <roman.sobanski@intel.com>
Mon, 13 Aug 2018 05:52:53 +0000 (07:52 +0200)
committerJes Sorensen <jsorensen@fb.com>
Thu, 27 Sep 2018 14:28:35 +0000 (10:28 -0400)
In some scenarios mdadm --detail-platform shows duplicated info about one
of controllers. Block it.

Signed-off-by: Roman Sobanski <roman.sobanski@intel.com>
Signed-off-by: Jes Sorensen <jsorensen@fb.com>
platform-intel.c

index a11101db3bfb7024466c2ff82310f1b1f215c1e3..04bffc57accf483a64e570db705b3865f8acfd93 100644 (file)
@@ -371,6 +371,9 @@ static int scan(const void *start, const void *end, const void *data)
        if (__le16_to_cpu(ptr->vendorID) != 0x8086)
                return 0;
 
+       if (get_orom_by_device_id(ptr->deviceID))
+               return 0;
+
        for (offset = 0; offset < len; offset += 4) {
                const void *mem = start + offset;