summary refs log tree commit diff stats
path: root/hw
diff options
context:
space:
mode:
authorPeter Maydell <peter.maydell@linaro.org>2015-04-30 20:34:54 +0100
committerPeter Maydell <peter.maydell@linaro.org>2015-04-30 20:34:54 +0100
commit5bccbb04a4abba7af4398de992bf06d585fd1333 (patch)
tree4cf4b6eed5b634b06354df55722841cccfd6f5f3 /hw
parentf90f5b9a9aa41e5ea47dc7a0f3e1f99196f485c3 (diff)
parent4a4d614ff56b4cf15e83629946afe51dc116053f (diff)
downloadfocaccia-qemu-5bccbb04a4abba7af4398de992bf06d585fd1333.tar.gz
focaccia-qemu-5bccbb04a4abba7af4398de992bf06d585fd1333.zip
Merge remote-tracking branch 'remotes/kevin/tags/for-upstream' into staging
Block patches

# gpg: Signature made Thu Apr 30 19:51:16 2015 BST using RSA key ID C88F2FD6
# gpg: Good signature from "Kevin Wolf <kwolf@redhat.com>"

* remotes/kevin/tags/for-upstream:
  Enable NVMe start controller for Windows guest.
  MAINTAINERS: Add qemu-block list where missing
  MAINTAINERS: make block layer core Kevin Wolf's responsibility
  MAINTAINERS: make image fuzzer Stefan Hajnoczi's responsibility
  MAINTAINERS: make block I/O path Stefan Hajnoczi's responsibility
  MAINTAINERS: split out image formats
  MAINTAINERS: make virtio-blk Stefan Hajnoczi's responsibility

Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Diffstat (limited to 'hw')
-rw-r--r--hw/block/nvme.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/hw/block/nvme.c b/hw/block/nvme.c
index 1e071662d2..ad988d7c24 100644
--- a/hw/block/nvme.c
+++ b/hw/block/nvme.c
@@ -615,6 +615,13 @@ static void nvme_write_bar(NvmeCtrl *n, hwaddr offset, uint64_t data,
         n->bar.intmc = n->bar.intms;
         break;
     case 0x14:
+        /* Windows first sends data, then sends enable bit */
+        if (!NVME_CC_EN(data) && !NVME_CC_EN(n->bar.cc) &&
+            !NVME_CC_SHN(data) && !NVME_CC_SHN(n->bar.cc))
+        {
+            n->bar.cc = data;
+        }
+
         if (NVME_CC_EN(data) && !NVME_CC_EN(n->bar.cc)) {
             n->bar.cc = data;
             if (nvme_start_ctrl(n)) {