aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYaroslav Isakov <yaroslav.isakov@gmail.com>2016-02-22 17:17:57 +0300
committerNivedita Swaminathan <nivedita.swaminathan@intel.com>2016-03-24 12:26:09 -0700
commit44d78f9cc58c010b64c78d129fb8f1926f5d46bd (patch)
treec61c77a39b8b3a49cc19fb852d484e518b5c65d5
parentb13583520f2996aaa198321d157105fdad94bd88 (diff)
Fixed bug when all PCI devices usage is shown as 00%
-rw-r--r--src/devices/runtime_pm.cpp1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/devices/runtime_pm.cpp b/src/devices/runtime_pm.cpp
index ccfd945..26f9d32 100644
--- a/src/devices/runtime_pm.cpp
+++ b/src/devices/runtime_pm.cpp
@@ -194,6 +194,7 @@ static void do_bus(const char *bus)
if (entry->d_name[0] == '.')
continue;
+ snprintf(filename, sizeof(filename), "/sys/bus/%s/devices/%s", bus, entry->d_name);
dev = new class runtime_pmdevice(entry->d_name, filename);
if (strcmp(bus, "i2c") == 0) {