aboutsummaryrefslogtreecommitdiff
path: root/xorg-server/hw/xfree86/int10/generic.c
diff options
context:
space:
mode:
Diffstat (limited to 'xorg-server/hw/xfree86/int10/generic.c')
-rw-r--r--xorg-server/hw/xfree86/int10/generic.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/xorg-server/hw/xfree86/int10/generic.c b/xorg-server/hw/xfree86/int10/generic.c
index 4633120fd..d7594def2 100644
--- a/xorg-server/hw/xfree86/int10/generic.c
+++ b/xorg-server/hw/xfree86/int10/generic.c
@@ -178,7 +178,8 @@ xf86ExtendedInitInt10(int entityIndex, int Flags)
*/
vbiosMem = (char *) base + V_BIOS;
memset(vbiosMem, 0, 2 * V_BIOS_SIZE);
- if (pci_device_read_rom(pInt->dev, vbiosMem) < V_BIOS_SIZE) {
+ if (pci_device_read_rom(pInt->dev, vbiosMem) != 0
+ || pInt->dev->rom_size < V_BIOS_SIZE) {
xf86DrvMsg(pScrn->scrnIndex, X_WARNING,
"Unable to retrieve all of segment 0x0C0000.\n");
}