From d5786feede3b981a1f46a2eb59e231fe3e6f85f8 Mon Sep 17 00:00:00 2001 From: Jarrod Johnson Date: Mon, 26 Aug 2019 09:57:05 -0400 Subject: [PATCH] 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 --- pyghmi/redfish/command.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/pyghmi/redfish/command.py b/pyghmi/redfish/command.py index 041f8453..bc745dd7 100644 --- a/pyghmi/redfish/command.py +++ b/pyghmi/redfish/command.py @@ -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]