Bug 1122973
| Summary: | missing pci address for vga devices | ||||||
|---|---|---|---|---|---|---|---|
| Product: | Red Hat Enterprise Linux 7 | Reporter: | Francesco Romani <fromani> | ||||
| Component: | libvirt | Assignee: | Libvirt Maintainers <libvirt-maint> | ||||
| Status: | CLOSED ERRATA | QA Contact: | Virtualization Bugs <virt-bugs> | ||||
| Severity: | unspecified | Docs Contact: | |||||
| Priority: | unspecified | ||||||
| Version: | 7.0 | CC: | danken, dyuan, fnovak, hannsj_uhl, jdenemar, jtomko, juzhou, lhuang, michal.skrivanek, michen, mzhan, rbalakri, rmm | ||||
| Target Milestone: | rc | ||||||
| Target Release: | 7.1 | ||||||
| Hardware: | ppc64 | ||||||
| OS: | Unspecified | ||||||
| Whiteboard: | |||||||
| Fixed In Version: | libvirt-1.2.7-1.el7 | Doc Type: | Bug Fix | ||||
| Doc Text: | Story Points: | --- | |||||
| Clone Of: | Environment: | ||||||
| Last Closed: | 2015-03-05 07:41:36 UTC | Type: | Bug | ||||
| Regression: | --- | Mount Type: | --- | ||||
| Documentation: | --- | CRM: | |||||
| Verified Versions: | Category: | --- | |||||
| oVirt Team: | --- | RHEL 7.3 requirements from Atomic Host: | |||||
| Cloudforms Team: | --- | Target Upstream Version: | |||||
| Embargoed: | |||||||
| Bug Depends On: | |||||||
| Bug Blocks: | 1122979 | ||||||
| Attachments: |
|
||||||
This has been fixed upstream by:
commit 54e4d9d081e816b35a097ddd2596899cc3846b1a
Author: Vitor de Lima <vitor.lima.br>
AuthorDate: 2013-11-06 14:13:54 -0200
Commit: Laine Stump <laine>
CommitDate: 2013-11-08 12:48:32 +0200
qemu: assign PCI address to primary video card
When adding support for Q35 guests, the code to assign a PCI address
to the primary video card was moved into Q35 and i440fx(PIIX3)
specific functions, but no fallback was kept for other machine types
that might have a video card.
This patch remedies that by assigning a PCI address to the primary
video card if it does not have any kind of address. In particular,
this fixes issues with pseries guests.
Signed-off-by: Vitor de Lima <vitor.lima.br>
Signed-off-by: Laine Stump <laine>
git describe: v1.1.4-57-g54e4d9d contains: v1.2.0-rc1~106
Verify this bug with libvirt-1.2.8-10.el7.ppc64:
1. prepare a guest xml with vga video:
# cat test3.xml
<video>
<model heads="1" type="vga" vram="32768"/>
</video>
2. create it :
# virsh create test3.xml
Domain test3-lhuang created from test3.xml
3.check the xml:
# virsh dumpxml test3-lhuang
<video>
<model type='vga' vram='32768' heads='1'/>
<alias name='video0'/>
<address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/>
</video>
Also test with define and start, no issue found.
Check the code: in src/qemu/qemu_command.c
2249 /* Assign a PCI slot to the primary video card if there is not an
2250 * assigned address. */
2251 if (def->nvideos > 0 &&
2252 def->videos[0]->info.type == VIR_DOMAIN_DEVICE_ADDRESS_TYPE_NONE) {
2253 if (virDomainPCIAddressReserveNextSlot(addrs, &def->videos[0]->info,
2254 flags) < 0)
2255 goto error;
2256 }
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://rhn.redhat.com/errata/RHSA-2015-0323.html |
Created attachment 920542 [details] example xml to be fed to virsh createxml Description of problem: When creating a domain with a VGA video device, the device doesn't get a pci address in the XML domain representation: relevant snippet: <video> <model type='vga' vram='32768' heads='1'/> <alias name='video0'/> </video> However, on x86_64, this happens: <video> <model type='vga' vram='32768' heads='1'/> <alias name='video0'/> <address type='pci' domain='0x0000' bus='0x00' slot='0x02' function='0x0'/> </video> Input XML for both cases is ... <devices> ... <video> <model heads="1" type="vga" vram="32768"/> </video> ... </devices> ... Version-Release number of selected component (if applicable): libvirt-1.1.3-1.pkvm2_1.17.3.ppc64 How reproducible: 100% of times in my experiments Steps to Reproduce: 1. create a domain with a vga device 2. get back the xml representation from libvirt (virsh dumpxml...) 3. Actual results: the vga device has not an address element, unlike x86_64 Expected results: the vga device has not an address element, unlike x86_64 Additional info: example domain XML attached