summaryrefslogtreecommitdiffstats
path: root/src/util/disrom.pl
diff options
context:
space:
mode:
authorPetr Borsodi2019-01-16 17:37:58 +0100
committerMichael Brown2019-01-21 12:58:02 +0100
commitde4565cbe76ea9f7913a01f331be3ee901bb6e17 (patch)
tree3ea69ee18d11142e9f841281e350b6ab665368eb /src/util/disrom.pl
parent[util] Improve processing of ROM images in Option::ROM (diff)
downloadipxe-de4565cbe76ea9f7913a01f331be3ee901bb6e17.tar.gz
ipxe-de4565cbe76ea9f7913a01f331be3ee901bb6e17.tar.xz
ipxe-de4565cbe76ea9f7913a01f331be3ee901bb6e17.zip
[util] Add support for EFI ROM images
The Option::ROM module recognizes and checks EFI header of image. The disrom.pl utility dumps this header if is present. Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/util/disrom.pl')
-rwxr-xr-xsrc/util/disrom.pl13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/util/disrom.pl b/src/util/disrom.pl
index 71eee590..6b2b3073 100755
--- a/src/util/disrom.pl
+++ b/src/util/disrom.pl
@@ -51,6 +51,19 @@ do {
printf " %-16s 0x%04x\n", "PnP header:", $rom->{pnp_header} if ( exists $rom->{pnp_header} );
printf "\n";
+ my $efi = $rom->efi_header();
+ if ( $efi ) {
+ printf "EFI header:\n\n";
+ printf " %-16s 0x%04x (%d)\n", "Init size:",
+ $efi->{init_size}, ( $efi->{init_size} * 512 );
+ printf " %-16s 0x%08x\n", "EFI Signature:", $efi->{efi_signature};
+ printf " %-16s 0x%04x\n", "EFI Subsystem:", $efi->{efi_subsystem};
+ printf " %-16s 0x%04x\n", "EFI Machine type:", $efi->{efi_machine_type};
+ printf " %-16s 0x%04x\n", "Compression type:", $efi->{compression_type};
+ printf " %-16s 0x%04x\n", "EFI Image offset:", $efi->{efi_image_offset};
+ printf "\n";
+ }
+
my $pci = $rom->pci_header();
if ( $pci ) {
printf "PCI header:\n\n";