Patrick Venture | 6dd5cc9 | 2018-11-09 18:27:28 -0800 | [diff] [blame] | 1 | HOMEPAGE = "http://github.com/openbmc/phosphor-ipmi-flash" |
| 2 | SUMMARY = "Phosphor OEM IPMI In-band Firmware Update over BLOB" |
| 3 | DESCRIPTION = "This package handles a series of OEM IPMI commands that implement the firmware update handler over the BLOB protocol." |
| 4 | PR = "r1" |
Patrick Venture | 24d981d | 2019-06-28 15:34:15 -0700 | [diff] [blame] | 5 | PV = "1.0+git${SRCPV}" |
Patrick Venture | 6dd5cc9 | 2018-11-09 18:27:28 -0800 | [diff] [blame] | 6 | LICENSE = "Apache-2.0" |
| 7 | LIC_FILES_CHKSUM = "file://LICENSE;md5=86d3f3a95c324c9479bd8986968f4327" |
| 8 | |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 9 | inherit meson pkgconfig systemd |
Patrick Venture | 6dd5cc9 | 2018-11-09 18:27:28 -0800 | [diff] [blame] | 10 | |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 11 | DEPENDS += " \ |
| 12 | phosphor-ipmi-blobs \ |
| 13 | phosphor-logging \ |
| 14 | sdbusplus \ |
| 15 | systemd \ |
| 16 | ipmi-blob-tool \ |
| 17 | function2 \ |
| 18 | " |
Patrick Venture | 6dd5cc9 | 2018-11-09 18:27:28 -0800 | [diff] [blame] | 19 | |
Andrew Geissler | 79ca37b | 2019-06-19 18:52:19 +0000 | [diff] [blame] | 20 | PACKAGECONFIG ?= "cleanup-delete" |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 21 | PACKAGECONFIG[cleanup-delete] = "-Dcleanup-delete=enabled,-Dcleanup-delete=disabled" |
Patrick Venture | e4c6407 | 2019-06-28 19:28:28 -0700 | [diff] [blame] | 22 | # If using static-layout, reboot-update is a good option to handle updating. |
Brandon Kim | c0323d6 | 2019-09-17 17:14:48 -0700 | [diff] [blame] | 23 | # To be able to track the update status, update-status option can be used. |
| 24 | # Note that both reboot-update and update-status cannot be enabled at the same time. |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 25 | PACKAGECONFIG[reboot-update] = "-Dreboot-update=true,-Dreboot-update=false" |
| 26 | PACKAGECONFIG[update-status] = "-Dupdate-status=true,-Dupdate-status=false" |
Patrick Venture | 5bcb867 | 2019-07-19 14:07:22 -0700 | [diff] [blame] | 27 | |
| 28 | # Default options for supporting various flash types: |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 29 | PACKAGECONFIG[static-bmc] = "-Dupdate-type=static-layout,-Dupdate-type=none" |
| 30 | PACKAGECONFIG[ubitar-bmc] = "-Dupdate-type=tarball-ubi,-Dupdate-type=none" |
| 31 | PACKAGECONFIG[host-bios] = "-Dhost-bios=true,-Dhost-bios=false" |
Andrew Geissler | 79ca37b | 2019-06-19 18:52:19 +0000 | [diff] [blame] | 32 | |
Patrick Venture | 700db3c | 2019-07-15 09:39:43 -0700 | [diff] [blame] | 33 | # Hardware options to enable transmitting the data from the host. |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 34 | # Only one type of p2a or lpc can be enabled. |
| 35 | PACKAGECONFIG[aspeed-p2a] = "-Dp2a-type=aspeed-p2a,,,,,aspeed-lpc nuvoton-lpc nuvoton-p2a-vga nuvoton-p2a-mbox" |
| 36 | PACKAGECONFIG[aspeed-lpc] = "-Dlpc-type=aspeed-lpc,,,,,aspeed-p2a nuvoton-lpc nuvoton-p2a-vga nuvoton-p2a-mbox" |
| 37 | PACKAGECONFIG[nuvoton-lpc] = "-Dlpc-type=nuvoton-lpc,,,,,aspeed-p2a aspeed-lpc nuvoton-p2a-vga nuvoton-p2a-mbox" |
| 38 | PACKAGECONFIG[nuvoton-p2a-vga] = "-Dp2a-type=nuvoton-p2a-vga,,,,,aspeed-p2a aspeed-lpc nuvoton-lpc nuvoton-p2a-mbox" |
| 39 | PACKAGECONFIG[nuvoton-p2a-mbox] = "-Dp2a-type=nuvoton-p2a-mbox,,,,,aspeed-p2a aspeed-lpc nuvoton-lpc nuvoton-p2a-vga" |
| 40 | PACKAGECONFIG[net-bridge] = "-Dnet-bridge=true,-Dnet-bridge=false" |
Patrick Venture | 700db3c | 2019-07-15 09:39:43 -0700 | [diff] [blame] | 41 | |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 42 | EXTRA_OEMESON = "-Dtests=disabled -Dhost-tool=disabled" |
Patrick Venture | 51c0f09 | 2019-05-15 12:19:16 -0700 | [diff] [blame] | 43 | |
Patrick Venture | d190c73 | 2019-07-15 09:50:03 -0700 | [diff] [blame] | 44 | # Set this variable in your recipe to set it instead of using MAPPED_ADDRESS directly. |
| 45 | IPMI_FLASH_BMC_ADDRESS ?= "0" |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 46 | EXTRA_OEMESON:append = " -Dmapped-address=${IPMI_FLASH_BMC_ADDRESS}" |
Patrick Venture | d190c73 | 2019-07-15 09:50:03 -0700 | [diff] [blame] | 47 | |
Patrick Venture | 6dd5cc9 | 2018-11-09 18:27:28 -0800 | [diff] [blame] | 48 | S = "${WORKDIR}/git" |
Patrick Williams | bb99d22 | 2022-01-24 15:55:09 -0600 | [diff] [blame^] | 49 | SRC_URI = "git://github.com/openbmc/phosphor-ipmi-flash;branch=master;protocol=https" |
Andrew Geissler | 76a34c7 | 2022-01-07 20:40:13 +0000 | [diff] [blame] | 50 | SRCREV = "a49a3f79e4bea32929d7be8201645c7d83b0f2ae" |
Andrew Geissler | bae19af | 2019-07-08 19:51:12 +0000 | [diff] [blame] | 51 | |
| 52 | SYSTEMD_PACKAGES = "${PN}" |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 53 | SYSTEMD_SERVICE:${PN} += " \ |
| 54 | phosphor-ipmi-flash-bmc-prepare.target \ |
| 55 | phosphor-ipmi-flash-bmc-verify.target \ |
| 56 | phosphor-ipmi-flash-bmc-update.target \ |
| 57 | " |
Andrew Geissler | bae19af | 2019-07-08 19:51:12 +0000 | [diff] [blame] | 58 | |
| 59 | # If they enabled host-bios, add those three extra targets. |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 60 | HOST_BIOS_TARGETS = " \ |
| 61 | phosphor-ipmi-flash-bios-prepare.target \ |
| 62 | phosphor-ipmi-flash-bios-verify.target \ |
| 63 | phosphor-ipmi-flash-bios-update.target \ |
| 64 | " |
Andrew Geissler | bae19af | 2019-07-08 19:51:12 +0000 | [diff] [blame] | 65 | |
Patrick Williams | 12fc939 | 2021-08-06 09:16:53 -0500 | [diff] [blame] | 66 | SYSTEMD_SERVICE:${PN} += "${@bb.utils.contains('PACKAGECONFIG', 'host-bios', '${HOST_BIOS_TARGETS}', '', d)}" |
Patrick Venture | 6dd5cc9 | 2018-11-09 18:27:28 -0800 | [diff] [blame] | 67 | |
Willy Tu | fedadb5 | 2021-09-17 09:46:45 -0700 | [diff] [blame] | 68 | FILES:${PN}:append = " ${libdir}/ipmid-providers" |
| 69 | FILES:${PN}:append = " ${libdir}/blob-ipmid" |
Patrick Williams | 12fc939 | 2021-08-06 09:16:53 -0500 | [diff] [blame] | 70 | FILES:${PN}:append = " ${libdir}/tmpfiles.d" |
Patrick Venture | 6dd5cc9 | 2018-11-09 18:27:28 -0800 | [diff] [blame] | 71 | |
| 72 | BLOBIPMI_PROVIDER_LIBRARY += "libfirmwareblob.so" |
William A. Kennington III | a89d924 | 2021-01-29 20:18:02 -0800 | [diff] [blame] | 73 | BLOBIPMI_PROVIDER_LIBRARY += "libversionblob.so" |
Gaurav Gandhi | 8563c83 | 2022-01-05 00:50:25 +0000 | [diff] [blame] | 74 | BLOBIPMI_PROVIDER_LIBRARY += "liblogblob.so" |
Andrew Geissler | 79ca37b | 2019-06-19 18:52:19 +0000 | [diff] [blame] | 75 | BLOBIPMI_PROVIDER_LIBRARY += "${@bb.utils.contains('PACKAGECONFIG', 'cleanup-delete', 'libfirmwarecleanupblob.so', '', d)}" |
Patrick Venture | 3c1a03b | 2019-05-08 07:43:10 -0700 | [diff] [blame] | 76 | |
| 77 | do_configure[depends] += "virtual/kernel:do_shared_workdir" |