32e9ea16 | 01-Feb-2025 |
Patrick Williams <patrick@stwcx.xyz> |
meson: reformat with meson formatter
Apply the `meson format` results.
Change-Id: I116103d8e0994e09ecb6381f5bb7d564608826b2 Signed-off-by: Patrick Williams <patrick@stwcx.xyz> |
99d292a3 | 08-Feb-2022 |
Willy Tu <wltu@google.com> |
phosphor-ipmi-flash: Code Health Cleanup
Removed the following warning. - using decl '*' is unused - 'push_back' is called inside a loop; consider pre-allocating the container capacity before th
phosphor-ipmi-flash: Code Health Cleanup
Removed the following warning. - using decl '*' is unused - 'push_back' is called inside a loop; consider pre-allocating the container capacity before the loop - function '*' defined in a header file; function definitions in header files can lead to ODR violations
Change-Id: I44e4b0f8056a853fb45b690394be1a8ebec45b20 Signed-off-by: Willy Tu <wltu@google.com>
show more ...
|
bcae9002 | 12-Sep-2021 |
Willy Tu <wltu@google.com> |
build: Add meson build
Changes to note, - `with_systemdsystemunitdir` and `with_tmpfilesdir` is removed since it is not being documented nor used in OpenBMC. - Removed the Code coverage feature wi
build: Add meson build
Changes to note, - `with_systemdsystemunitdir` and `with_tmpfilesdir` is removed since it is not being documented nor used in OpenBMC. - Removed the Code coverage feature with `-DDHAVE_GCOV`, since it is not used and meson covers it. - Removed `--enable-oe-sdk` for using the OpenBMC SDK. It should work directly with no change required.
Tested: ``` Jan 01 00:01:54 ipmid[709]: Try loading blob from persistent data Jan 01 00:01:54 ipmid[709]: Stale blob data, resetting internals... Jan 01 00:01:56 ipmid[709]: config loaded: /flash/bios Jan 01 00:01:56 ipmid[709]: config loaded: /flash/image Jan 01 00:01:56 ipmid[709]: config loaded: /flash/dummy ... ```
``` $ ls /usr/lib/blob-ipmid/ libfirmwareblob.so libfirmwarecleanupblob.so libversionblob.so ```
Testing the service, ``` $ echo "hello" > /tmp/test.txt $ burn_my_bmc -command update -layout dummy -image /tmp/test.txt Sending over the firmware image. Opening the verification file Committing to /flash/verify to trigger service Calling stat on /flash/verify session to check status running success Returned success succeeded ```
On the BMC. ``` /run/initramfs$ cat dummy hello ```
Change-Id: I21c7c33bd62c0ee40681cb40da90125c125bea2f Signed-off-by: Willy Tu <wltu@google.com>
show more ...
|
f450486f | 25-Apr-2021 |
Willy Tu <wltu@google.com> |
test: Replace the C++ MOCK_METHOD<n> macros with the new MOCK_METHOD
Change-Id: I5099c727e9e918f19fa61acc91ef75250ebc6fa6 Signed-off-by: Willy Tu <wltu@google.com> |
4175b4ca | 24-Dec-2020 |
William A. Kennington III <wak@google.com> |
Add callback support to triggerable actions
Change-Id: Icc27fbe9403eda418f41e12c76af7f3216f4b72a Signed-off-by: William A. Kennington III <wak@google.com> |
c78bfc82 | 05-Nov-2020 |
Jason Ling <jasonling@google.com> |
version-handler: add version-handler, blob handler
Implement version-handler: a blob handler for retrieving version information about a blob.
Problem: ipmi-flash(firmware-handler) provides a mechan
version-handler: add version-handler, blob handler
Implement version-handler: a blob handler for retrieving version information about a blob.
Problem: ipmi-flash(firmware-handler) provides a mechanism to transfer firmware updates, verify them and perform updates but there is no mechanism to interrogate the firmware for its version.
Solution: version-handler provides handlers for retrieving information about firmware blobs. Adding "version" syntax to "/flash/blob" entries in the json configuration file enables this feature. The mechanism to retrieve version is identical to the mechanism used by firmware-handler to perform preparation, verification and updates (kick off systemd targets).
Signed-off-by: Jason Ling <jasonling@google.com> Change-Id: I28868ca8dd76d63af668d2e46b9359401d45f0bc
show more ...
|
84bff8be | 06-Nov-2020 |
Jason Ling <jasonling@google.com> |
test: move shared mocks to common area
Move mocks that can be shared between version and firmware handler tests to parent directory (bmc/test).
This will eliminate the need to duplicate the definit
test: move shared mocks to common area
Move mocks that can be shared between version and firmware handler tests to parent directory (bmc/test).
This will eliminate the need to duplicate the definition of testing mocks.
Signed-off-by: Jason Ling <jasonling@google.com> Change-Id: Id41c56271d0bfbcb8c18da1f903c7786699508d4
show more ...
|
ded66d0f | 23-Oct-2020 |
Jason Ling <jasonling@google.com> |
move files around to create a common convenience library
Problem: plan is to add another blob handler into ipmi-flash (ipmi-flash-version). This new handler will re-use much of the ipmi-flash (firmw
move files around to create a common convenience library
Problem: plan is to add another blob handler into ipmi-flash (ipmi-flash-version). This new handler will re-use much of the ipmi-flash (firmware-handler) code. The common code should be presented as a convenience library to reduce code duplication.
Solution: move anticipated firmware-handler specific code into the subdirectory bmc/firmware-handler and leave common code in bmc/.
The end goal is to have version-handler re-use as much code as possible.
Tested: rebuilt everything and ran unit tests.
Signed-off-by: Jason Ling <jasonling@google.com> Change-Id: I2128da629b0ddf27b89f1faee358d1941f1dff38
show more ...
|
63902a43 | 06-Oct-2020 |
Patrick Venture <venture@google.com> |
bmc/test: cleanup remove unused declarations
Remove unused using declarations.
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: If975e789745f4c625c84fba376d85f805f38f3e0 |
4b1b0450 | 30-Sep-2020 |
Patrick Venture <venture@google.com> |
bmc/test: add missing util header
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: I384e9d34d65336c9081da88e4378a987b26c8504 |
da4d4a43 | 28-Sep-2020 |
Patrick Venture <venture@google.com> |
bmc/test: fixups detected in bazel-type build
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Id5a2ac8ab7a59d6483a82e51ebcb25d7aaffaf50 |
794a37c1 | 25-Sep-2020 |
Patrick Venture <venture@google.com> |
bmc/test: drop unused variable
There was a variable in a test that aimed to do something but was unused.
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Ieffd014d740acebbafa68d98076b
bmc/test: drop unused variable
There was a variable in a test that aimed to do something but was unused.
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Ieffd014d740acebbafa68d98076bd63fd1855132
show more ...
|
c6ba8ffc | 23-Sep-2020 |
Patrick Venture <venture@google.com> |
cleanup: transition to emplace_back where possible
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: I41ea0bcabe0dd71111fa96b5e1baf12d3e79d129 |
4934daac | 22-Sep-2020 |
Patrick Venture <venture@google.com> |
bmc: move data handler to owned object
To handle the case where one cannot have complex static or global objects, the object must be owned. In this case, it is reasonable to pass ownership to the o
bmc: move data handler to owned object
To handle the case where one cannot have complex static or global objects, the object must be owned. In this case, it is reasonable to pass ownership to the only object that will use the data handler.
Alternatively, singletons can be used to get around this, but just using ownership is more appropriate.
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: I47b291d1cd01af9d4b7287c1411ed9ba37aa7a4c
show more ...
|
7b783439 | 22-Sep-2020 |
Patrick Venture <venture@google.com> |
bmc: move transports vector into handler object
Move the transport vector to the firmware handler object.
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Ic64b56b95ec52d4bbeb7e12ac26
bmc: move transports vector into handler object
Move the transport vector to the firmware handler object.
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Ic64b56b95ec52d4bbeb7e12ac26d0cc238363e42
show more ...
|
92f26150 | 26-May-2020 |
Patrick Venture <venture@google.com> |
firmware: add expiration handle
Expiring the session aborts the process.
Tested: Only tested with unit-tests, not run on a real system. Signed-off-by: Patrick Venture <venture@google.com> Change-Id
firmware: add expiration handle
Expiring the session aborts the process.
Tested: Only tested with unit-tests, not run on a real system. Signed-off-by: Patrick Venture <venture@google.com> Change-Id: I3a7ae54cfa04e162a2a1e591c0ddd4eca3d6d3db
show more ...
|
9b37b095 | 28-May-2020 |
Patrick Venture <venture@google.com> |
update gcc10 and clang-format10
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: I72239b884615d26b2c4311c49a26e2eced0a1fb0 |
d53d60a4 | 07-Apr-2020 |
Patrick Venture <venture@google.com> |
bmc: config: add skip action
If you specify the action for one of the three fields as "skip" it'll create a handler object for that action that always returns success and has no effect. This action
bmc: config: add skip action
If you specify the action for one of the three fields as "skip" it'll create a handler object for that action that always returns success and has no effect. This action therefore "skips" the step, moving the state machine forward as though it was a successful real action.
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Ib4c1091745eb96b8381a332bbeb0562625d3bfbe
show more ...
|
1290198f | 12-Nov-2019 |
Benjamin Fair <benjaminfair@google.com> |
bmc: allowing packing transport flags densely
Future transport backends can densely fill in the upper 5 bits of the transport flag bitfield.
Signed-off-by: Benjamin Fair <benjaminfair@google.com> C
bmc: allowing packing transport flags densely
Future transport backends can densely fill in the upper 5 bits of the transport flag bitfield.
Signed-off-by: Benjamin Fair <benjaminfair@google.com> Change-Id: Ie4ee59e0581e458a9020775e18270100f9a1de4e
show more ...
|
a67e9e9e | 15-Nov-2019 |
Benjamin Fair <benjaminfair@google.com> |
bmc: add test for reserved flags
Test that no one adds transport backends which use the lower 3 bits of the transport flag bitfield. These bits are reserved for exclusive use with the IPMI, LPC, and
bmc: add test for reserved flags
Test that no one adds transport backends which use the lower 3 bits of the transport flag bitfield. These bits are reserved for exclusive use with the IPMI, LPC, and P2A backends to ensure backwards compatibility with older host tools.
Signed-off-by: Benjamin Fair <benjaminfair@google.com> Change-Id: I6284f2c864aeb5e20a812c0b13e9ecc61349b127
show more ...
|
1626538d | 06-Nov-2019 |
Patrick Venture <venture@google.com> |
bmc: require at least one action pack configuration
In the event the phosphor-ipmi-flash package is added to an image with only a default configuration, it should not register itself as a blob handl
bmc: require at least one action pack configuration
In the event the phosphor-ipmi-flash package is added to an image with only a default configuration, it should not register itself as a blob handler. The default installation does not include any json configuration files. Therefore, this lack of a configuration can be checked at load time.
Added validation that the firmware image list contains at least two handlers, and one is always the hash blob handler. Added validation that the action map contains at least one action pack configuration.
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: I0b2f6cded78121869e8a01290d29e420c555a16d
show more ...
|
e0216d23 | 21-Aug-2019 |
Patrick Venture <venture@google.com> |
bmc: merge update and prepare systemd
The update systemd and prepare systemd were effectively the same, and this makes the systemd action generic.
Tested: Not tested beyond unit-tests continuing to
bmc: merge update and prepare systemd
The update systemd and prepare systemd were effectively the same, and this makes the systemd action generic.
Tested: Not tested beyond unit-tests continuing to pass. Signed-off-by: Patrick Venture <venture@google.com> Change-Id: I8070731e53bfd6cdafb1d74d9db652f20341985e
show more ...
|
097435fc | 15-Aug-2019 |
Patrick Venture <venture@google.com> |
bmc: require blob ids to start with /flash/
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Ib6a0db91d4e2ecd7e7cc3c51ddc1953d9fd8da3c |
cf066ace | 06-Aug-2019 |
Patrick Venture <venture@google.com> |
bmc: cleanup verification language and symbols
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: Ife4d7e519e44aff60441c5909346ca6d7e2aa090 |
29af1e3e | 05-Aug-2019 |
Patrick Venture <venture@google.com> |
bmc: s/SystemdVerification/SystemdWithStatusFile/g
Signed-off-by: Patrick Venture <venture@google.com> Change-Id: I5da0ca9e3ae53df957647b19446df4196248fd31 |