Skip to content

Commit

Permalink
fby35: gl: Do 12V cycle after BIOS update
Browse files Browse the repository at this point in the history
Summary:
# Description:
Do 12V cycle after BIOS update no matter success or fail

# Motivation:
If doing Flash OOB update reboot at S5, system failed to reboot by 4S PBO

X-link: facebookexternal/openbmc.wiwynn#2807

Test Plan:
Do BIOS FW update

# Test Log:
root@bmc-oob:~# power-util slot3 status
Power status for fru 3 : ON
root@bmc-oob:~# fw-util slot3 --force --update bios Y35GLE08.bin Checking if the server is ready...
Wrong firmware image component.
Force powering off the server
slot_id: 3, comp: c, intf: 0, img: Y35GLE08.bin, force: 1 Init libusb Successful!
1d6b:0104 (bus 1, device 5) path: 1.3.4
Manufactured : ZEPHYR
Product : Zephyr CDC ACM
----------------------------------------
Device Descriptors:
Vendor ID : 1d6b
Product ID : 104
Serial Number : 3
Size of Device Descriptor : 18
Type of Descriptor : 1
USB Specification Release Number : 512
Device Release Number : 518
Device Class : 0
Device Sub-Class : 0
Device Protocol : 0
Max. Packet Size : 64
No. of Configuraions : 1
Configured value : 1
Claimed Interface: 1, EP addr: 0x03
-----------------------------------

Interface Descriptors:
  Number of Interfaces : 0x2
  Length : 0x9
  Desc_Type : 0x2
  Config_index : 0x0
  Total length : 75
  Configuration Value  : 0x1
  Configuration Attributes : 0xc0
  MaxPower(mA) : 50
    Interface:
      bInterfaceNumber:   0
      bAlternateSetting:  0
      bNumEndpoints:      1
      bInterfaceClass:    2
      bInterfaceSubClass: 2
      bInterfaceProtocol: 0
      iInterface:         0

      EndPoint Descriptors:
        bLength: 7
        bDescriptorType: 0x5
        bEndpointAddress: 0x81
        Maximum Packet Size: 0x10
        bmAttributes: 0x3
        bInterval: 0xa
-----------------------------------
    Interface:
      bInterfaceNumber:   1
      bAlternateSetting:  0
      bNumEndpoints:      2
      bInterfaceClass:    10
      bInterfaceSubClass: 0
      bInterfaceProtocol: 0
      iInterface:         0

      EndPoint Descriptors:
        bLength: 7
        bDescriptorType: 0x5
        bEndpointAddress: 0x82
        Maximum Packet Size: 0x40
        bmAttributes: 0x2
        bInterval: 0x0
      EndPoint Descriptors:
        bLength: 7
        bDescriptorType: 0x5
        bEndpointAddress: 0x3
        Maximum Packet Size: 0x40
        bmAttributes: 0x2
        bInterval: 0x0
-----------------------------------
Checksum function is unavailable, disabling deduplication and verification. Updating BIOS, dedup is off, verification is off.
1024 blocks (1024 written, 0 skipped)...finished.
Elapsed time:  437   sec.
12V-cycling the server for GL...
Force upgrade of slot3 : bios succeeded
root@bmc-oob:~# power-util slot3 status
Power status for fru 3 : ON
[root@localhost ~]#

# Description

Please include a summary of the change and which issue is fixed.

# Motivation

Please include an explanation of why you these changes are necessary

Please describe the tests that you ran to verify your changes. Provide instructions so we can reproduce.

Reviewed By: wangx6f

Differential Revision: D49675906

fbshipit-source-id: 2446ec36779b38003f4d86a8256636bbf4725bbd
  • Loading branch information
WayneLiu-wiwynn authored and facebook-github-bot committed Sep 27, 2023
1 parent 9ccf43a commit 8fae05a
Showing 1 changed file with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -209,6 +209,12 @@ int BiosComponent::update_internal(const std::string& image, int fd, bool force)
sleep(DELAY_ME_RESET);
}
if (SERVER_TYPE_HD != server_type || isBypass) {
if (server_type == SERVER_TYPE_GL) {
cerr << "12V-cycling the server for GL..." << endl;
pal_set_server_power(slot_id, SERVER_12V_CYCLE);
return ret;
}

cerr << "Power-cycling the server..." << endl;

// 12V-cycle is necessary for concerning BIOS/ME crash case
Expand Down

0 comments on commit 8fae05a

Please sign in to comment.