virtio-blk: BDRV_REQ_REGISTERED_BUF optimization hint crashes on macOS Description of problem: When using QEMU 7.2.0 on macOS with the virtio-blk drive, the process will exit and QMP shows a `BLOCK_IO_ERROR` event. This appears to be caused by this line: https://gitlab.com/qemu-project/qemu/-/blob/master/hw/block/virtio-blk.c#L405 introduced in https://gitlab.com/qemu-project/qemu/-/commit/baf422684d73c7bf38e2c18815e18d44fcf395b6 Commenting that line out fixes the issue. Steps to reproduce: 1. Run the QEMU command above with a Ubuntu 22.04 server ISO image. 2. Follow the installer and try to get to the end. 3. The process will crash before you can finish installing. Additional information: Following event appears on QMP: ``` { data = { action = report; device = "drive437EC806-41A4-4CCE-A747-713352E7C27C"; "node-name" = "#block785"; nospace = 0; operation = write; reason = "Invalid argument"; }; event = "BLOCK_IO_ERROR"; timestamp = { microseconds = 808474; seconds = 1671867673; }; } ```