| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
|
|
| |
Adopt a more conventional directory hierarchy. meta-phosphor is still
a _long_ way from suitable for hosting on yoctoproject.org but things
like this don't help.
(From meta-phosphor rev: 471cfcefa74b8c7ceb704cb670e6d915cf27c63b)
Change-Id: I3f106b2f6cdc6cec734be28a6090800546f362eb
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Andrew Geissler (1):
Add -flto to CXXFLAGS
Lei YU (3):
Make MEDIA_DIR configurable
Delete functional BMC id if ACTIVE_BMC_MAX_ALLOWED is less than 2
static layout: Support field mode
(From meta-phosphor rev: 1b7c30dcac5dff739a6ccb66ccd20ed632511f9b)
Change-Id: If5b70e8c063b86c9ee8dbc6bcd433b52b0a7d5e4
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
For static flash layout, configure ACTIVE_BMC_MAX_ALLOWED to 1, because
it has only one active BMC image;
For ubi-fs, configure ACTIVE_BMC_MAX_ALLOWED to 2, because ubi-fs
assumes there are two BMC images by default.
Resolves openbmc/phosphor-bmc-code-mgmt#2
Tested: Verify that ACTIVE_BMC_MAX_ALLOWED is set to 1 for Romulus
build, and set to 2 for Witherspoon build.
(From meta-phosphor rev: bf3edf1ce09f19836c38c2dd43ab4e50664fc46e)
Change-Id: I60e49c14bda25547fde9a2308470ed164ebbd249
Signed-off-by: Lei YU <mine260309@gmail.com>
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Configure MEDIA_DIR to /run/media for static flash layout;
Configure MEDIA_DIR to /media which is default for ubi-fs.
Resolves openbmc/phosphor-bmc-code-mgmt#3
Tested: Verify that the MEDIA_DIR is set to /run/media for Romulus
build, and set to /media for Witherspoon build.
(From meta-phosphor rev: f43eb6ee89433e4898cbdb1532963f038419c003)
Change-Id: If96c2ee135d314bd6de0cd745c6a871b75183fe1
Signed-off-by: Lei YU <mine260309@gmail.com>
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Static flash layout will use obmc-flash-bmc-setenv service to set
factory-reset env in u-boot, so make it common for both static and ubi
flash layout.
Tested: Build the image and verify the service and the obmc-flash-bmc
script exist in both static and ubi builds.
(From meta-phosphor rev: b2c944f13b0f891a7f569f3a9608e3c0de27a462)
Change-Id: Ia067cebfe35a9d2d7d2af8b4d1bd4cb5717372ae
Signed-off-by: Lei YU <mine260309@gmail.com>
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
| |
Change-Id: Ia57c246400656cee580f8fd5f249a05ad44c2715
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: Ibd1e9079fb4a20326f64888e2aa49190262ed9c5
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: I3ab604d0c77177e015278170abf4e95b5b1c1d8a
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: Iaedf2c60272e02e656fd4949a5ab6c4fd9205a4c
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This needs to be done so phosphor-logging will know to grab
the error log's metadata from the journal and add it to
the log in the AdditionalData field.
Tested: Check that the errors now show up in the elog-lookup.cpp
file generated during the build by phosphor-logging.
Change-Id: I59e357986ac56ea752c9f7241a5138eb4985ceb6
Signed-off-by: Matt Spinler <spinler@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I7685577363722d767cfb881d8388824812c06265
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Add ubifs_layout package config and pass --enable-ubifs_layout
configuration option when ubi-fs distro feature is enabled.
Tested: Verify --enable-ubifs_layout is passed to
phosphor-software-manager's config for Witherspoon;
And it is not passed for Romulus.
Change-Id: I6daa0c565d2c2be980b6292e62654c0a86a69bbc
Signed-off-by: Lei YU <mine260309@gmail.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Remove from the base phosphor-software-manager recipe everything
that is conditional in the ubi-fs distro feature and put it
in its own class.
This allows for the base recipe to be cleaner and for future
specific packages to be added conditionally.
Tested: Built witherspoon and romulus and verified only
witherspoon contained the UBI-specific files.
Booted a witherspoon and a romulus qemu.
Change-Id: I2a783abc6152aadcf212a35f0060409f8dac2241
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
| |
Change-Id: Iad305e48972e1f78c2fe3226d48abd213043675b
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
Check that the alt rwfs ubi volume exists before attempting
to mount it to avoid journal error messages.
Resolves openbmc/openbmc#3245
Tested: Mount is not attempted if alt rwfs doesn't exist, and
no error msgs are created.
Change-Id: Id48a06ca32d799686859e2ff14399d39cc8076bd
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
| |
Change-Id: Ib42fc67bd9d0ad4b4b762e84ad8c7cc1127bbcf4
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
1e4452449 added a systemd tmpfile config file for the software image
upload path but the config file was added to the systemd recipe.
tmpfile config files should be added to the recipes/config files that
use them. For example on an RPM based distro:
$ rpm -qf /usr/lib/tmpfiles.d/samba.conf
samba-common-4.7.7-0.fc27.noarch
Tested: Validated software.conf present in Witherspoon rootfs
Change-Id: I47e8c8c44eb19440cc98d0380e9634f688eccb21
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
|
|
|
|
| |
Replace invocations of mapper call with a call to busctl and mapper
get-service. This provides equivalent functionality but opens the
door for dropping a systemd patch we have carried for some time.
Change-Id: Iea0cce89341939b49b095d1f5010415578331d4d
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
| |
Change-Id: I6756f715f355b9ff45c537a2d705aba6c3e1814c
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
A DeleteAll request first deletes individual software D-Bus objects
and their corresponding rofs and kernel UBI volumes, then it calls
the cleanup service to remove UBI volumes that were not part of a
D-Bus object.
1. Only delete the rofs volume during a cleanup, this is the volume
used to create D-Bus objects. Don't delete the kernel volume because
if the system has an alt BMC chip, the backup kernel volume is
deleted as part of this step which is undesirable.
2. Call createenvbackup as part of the cleanup service, to update
the alt environment variables to point to the currently running
image, because DeleteAll will delete all other images so the alt
environment should be updated to point to the remaining image.
Change-Id: Ibde8f9ef275c0536573cf0625c8291096c6cdd6e
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
A number of recipes remove PN from the package list. While this
seems to work it is unconventional and puts us into dusty corners
of oe-core/bitbake.
Adopt a more conventional approach with ALLOW_EMPTY_${PN} = "1".
Change-Id: If19c9cf985878dc42f17a85f6762bbe20ffe5ee1
Tested: Built phosphor-software-manager and validated package contents
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
| |
Change-Id: I3adfd5505862a7403dcb0096b645563580af3e59
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: Ia45c127d9915a9cd2432e95aca26fbca8f413eef
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
| |
Create a synclist file to specify the files and directories
that the sync manager should copy over to the alternate
BMC chip. Store the synclist file in /etc/ by default so
that it can be modified at runtime if desired.
Change-Id: I458b08fafd565e7622a1c7497b6d9c5b61674fdc
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
|
|
|
| |
Add the sync manager which watches for files to be synced
to the alternate BMC chip.
Change-Id: I543dacf389629c024b35d1b855745bbcc0bbd848
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I357c3cc25c9c0300b8a1b1e3124bb004f89ab32f
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Mount the rwfs of the alt-bmc chip if present when the BMC
boots up to be able to synchronize (backup files) from the
BMC rwfs to the alt one, for the case when a chip switch
occurs then the persistent data is available on the alt chip.
Create a persist/etc directory to backup the /etc files to
it since that's the overlay's upperdir for /etc.
Change-Id: Ibe287fa792c1e214ba35a43bc253da391728299a
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
phosphor-software-manager is the recipe to manage software updates with
obmc-ubi-fs feature.
Missing the RDEPENDS will cause the built image to miss the ubi utils,
and code update will fail.
Resolves openbmc/openbmc#3177.
Tested: On a romulus build, verify there are no ubi utils without ubifs
feature;
verify there are ubi utils with ubifs feature.
Change-Id: Ib6de3ecee4d1b914e4dbc4df3c9c9e4baa1bb0be
Signed-off-by: Lei YU <mine260309@gmail.com>
|
|
|
|
|
| |
Change-Id: Ic3dac782519bf1211a3e85c2e72de467d7c9bf26
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: Ie10a6afa4e1ad14534fe94b493e2689dc5e29c61
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
| |
The BMC automatically changes the mtd device numbers (and udev names)
when we're on the alternate chip. As such, we can always copy the
current BMC chip u-boot to the alt chip, without checking whether we're
on the alternate chip or not; "alt" always means the other chip than the
one we're booted from.
Change-Id: Iedf9f3aae2196434b7972be6b73b4bc7bfb608d0
Signed-off-by: Eddie James <eajames@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
With commit https://gerrit.openbmc-project.xyz/#/c/10248/
a new u-boot env variable set was introduced to switch
sides on failure to boot. Since a BMC update does not
update the env variables, explicitly set them if they're
not present.
Tested: Verified the new env variables were set after
activating the image and rebooting the BMC.
Change-Id: I807c3e4f9a37d9d9d5f474ba4eb7c60351e3334e
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Enable signature verification in the phosphor-software-manager code
for witherspoon. This causes an error to be logged if updating to
an unsigned image, or image signed with a different key than the one
on the system, and if field mode is set, it'll stop the activation
process.
Tested: Signature verification is enforced on witherspoon,
verified error is logged with and without field mode enabled, and
activation is prevented with field mode enabled.
Change-Id: Ifc8f8054f8d852cc16942af9cbf58d60aff3fc33
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The mirror u-boot function copies the currently booted BMC chip's u-boot
partition to the alternate chip, if the two don't match. This is to make
sure we always have a good u-boot in the alternate flash.
Also add service file for the mirror u-boot option.
Resolves openbmc/openbmc#2876
Change-Id: Ida09a167de21f3ccb588a096509d88ad88450c93
Signed-off-by: Eddie James <eajames@us.ibm.com>
|
|
|
|
|
| |
Change-Id: Id6dada319cfd2e63db9b993532750af688f80e6a
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: Ia3ee6911e600c60fba86c49a40e17f005dee623d
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: I33cc9f8e02fa65b74d14cb6f929136fdf1c701ac
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
In order to secure the BMC, we need to sign all the images and include a
public key in the package with which to verify future update images.
This commit adds a framework to sign the image files with an open
private key and generates a corresponding public key added to the image.
This isn't secure by itself (since the private key is available), but
additional changes can easily provide their own private key, creating a
secure BMC.
To use a secure private key:
export BB_ENV_EXTRAWHITE="$BB_ENV_EXTRAWHITE SIGNING_KEY"
SIGNING_KEY=/path/to/secure/key bitbake obmc-phosphor-image
Resolves openbmc/openbmc#2835
Resolves openbmc/openbmc#2836
Resolves openbmc/openbmc#2837
Change-Id: I28919b7de54e3a32e5efcbb4522fb39731e68384
Signed-off-by: Eddie James <eajames@us.ibm.com>
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|
|
|
|
|
| |
Change-Id: I2b6ee56c1742fea4418d97a6321362555138dcf7
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: I9a8a1e198ef86e82f1b00b133a10aad43a5acbf0
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: Ia1a1be4de904c5675678a4f248fa36973ed8a364
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
| |
Change-Id: I01c99149582d50cffcab2fa3c46fc28e4e57100f
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
obmc-control-bmc service was removed from build but bmc flash service
still depends on it, which causes it never starts and BMC will not enter
ready state.
Removing the non-existing dependency and this service can be started.
Tested: Without this change, BMC becomes NotReady state after power on;
With this change, BMC enters Ready state after power on.
Change-Id: I469037cc5d5c15a695e1fd1730d14af7cbc03d73
Signed-off-by: Lei YU <mine260309@gmail.com>
|
|
|
|
|
| |
Change-Id: I5311255a9d45846fdf774177d848635286d24226
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
| |
This download service is used on systems that do not implement
the UBI code update feature. Therefore it should run at the same
priority as all other services. On the UBI enabled system that
doesn't use it (witherspoon), its been pulled from the image.
Resolves openbmc/openbmc-tools#13
Change-Id: I14693dadda375f9d0108e4fccb1a614dae7388e1
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Ignore the return code of fw_printenv in case rwfs_size doesn't
exist, otherwise the function fails and doesn't get set.
Also check that the imgsize variable is set before calling
fw_setenv to prevent accidentally clearing the rwfs_size.
Tested: Verified that rwfs_size gets set when it didn't exist.
Also that it gets updated when the value is different than
the one passed. And that it doesn't get cleared if the function
is called without passing the imgsize argument.
Change-Id: I02e3414e3b22da55890b7343b8805402139b6bad
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
If an environment variable doesn't exist, fw_printenv returns 1
(error). With the addition of "set -eo pipefail" to the
obmc-flash-bmc script, this error causes the service that sets
the priorities to fail:
witherspoon systemd[1]: Starting Set U-Boot environment variable...
witherspoon obmc-flash-bmc[3883]: ## Error: "66089bab" not defined
witherspoon systemd[1]: obmc-flash-bmc-setenv@66089bab\x3d0.service: Main process exited, code=exited, status=1/FAILURE
witherspoon systemd[1]: Failed to start Set U-Boot environment variable.
Ignore the return code instead, the variable will be empty
if fw_printenv doesn't return a value.
Change-Id: I78b559e0ccb74ae52c73f1cc37b06a139a0d0e14
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
| |
Change-Id: I4ecedf890b2d19d1345fa80f9278ed198429a588
Signed-off-by: Andrew Geissler <geissonator@yahoo.com>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The default size of the UBI read-write volume is currently set to 4MB.
There are no plans to store more than one BMC rootfs image on the chip
so in a 32MB flash chip, accounting for the current rootfs image size
of ~15MB with plans to grow to ~20MB with the addition of redfish and
other packages, it is safe to increase the read-write volume size to
6MB since the current size is already almost completely taken up if
there are multiple error logs / dumps on the system.
In addition, make the size configurable from a recipe so that the
size can be changed in a per-system basis. And during code update,
check the current size and update it if it's different, this allows
systems to be able to be resized to a new size by performing factory
reset after a code update that sets the new size.
Tested:
- Booted on QEMU and verified non-ubi system (romulus) retains the
current 4MB read-write volume, and ubi system (witherspoon) has a
6MB volume.
- Code updated to an image that has these changes and verified the
rwfs_size env variable changes to 6MB, and that a subsequent factory
reset rebuilds the volume with size 6MB.
Change-Id: I995eb560c1bd87ee95712c731e3d6e55bc0b2735
Signed-off-by: Adriana Kobylak <anoo@us.ibm.com>
|
|
|
|
|
|
|
|
| |
The phosphor-software-manager-updater depends on bash. Add
the runtime dependency.
Change-Id: I619cf8d965be520785752ad6073419a5eb645618
Signed-off-by: Brad Bishop <bradleyb@fuzziesquirrel.com>
|