+++ This bug was initially created as a clone of Bug #1624009 +++ Description of problem: The 'pflash' device is instantiated by definig the -drive which is backing it. To allow snapshotting it along with the disks it would be beneficial to allow using -blockdev for it so that the same code can be reused. --- Additional comment from Markus Armbruster on 2018-09-26 05:03:48 EDT --- We configure pflash devices with -drive if=pflash,... Peter is looking for a way to configure them with -blockdev and -device. I'll look into it.
Fixed in upstream merge commit eda1df0345f5a1e337e30367124dcb0e802bdfde, will be in QEMU v4.0. The fix supersedes the old way of configuring OVMF -drive if=pflash,format=raw,unit=0,readonly,file=/usr/share/edk2/ovmf/OVMF_CODE.fd \ -drive if=pflash,format=raw,unit=1,file=copy-of-OVMF_VARS.fd by -blockdev node-name=pflash0,driver=file,read-only=on,filename=/usr/share/edk2/ovmf/OVMF_CODE.fd \ -blockdev node-name=pflash1,driver=file,filename=copy-of-OVMF_VARS.fd \ -machine pflash0=pflash0,pflash1=pflash1
Verified on qemu-kvm-4.0.0-0.module+el8.1.0+3169+3c501422.x86_64: plash device works well with blockdev. -blockdev node-name=pflash0,read-only=on,driver=file,filename=/usr/share/OVMF/OVMF_CODE.secboot.fd \ -blockdev node-name=pflash1,driver=file,filename=/home/kvm_autotest_root/images/rhel810-64-virtio-scsi.qcow2.fd \ -machine pflash0=pflash0,pflash1=pflash1 \
Dropping NEED_INFO
Based on comment 4, set bug to 'VERIFIED'. Thanks.
*** Bug 1717155 has been marked as a duplicate of this bug. ***
Hi Laszlo: It looks that the slow train does not support Property '.pflash0'. /usr/libexec/qemu-kvm -M q35 -cpu SandyBridge -enable-kvm -m 4G -smp 4 -nodefaults \ -global driver=cfi.pflash01,property=secure,value=on \ -machine pflash0=pflash0,pflash1=pflash1 \ -blockdev node-name=pflash0,read-only=on,driver=file,filename=/usr/share/edk2/ovmf/OVMF_CODE.secboot.fd \ -blockdev node-name=pflash1,read-only=off,driver=file,filename=/tmp/new-edk2-version/OVMF_VARS.fd \ ... ... qemu-kvm: Property '.pflash0' not found Version: qemu-kvm-2.12.0-81.module+el8.1.0+3619+dfe1ae01.x86_64 edk2-ovmf-20190308git89910a39dcfd-5.el8.noarch Thank you for your help.
The slow train has not gotten this feature. If it is needed there, ask for it by cloning this BZ for product "Red Hat Enterprise Linux 8".
(In reply to Markus Armbruster from comment #14) > The slow train has not gotten this feature. If it is needed there, ask for > it by cloning this BZ for product "Red Hat Enterprise Linux 8". It's not needed. We don't plan to support -blockdev in RHEL8 (slow train) until a potential rebase of major virt components (qemu, libvirt, etc).
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2019:3723