aboutsummaryrefslogtreecommitdiffstats
path: root/src/util/fixrom.pl
diff options
context:
space:
mode:
authorMichael Brown <mcb30@ipxe.org>2012-07-23 17:41:38 +0100
committerMichael Brown <mcb30@ipxe.org>2012-07-23 17:57:40 +0100
commit5de45cd3da2308a6db37fb7c0822c9fdadf00d96 (patch)
treee33ac06ab9d117ea86644d2362660e84b7727c2f /src/util/fixrom.pl
parentee3636370d901bca306cf85241491f23e0f5034a (diff)
downloadipxe-5de45cd3da2308a6db37fb7c0822c9fdadf00d96.tar.gz
[romprefix] Report a pessimistic runtime size estimate
PCI3.0 allows us to report a "runtime size" which can be smaller than the actual ROM size. On systems that support PMM our runtime size will be small (~2.5kB), which helps to conserve the limited option ROM space. However, there is no guarantee that the PMM allocation will succeed, and so we need to report the worst-case runtime size in the PCI header. Move the "shrunk ROM size" field from the PCI header to a new "iPXE ROM header", allowing it to be accessed by ROM-manipulation utilities such as disrom.pl. Reported-by: Anton D. Kachalov <mouse@yandex-team.ru> Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/util/fixrom.pl')
-rwxr-xr-xsrc/util/fixrom.pl1
1 files changed, 1 insertions, 0 deletions
diff --git a/src/util/fixrom.pl b/src/util/fixrom.pl
index c84e2cf2..8987b512 100755
--- a/src/util/fixrom.pl
+++ b/src/util/fixrom.pl
@@ -32,6 +32,7 @@ foreach my $romfile ( @romfiles ) {
my $image = $rom;
while ( $image ) {
$image->pnp_header->fix_checksum() if $image->pnp_header;
+ $image->ipxe_header->fix_checksum() if $image->ipxe_header;
$image->fix_checksum();
$image = $image->next_image();
}