Failed shutdown during record with `ide-hd` disk. Description of problem: Running `shutdown -h now` on the guest with an `ide-hd` disk during a recording results in a long wait, followed by a BMDMA error. Steps to reproduce: 1. Install Ubuntu Server guest OS and create disk snapshot 1. Reboot and log in: `qemu-system-x86_64 -hda ubuntu_snapshot.qcow2 -m 2g -net none -monitor stdio` 2. Take a snapshot: `savevm loggedin` 3. Start recording from VM snapshot: `./qemu/build/qemu-system-x86_64 -icount shift=auto,rr=record,rrfile=ubuntu_shutdown.bin -drive file=ubuntu_snapshot.qcow2,if=none,id=img-direct -drive driver=blkreplay,if=none,image=img-direct,id=img-blkreplay -device ide-hd,drive=img-blkreplay -loadvm loggedin -net none -m 2g` 4. Run `shutdown -h now` in guest 5. Wait (~5-10 mins) 6. Observe BMDMA error (see below) Additional information: ``` ata1.00: exeption Emask 0x0 SAct 0.0 SErr 0.0 action 0x6 ata1.00: BMDMA stat 0x5 ata1.00: failed command: READ DMA ata1.00: cmd c8/xx:xx:xx:xx:xx/xx:xx:xx:xx:xx/xx tag - dma 4096 in res 00/00:00:00:00:00/00:00:00:00:00/00 Emask 0x2 (HSM violation) ata1.00: revalidation failed (errno=-2) ... ``` Note: Running the same command on a guest with a `virtio` disk results in further progress, but still does not shut down (stuck on `[ OK ] Stopped Create final runtime dir for shutdown pivot root.`)