]> git.openfabrics.org - ~adrianc/mstflint.git/commitdiff
mtcr: mtcr_ul/mtcr.h set pci.conf_dev as the default device (copy pci.conf_dev to...
authorSami Salloum <sami@mellanox.com>
Tue, 30 Apr 2013 18:45:00 +0000 (18:45 +0000)
committerOren Kladnitsky <orenk@dev.mellanox.co.il>
Sun, 4 Aug 2013 13:29:54 +0000 (16:29 +0300)
include/mtcr_ul/mtcr.h

index 16fcc308adf3972e2ee3f14c110ba9e6cbc3e08f..9364e8ae646c74e8d8039ad4699df5807e948fb1 100644 (file)
@@ -875,9 +875,10 @@ dev_info* mdevices_info(int mask, int* len)
         dev_info_arr[i].pci.subsys_id = __le32_to_cpu(conf_header_32p[11]) >> 16;
         dev_info_arr[i].pci.subsys_vend_id = __le32_to_cpu(conf_header_32p[11]) & 0xffff;
 
-        // set conf device
+        // set pci conf device
         snprintf(dev_info_arr[i].pci.conf_dev, sizeof(dev_info_arr[i].pci.conf_dev), "/sys/bus/pci/devices/%04x:%02x:%02x.%x/config", domain, bus,dev, func);
-
+        //Copy to dev_name as default device
+        snprintf(dev_info_arr[i].dev_name, sizeof(dev_info_arr[i].dev_name), "/sys/bus/pci/devices/%04x:%02x:%02x.%x/config", domain, bus,dev, func);
 
 next:
         dev_name += strlen(dev_name) + 1;