aboutsummaryrefslogtreecommitdiff
path: root/hw/ide.c
diff options
context:
space:
mode:
authorpbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162>2006-06-04 11:39:07 +0000
committerpbrook <pbrook@c046a42c-6fe2-441c-8c8c-71466251a162>2006-06-04 11:39:07 +0000
commit7a6cba611d09f8eccdfc90d5ad3eb03762e60ce9 (patch)
tree43cfb9b27d844ba04ed506226d4cfc0246d5506e /hw/ide.c
parent17acfe326ce2038033934485145ddd2390337986 (diff)
Disk cache flush support.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@1949 c046a42c-6fe2-441c-8c8c-71466251a162
Diffstat (limited to 'hw/ide.c')
-rw-r--r--hw/ide.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/hw/ide.c b/hw/ide.c
index ffe0230d8a..debbc0f418 100644
--- a/hw/ide.c
+++ b/hw/ide.c
@@ -1656,6 +1656,11 @@ static void ide_ioport_write(void *opaque, uint32_t addr, uint32_t val)
break;
case WIN_FLUSH_CACHE:
case WIN_FLUSH_CACHE_EXT:
+ if (s->bs)
+ bdrv_flush(s->bs);
+ s->status = READY_STAT;
+ ide_set_irq(s);
+ break;
case WIN_STANDBYNOW1:
case WIN_IDLEIMMEDIATE:
s->status = READY_STAT;