Skip to content

Commit

Permalink
Merge pull request #449 from PavamanSubramaniyam/EnergyScale_P9_platf…
Browse files Browse the repository at this point in the history
…orms

Adding power limit support for P9 platforms
  • Loading branch information
stewartsmith authored Mar 18, 2019
2 parents bfb9290 + 120b8db commit 827e664
Show file tree
Hide file tree
Showing 3 changed files with 15 additions and 1 deletion.
2 changes: 1 addition & 1 deletion OpTestConfiguration.py
Original file line number Diff line number Diff line change
Expand Up @@ -263,7 +263,7 @@ def get_parser():

hostgroup.add_argument("--platform",
help="Platform (used for EnergyScale tests)",
choices=['unknown','habanero','firestone','garrison','firenze','p9dsu'])
choices=['unknown','habanero','firestone','garrison','firenze','p9dsu','witherspoon'])

osgroup = parser.add_argument_group('OS Images', 'OS Images to boot/install')
osgroup.add_argument("--os-cdrom", help="OS CD/DVD install image", default=None)
Expand Down
8 changes: 8 additions & 0 deletions common/OpTestConstants.py
Original file line number Diff line number Diff line change
Expand Up @@ -42,6 +42,9 @@ class OpTestConstants():
FIRESTONE = "firestone"
PALMETTO = "palmetto"
GARRISON = 'garrison'
P9DSU = "p9dsu"
WITHERSPOON = "witherspoon"


# Platform power limits in watts for different platforms taken from MRW xml file
HABANERO_POWER_LIMIT_LOW = "1000"
Expand All @@ -50,6 +53,11 @@ class OpTestConstants():
FIRESTONE_POWER_LIMIT_HIGH = "1820"
GARRISON_POWER_LIMIT_LOW = "1240"
GARRISON_POWER_LIMIT_HIGH = "2880"
P9DSU_POWER_LIMIT_LOW = "1550"
P9DSU_POWER_LIMIT_HIGH = "1650"
WITHERSPOON_POWER_LIMIT_LOW = "1550"
WITHERSPOON_POWER_LIMIT_HIGH = "3050"


PRIMARY_SIDE = "0x0080"
GOLDEN_SIDE = "0x0180"
Expand Down
6 changes: 6 additions & 0 deletions testcases/OpTestEnergyScale.py
Original file line number Diff line number Diff line change
Expand Up @@ -80,6 +80,12 @@ def get_platform_power_limits(self, i_platform):
elif BMC_CONST.GARRISON in l_platform:
l_power_limit_high = BMC_CONST.GARRISON_POWER_LIMIT_HIGH
l_power_limit_low = BMC_CONST.GARRISON_POWER_LIMIT_LOW
elif BMC_CONST.WITHERSPOON in l_platform:
l_power_limit_high = BMC_CONST.WITHERSPOON_POWER_LIMIT_HIGH
l_power_limit_low = BMC_CONST.WITHERSPOON_POWER_LIMIT_LOW
elif BMC_CONST.P9DSU in l_platform:
l_power_limit_high = BMC_CONST.P9DSU_POWER_LIMIT_HIGH
l_power_limit_low = BMC_CONST.P9DSU_POWER_LIMIT_LOW
else:
l_msg = "New platform, add power limit support to this platform and retry"
raise OpTestError(l_msg)
Expand Down

0 comments on commit 827e664

Please sign in to comment.