iprutils: on PowerNV, some of IOAs showed the wrong physical location
With iprutils 2.4.2 in PowerNV system, sometime some of IOAs still showed the wrong phyiscal location. This patch fixes the issue. signed-off-by: Wen Xiong<wenxiong@linux.vnet.ibm.com>
This commit is contained in:
parent
d70af62b5b
commit
ed25e2a520
1 changed files with 2 additions and 0 deletions
2
iprlib.c
2
iprlib.c
|
|
@ -1940,6 +1940,7 @@ static void ipr_get_pci_slots()
|
|||
ioa->physical_location[0] = '\0';
|
||||
|
||||
for_each_ioa(ioa) {
|
||||
memset(devspec, 0, sizeof(devspec));
|
||||
sprintf(attr, "/sys/bus/pci/devices/%s/devspec",
|
||||
ioa->pci_address);
|
||||
rc = read_attr_file(attr, devspec, PATH_MAX);
|
||||
|
|
@ -1947,6 +1948,7 @@ static void ipr_get_pci_slots()
|
|||
if (rc)
|
||||
continue;
|
||||
|
||||
memset(loc_code, 0, sizeof(loc_code));
|
||||
sprintf(locpath, "/proc/device-tree%s/ibm,loc-code",
|
||||
devspec);
|
||||
rc = read_attr_file(locpath, loc_code,
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue