[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Qemu-devel] [PATCH v5 1/4] fdc: fix implied seek while there is no medi
From: |
Pavel Hrdina |
Subject: |
[Qemu-devel] [PATCH v5 1/4] fdc: fix implied seek while there is no media in drive |
Date: |
Wed, 13 Jun 2012 15:43:11 +0200 |
The Windows uses 'READ' command at the start of an instalation
without checking the 'dir' register. We have to abort the transfer
with an abnormal termination if there is no media in the drive.
Signed-off-by: Pavel Hrdina <address@hidden>
---
hw/fdc.c | 4 ++++
1 files changed, 4 insertions(+), 0 deletions(-)
diff --git a/hw/fdc.c b/hw/fdc.c
index 30d34e3..be35201 100644
--- a/hw/fdc.c
+++ b/hw/fdc.c
@@ -159,6 +159,10 @@ static int fd_seek(FDrive *drv, uint8_t head, uint8_t
track, uint8_t sect,
drv->sect = sect;
}
+ if (drv->bs == NULL || !bdrv_is_inserted(drv->bs)) {
+ ret = 2;
+ }
+
return ret;
}
--
1.7.7.6
- [Qemu-devel] [PATCH v5 0/4] fdc: fix/rewrite seek, media_changed and interrupt handling, Pavel Hrdina, 2012/06/13
- [Qemu-devel] [PATCH v5 2/4] fdc-test: introduced qtest read_without_media, Pavel Hrdina, 2012/06/13
- [Qemu-devel] [PATCH v5 3/4] fdc: rewrite seek and DSKCHG bit handling, Pavel Hrdina, 2012/06/13
- [Qemu-devel] [PATCH v5 4/4] fdc: fix interrupt handling, Pavel Hrdina, 2012/06/13
- [Qemu-devel] [PATCH v5 1/4] fdc: fix implied seek while there is no media in drive,
Pavel Hrdina <=
- Re: [Qemu-devel] [PATCH v5 0/4] fdc: fix/rewrite seek, media_changed and interrupt handling, Kevin Wolf, 2012/06/14