[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI re
From: |
Michael S. Tsirkin |
Subject: |
Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI rerror/werror=stop |
Date: |
Mon, 28 Oct 2013 19:16:53 +0200 |
On Mon, Oct 28, 2013 at 05:43:16PM +0100, Paolo Bonzini wrote:
> Hi all,
>
> this is some cleanup to the IDE code that I started long ago
> and picked up again on my flight back from KVM Forum...
>
> The patches clean up the callbacks to prepare for implementing request
> retry for AHCI. After these patches, PIO retry should work for AHCI and
> non-NCQ retry should be very close (you need an implementation of the
> new restart_dma callback). NCQ retry and save/restore is AHCI-specific
> and has to be done separately, similar to how we do it for SCSI already.
>
> Patches 1-4 set up a new (incomplete) testcase. Patches 5-13 are no-op
> cleanups, or so I hope. Patches 14-23 genericize retry and make it
> "just work" for all adapters for PIO. Patch 24 is another cleanup that
> could probably be moved earlier in the series.
>
> Throwing it out since I know Kevin and mst are working on AHCI, to avoid
> doing duplicate work. Patches 2 and 4 are known to be racy and
> incomplete. Extremely light testing, if something breaks tells me and
> I'll look at it.
>
> Paolo
Well ATM win7 boot is broken with non NCQ (crash on boot).
Do you patches help?
Also, without NCQ win 7 boot will sometime hang.
The following patch by Alex makes it behave better:
it still sometimes hangs for a very long time but with the patch it
will after a long time proceed. Sometimes it proceeds normally.
diff --git a/hw/ide/ahci.c b/hw/ide/ahci.c
index a8be62c..fbea9e8 100644
--- a/hw/ide/ahci.c
+++ b/hw/ide/ahci.c
@@ -961,7 +961,8 @@ static int handle_cmd(AHCIState *s, int port, int slot)
/* We're ready to process the command in FIS byte 2. */
ide_exec_cmd(&s->dev[port].port, cmd_fis[2]);
- if (s->dev[port].port.ifs[0].status & READY_STAT) {
+ if ((s->dev[port].port.ifs[0].status &
(READY_STAT|DRQ_STAT|BUSY_STAT)) ==
+ READY_STAT) {
ahci_write_fis_d2h(&s->dev[port], cmd_fis);
}
}
- Re: [Qemu-devel] [PATCH 16/24] ide: introduce ide_register_restart_cb, (continued)
- [Qemu-devel] [PATCH 17/24] ide: do not use BMDMA in restart callback, Paolo Bonzini, 2013/10/28
- [Qemu-devel] [PATCH 18/24] ide: pass IDEBus to the restart_cb, Paolo Bonzini, 2013/10/28
- [Qemu-devel] [PATCH 19/24] ide: move restart callback to common code, Paolo Bonzini, 2013/10/28
- [Qemu-devel] [PATCH 20/24] ide: remove restart_cb callback, Paolo Bonzini, 2013/10/28
- [Qemu-devel] [PATCH 21/24] ide: replace set_unit callback with more IDEBus state, Paolo Bonzini, 2013/10/28
- [Qemu-devel] [PATCH 22/24] ide: place initial state of the current request to IDEBus, Paolo Bonzini, 2013/10/28
- [Qemu-devel] [PATCH 23/24] ide: migrate initial request state via IDEBus, Paolo Bonzini, 2013/10/28
- [Qemu-devel] [PATCH 24/24] ide: commonize io_buffer_index initialization, Paolo Bonzini, 2013/10/28
- Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI rerror/werror=stop,
Michael S. Tsirkin <=
- Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI rerror/werror=stop, Paolo Bonzini, 2013/10/28
- Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI rerror/werror=stop, Michael S. Tsirkin, 2013/10/28
- Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI rerror/werror=stop, Paolo Bonzini, 2013/10/28
- Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI rerror/werror=stop, Michael S. Tsirkin, 2013/10/28
- Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI rerror/werror=stop, Paolo Bonzini, 2013/10/29
Re: [Qemu-devel] [WIP PATCH 00/24] IDE cleanups, initial work on AHCI rerror/werror=stop, Kevin Wolf, 2013/10/29