1
0
mirror of https://github.com/ARM-software/workload-automation.git synced 2025-09-01 19:02:31 +01:00

Replaced active_cpus by online_cpus in common/linux/device.py

This commit is contained in:
Anthony Barbier
2017-06-14 14:25:17 +01:00
parent ae1a5019dc
commit ff67ed1697
2 changed files with 3 additions and 3 deletions

View File

@@ -518,10 +518,10 @@ class BaseLinuxDevice(Device): # pylint: disable=abstract-method
def get_number_of_online_cores(self, core):
if core not in self.core_names:
raise ValueError('Unexpected core: {}; must be in {}'.format(core, list(set(self.core_names))))
active_cpus = self.active_cpus
online_cpus = self.online_cpus
num_active_cores = 0
for i, c in enumerate(self.core_names):
if c == core and i in active_cpus:
if c == core and i in online_cpus:
num_active_cores += 1
return num_active_cores