diff options
author | Adriana Kobylak <anoo@us.ibm.com> | 2019-10-29 00:03:12 +0300 |
---|---|---|
committer | Brad Bishop <bradleyb@fuzziesquirrel.com> | 2019-11-20 13:13:02 +0300 |
commit | fb62a68f16d3fa64b242bd8c65abf64ef8088889 (patch) | |
tree | c9ef92a6dc3b20f4c95e718296b4b5a2c051c7a1 | |
parent | efef4377f8062867f0b845eb803ad5d6f97d7285 (diff) | |
download | openbmc-fb62a68f16d3fa64b242bd8c65abf64ef8088889.tar.xz |
image_types_phosphor: Make Version Purpose configurable
The current version purpose is set to BMC[1]. Make it a configurable
variable for cases where other Purpose value is more appropriate, like
setting it to System if the machine includes the host-fw package that
would package the BMC and host firmware code into a combined image.
1: https://github.com/openbmc/phosphor-dbus-interfaces/blob/master/xyz/openbmc_project/Software/Version.interface.yaml
Tested: Verified the purpose is still BMC, then verifed that setting the
variable from a machine.conf file changed its value.
(From meta-phosphor rev: 356265535d268858840ddbe52ff8c1e37f084188)
Change-Id: I159e73f9b9c310321dda885b10dbc1cd56a674ee
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
-rw-r--r-- | meta-phosphor/classes/image_types_phosphor.bbclass | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/meta-phosphor/classes/image_types_phosphor.bbclass b/meta-phosphor/classes/image_types_phosphor.bbclass index 23ff3475c7..e29f4ff47f 100644 --- a/meta-phosphor/classes/image_types_phosphor.bbclass +++ b/meta-phosphor/classes/image_types_phosphor.bbclass @@ -57,6 +57,8 @@ SIGNING_KEY ?= "${STAGING_DIR_NATIVE}${datadir}/OpenBMC.priv" INSECURE_KEY = "${@'${SIGNING_KEY}' == '${STAGING_DIR_NATIVE}${datadir}/OpenBMC.priv'}" SIGNING_KEY_DEPENDS = "${@oe.utils.conditional('INSECURE_KEY', 'True', 'phosphor-insecure-signing-key-native:do_populate_sysroot', '', d)}" +VERSION_PURPOSE ?= "xyz.openbmc_project.Software.Version.VersionPurpose.BMC" + UBOOT_SUFFIX ?= "bin" python() { @@ -418,10 +420,11 @@ def get_pubkey_path(d): 'publickey') python do_generate_phosphor_manifest() { + purpose = d.getVar('VERSION_PURPOSE', True) version = do_get_version(d) target_machine = d.getVar('MACHINE', True) with open('MANIFEST', 'w') as fd: - fd.write('purpose=xyz.openbmc_project.Software.Version.VersionPurpose.BMC\n') + fd.write('purpose={}\n'.format(purpose)) fd.write('version={}\n'.format(version.strip('"'))) fd.write('KeyType={}\n'.format(get_pubkey_type(d))) fd.write('HashType=RSA-SHA256\n') |