From 06208f2330fb32e6226f12bc79da8aa5b9b7d91d Mon Sep 17 00:00:00 2001 From: bolv Date: Sat, 25 May 2019 21:00:04 +0800 Subject: [PATCH] Fix bmc update failed in V1.2.5 --- .../plugins/fwmgrutil.py | 11 ++++++++--- .../plugins/fwmgrutil.py | 11 ++++++++--- .../plugins/fwmgrutil.py | 11 ++++++++--- 3 files changed, 24 insertions(+), 9 deletions(-) diff --git a/device/alibaba/x86_64-alibaba_as13-32h-cl-r0/plugins/fwmgrutil.py b/device/alibaba/x86_64-alibaba_as13-32h-cl-r0/plugins/fwmgrutil.py index 1da9228ceee..74cf3572438 100644 --- a/device/alibaba/x86_64-alibaba_as13-32h-cl-r0/plugins/fwmgrutil.py +++ b/device/alibaba/x86_64-alibaba_as13-32h-cl-r0/plugins/fwmgrutil.py @@ -322,9 +322,14 @@ def firmware_upgrade(self, fw_type, fw_path, fw_extra=None): if fw_extra_str == "pingpong": print("Switch to boot from %s" % flash) self.set_bmc_boot_flash(flash) - print("Rebooting BMC.....") - if not self.reboot_bmc(): - return False + print("Rebooting BMC.....") + if not self.reboot_bmc(): + return False + else: + print("Rebooting BMC in old fashion.....") + reboot_dict = {} + reboot_dict["reboot"] = "yes" + r = requests.post(self.bmc_info_url, json=reboot_dict) print("Done") else: print("Failed: Unable to install BMC image") diff --git a/device/alibaba/x86_64-alibaba_as13-48f8h-cl-r0/plugins/fwmgrutil.py b/device/alibaba/x86_64-alibaba_as13-48f8h-cl-r0/plugins/fwmgrutil.py index d70730fe8ee..abecfdcf298 100644 --- a/device/alibaba/x86_64-alibaba_as13-48f8h-cl-r0/plugins/fwmgrutil.py +++ b/device/alibaba/x86_64-alibaba_as13-48f8h-cl-r0/plugins/fwmgrutil.py @@ -322,9 +322,14 @@ def firmware_upgrade(self, fw_type, fw_path, fw_extra=None): if fw_extra_str == "pingpong": print("Switch to boot from %s" % flash) self.set_bmc_boot_flash(flash) - print("Rebooting BMC.....") - if not self.reboot_bmc(): - return False + print("Rebooting BMC.....") + if not self.reboot_bmc(): + return False + else: + print("Rebooting BMC in old fashion.....") + reboot_dict = {} + reboot_dict["reboot"] = "yes" + r = requests.post(self.bmc_info_url, json=reboot_dict) print("Done") else: print("Failed: Unable to install BMC image") diff --git a/device/alibaba/x86_64-alibaba_as23-128h-cl-r0/plugins/fwmgrutil.py b/device/alibaba/x86_64-alibaba_as23-128h-cl-r0/plugins/fwmgrutil.py index 04bd0f1305c..4ccc2fe040e 100644 --- a/device/alibaba/x86_64-alibaba_as23-128h-cl-r0/plugins/fwmgrutil.py +++ b/device/alibaba/x86_64-alibaba_as23-128h-cl-r0/plugins/fwmgrutil.py @@ -322,9 +322,14 @@ def firmware_upgrade(self, fw_type, fw_path, fw_extra=None): if fw_extra_str == "pingpong": print("Switch to boot from %s" % flash) self.set_bmc_boot_flash(flash) - print("Rebooting BMC.....") - if not self.reboot_bmc(): - return False + print("Rebooting BMC.....") + if not self.reboot_bmc(): + return False + else: + print("Rebooting BMC in old fashion.....") + reboot_dict = {} + reboot_dict["reboot"] = "yes" + r = requests.post(self.bmc_info_url, json=reboot_dict) print("Done") else: print("Failed: Unable to install BMC image")