2
0
mirror of https://opendev.org/x/pyghmi synced 2025-01-15 04:07:48 +00:00

Support report settings on read-only BIOS

Some redfish implementations support reporting the current
settings, but not changing them.

Support these platforms in an expected way.

Change-Id: Iacce6f35019516b57b5de171044653c96a05a892
This commit is contained in:
Jarrod Johnson 2019-08-26 09:57:05 -04:00
parent 414baadea2
commit d5786feede

View File

@ -887,7 +887,10 @@ class Command(object):
reginfo = self._get_biosreg(reguri)
extrainfo, valtodisplay, _, self.attrdeps = reginfo
currsettings = {}
pendingsettings = self._do_web_request(self._setbiosurl)
try:
pendingsettings = self._do_web_request(self._setbiosurl)
except exc.UnsupportedFunctionality:
pendingsettings = {}
pendingsettings = pendingsettings.get('Attributes', {})
for setting in biosinfo.get('Attributes', {}):
val = biosinfo['Attributes'][setting]