What does openbmc system do after update BMC Firmware and taps reboot?

Vijay Khemka vijaykhemka at fb.com
Tue Mar 3 07:41:11 AEDT 2020

During reboot, shutdown scripts check for any images in initramfs and it overwrites to its predefined partition via update scripts.

From: openbmc <openbmc-bounces+vijaykhemka=fb.com at lists.ozlabs.org> on behalf of 南野ムルシエラゴ <1181052146 at qq.com>
Date: Sunday, March 1, 2020 at 11:30 PM
To: openbmc <openbmc at lists.ozlabs.org>
Subject: What does openbmc system do after update BMC Firmware and taps reboot?


I am learning how openbmc update BMC firmware. I am following the guide "https://github.com/openbmc/docs/blob/master/code-update/code-update.md" to update BMC Firmware. It works well for me.
But I still do not know, why in step 7 should I reboot, and what reboot do?
Later I found in "https://github.com/openbmc/docs/blob/master/code-update/code-update-diagrams.md", which tells that:
        [*] In a static layout configuration, the images are stored in RAM and the content is written to flash during BMC reboot.
        Reference the update and shutdown scripts provided by initrdscripts<https://github.com/openbmc/openbmc/tree/master/meta-phosphor/recipes-phosphor/initrdscripts>
I am using a static layout. And I found two scripts named "shutdown" and "update" in "/run/initramfs/". So I thought it is that, the update applications put the firmware image in /run/initramfs/ and when I tap reboot, by some means the "update" script runs and the "update" script using "flashcp" command to write the firmware image to the /dev/mtd. Is that right?
What happens after I tap "reboot", and who calls the "update" script, and how it calls the "update" scripts?
Can someone tell me? Thanks a lot!

Best Regards!
Liu Hongwei

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.ozlabs.org/pipermail/openbmc/attachments/20200302/0415d6e4/attachment-0001.htm>

More information about the openbmc mailing list