Capsule Upload and Apply Script
The data streams optimizer and the cache configurator use this script to copy a capsule to the target system and apply it.
- UEFI BIOS
- Slim Bootloader (SBL)
The script supports the Yocto Project*-based board support package.
You can copy and modify the script to support another firmware or OS. The scripts must meet the following requirements to maintain compatibility with the data streams optimizer:
- Input: The first parameter is a capsule version. Other parameters are paths to capsules on the host system.When a capsule is copied to the target, the capsule name is specified by thecapsule_createscript, but the destination is specified in thetarget_capsules_pathfield in the environment file.Capsule version is important for Windows* operating systems. The data streams optimizer uses capsule version “1” for Linux* operating systems.usage: capsule_upload_apply_uefi.sh VERSION CAPSULE_FILE_1 CAPSULE_FILE_2 ... CAPSULE_FILE_N VERSION Capsule version to apply CAPSULE_FILE_N Path to the capsule file
- Output: Return code must be 0 when the capsule is applied successfully.
- Error handling: Any nonzero value returned from the script will be interpreted as an error. Any additional logging should be printed to STDERR.
Example:
Command line: tools/host_scripts/capsule_upload_apply_uefi.sh 1 /home/root/my_on_host_capsule.capsule
STDOUT: some-output-there
Return value: 0
STDERR: empty