Description of problem: boot a pre-installed virtio-scsi vm under Q35, and attach a usb storage using the ehci+uchi companion config file, set usb-storage's bootindex to 1, virtio-scsi's to 2, but seabios always try to boot from virtio-scsi instead of usb-storage. BTW, i test it with pc-i440fx-1.4 machine type did not hit it. Version-Release number of selected component (if applicable): host info: kernel-3.9.0-0.rc4.45.el7.x86_64 qemu-kvm-1.4.0-1.el7.x86_64 seabios-1.7.2-0.2.gita810e4e7.el7.x86_64 guest info: windows: win2012/win8 64bit rhel7: kernel-3.9.0-0.rc4.45.el7.x86_64 How reproducible: 100% Steps to Reproduce: 1.boot a guest with a simulated usb-storage using ehci controller under Q35. e.g:# /usr/libexec/qemu-kvm -S -M q35 -cpu SandyBridge -enable-kvm -m 4096 -smp 2,sockets=2,cores=1,threads=1 -no-kvm-pit-reinjection -name sluo-test -uuid ed09fa10-6ffe-4811-a42f-0294afcb5a42 -rtc base=localtime,clock=host,driftfix=slew -readconfig /home/ich9-ehci-uhci.cfg -device usb-tablet,id=tablet,port=1 -device usb-hub,id=hub,port=2 -device usb-kbd,id=kbd,port=2.1 -device usb-mouse,id=mouse,port=2.2 -drive file=/home/my-usb-storage1.qcow2,if=none,id=storage1,media=disk,cache=none,format=qcow2 -device usb-storage,drive=storage1,id=usb-storage1,bootindex=1 -drive file=/home/windows_server_2012_x64.qcow2,if=none,id=drive-system-disk,format=qcow2,cache=none,aio=native,werror=stop,rerror=stop,serial=QEMU-DISK1 -device virtio-scsi-pci,bus=pcie.0,addr=0x3,id=scsi0 -device scsi-hd,bus=scsi0.0,drive=drive-system-disk,id=system-disk,bootindex=2 -netdev tap,id=hostnet0,vhost=off,script=/etc/qemu-ifup -device virtio-net-pci,netdev=hostnet0,id=virtio-net-pci0,mac=08:2e:5f:0a:0d:b1,bus=pcie.0,addr=0x4,bootindex=3 -device virtio-balloon-pci,id=ballooning,bus=pcie.0,addr=0x5 -qmp tcp:0:4444,server,nowait -k en-us -boot menu=on -vnc :1 -spice disable-ticketing,port=5931 -monitor stdio 2.press F12 during POST. Actual results: after step 2, seabios always try to boot from virtio-scsi instead of usb-storage. 1. virtio-scsi Drive QEMU QEMU HARDDISK 1.4. 2. USB MSC Drive QEMU QEMU HARDDISK 1.4. 3. Legacy option rom 4. Floppy [drive A] 5. iPXE (PCI 00:05.0) Expected results: seabios could boot from usb-storage first as specified it firstly in command line. Additional info:
Created attachment 730664 [details] screenshot for testing under Q35.
Created attachment 730665 [details] screenshot for testing under pc-i440fx-1.4, the usb-storage's boot priority is set correctly by seabios.
BTW, the network also have to same problem to usb-storage, in the comment #0, i set the network's bootindex=3, but the seabios display it to '5'. this issue only under the Q35, pc-i440fx-1.4 machine type have no such issue.
IIRC this one was fixed in qemu by mst (fix pcihost name in device path).
sluo, can you test with latest qemu-kvm-rhel7? It seems a same issue as bug 923030.
(In reply to Amos Kong from comment #5) > sluo, can you test with latest qemu-kvm-rhel7? > It seems a same issue as bug 923030. Yes, the bootindex is just as specified in command line correctly with the same test as comment #0. host info: 3.10.0-41.el7.x86_64 qemu-kvm-1.5.3-14.el7.x86_64 seabios-1.7.2.2-3.el7.x86_64 seabios-bin-1.7.2.2-3.el7.noarch after step 2, 1. USB MSC Drive QEMU QEMU HARDDISK 1.5. <------USB storage 2. virtio-scsi Drive QEMU QEMU HARDDISK 1.5.<------scsi system disk 3. iPXE (PCI 00:04.0) <------virtio nic 4. Legacy option rom 5. Floppy [drive A] Base on above, this issue also has been fixed with qemu-1.5.1 in bug 923030. Best Regareds, sluo
*** This bug has been marked as a duplicate of bug 923030 ***