Skip to content

Commit ebdddb5

Browse files
committed
boot: Add some error context
Signed-off-by: Colin Walters <[email protected]>
1 parent db7d769 commit ebdddb5

File tree

1 file changed

+4
-2
lines changed
  • crates/lib/src/bootc_composefs

1 file changed

+4
-2
lines changed

crates/lib/src/bootc_composefs/boot.rs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1+
use std::ffi::OsStr;
12
use std::fs::create_dir_all;
23
use std::io::Write;
34
use std::path::Path;
4-
use std::ffi::OsStr;
55

66
use anyhow::{anyhow, Context, Result};
77
use bootc_blockdev::find_parent_devices;
@@ -567,6 +567,7 @@ pub(crate) fn setup_composefs_bls_boot(
567567
}
568568

569569
/// Writes a PortableExecutable to ESP along with any PE specific or Global addons
570+
#[context("Writing {file_path} to ESP")]
570571
fn write_pe_to_esp(
571572
repo: &ComposefsRepository<Sha256HashValue>,
572573
file: &RegularFile<Sha256HashValue>,
@@ -586,7 +587,8 @@ fn write_pe_to_esp(
586587
if matches!(pe_type, PEType::Uki) {
587588
let cmdline = uki::get_cmdline(&efi_bin).context("Getting UKI cmdline")?;
588589

589-
let (composefs_cmdline, insecure) = get_cmdline_composefs::<Sha256HashValue>(cmdline)?;
590+
let (composefs_cmdline, insecure) =
591+
get_cmdline_composefs::<Sha256HashValue>(cmdline).context("Parsing composefs=")?;
590592

591593
// If the UKI cmdline does not match what the user has passed as cmdline option
592594
// NOTE: This will only be checked for new installs and now upgrades/switches

0 commit comments

Comments
 (0)