mirror of
https://opendev.org/x/pyghmi
synced 2025-07-24 05:01:10 +00:00
Implement state feedback on firmware update
Provide a means to indicate through string return to show user what the next step should be. Change-Id: Id6b9c2bb6e6a46d6eb653622294ae93e858b8356
This commit is contained in:
@@ -1779,7 +1779,7 @@ class Command(object):
|
||||
self.oem_init()
|
||||
if progress is None:
|
||||
progress = lambda x: True
|
||||
self._oem.update_firmware(file, data, progress)
|
||||
return self._oem.update_firmware(file, data, progress)
|
||||
|
||||
def attach_remote_media(self, url, username=None, password=None):
|
||||
"""Attach remote media by url
|
||||
|
@@ -840,8 +840,8 @@ class OEMHandler(generic.OEMHandler):
|
||||
if self.is_fpc:
|
||||
return self.smmhandler.update_firmware(
|
||||
filename, data=data, progress=progress)
|
||||
super(OEMHandler, self).update_firmware(filename, data=data,
|
||||
progress=progress)
|
||||
return super(OEMHandler, self).update_firmware(filename, data=data,
|
||||
progress=progress)
|
||||
|
||||
def detach_remote_media(self):
|
||||
if self.has_imm:
|
||||
|
@@ -630,3 +630,4 @@ class XCCClient(IMMClient):
|
||||
raise Exception(
|
||||
'Unknown condition waiting for '
|
||||
'firmware update: ' + repr(rsp))
|
||||
return 'pending'
|
||||
|
@@ -314,6 +314,7 @@ class SMMClient(object):
|
||||
progress({'phase': 'apply',
|
||||
'progress': percent})
|
||||
complete = percent >= 100.0
|
||||
return 'complete'
|
||||
|
||||
def logout(self):
|
||||
self.wc.request('POST', '/data/logout', None)
|
||||
|
Reference in New Issue
Block a user