diff options
author | Owain Ainsworth <oga@cvs.openbsd.org> | 2009-04-17 09:03:15 +0000 |
---|---|---|
committer | Owain Ainsworth <oga@cvs.openbsd.org> | 2009-04-17 09:03:15 +0000 |
commit | 7973b90a12e9f0eec34b485f0183423f446a3c1f (patch) | |
tree | a37c5160d567f856761d27332b5c64931b064280 | |
parent | f2b842104db0581bdc4ec00d36ec424b37929b1a (diff) |
Use the correct size when mapping the legacy vga rom.
fixes errors (and probably bugs) on intel hardware (at the least).
ok matthieu@
-rw-r--r-- | lib/libpciaccess/src/openbsd_pci.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/libpciaccess/src/openbsd_pci.c b/lib/libpciaccess/src/openbsd_pci.c index b83c35c3f..e9541443e 100644 --- a/lib/libpciaccess/src/openbsd_pci.c +++ b/lib/libpciaccess/src/openbsd_pci.c @@ -135,8 +135,8 @@ pci_device_openbsd_read_rom(struct pci_device *device, void *buffer) if (bios == MAP_FAILED) return errno; - memcpy(buffer, bios, device->rom_size); - munmap(bios, device->rom_size); + memcpy(buffer, bios, rom_size); + munmap(bios, rom_size); if (pci_rom) { /* Restore PCI config space */ |