RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Bug 622999 - core dumped when starting vm with large pci addr
Summary: core dumped when starting vm with large pci addr
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Red Hat Enterprise Linux 6
Classification: Red Hat
Component: qemu-kvm
Version: 6.0
Hardware: All
OS: Linux
medium
medium
Target Milestone: rc
: ---
Assignee: Virtualization Maintenance
QA Contact: Virtualization Bugs
URL:
Whiteboard:
Depends On:
Blocks: 580953
TreeView+ depends on / blocked
 
Reported: 2010-08-11 02:51 UTC by Cao, Chen
Modified: 2013-01-09 22:59 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2010-08-11 16:59:05 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Cao, Chen 2010-08-11 02:51:52 UTC
Description of problem:
core dumped when starting vm with pci addr > 0x20


Version-Release number of selected component (if applicable):
qemu-kvm-0.12.1.2-2.108.el6.x86_64


How reproducible:
frequently


Steps to Reproduce:
1. start vm with (pci addr = 0x92, 0x93)
qemu-kvm -name 'vm1' -chardev socket,id=human_monitor_f5dI,path=/tmp/monitor-humanmonitor1-20100810-181354-WbJi,server,nowait -mon chardev=human_monitor_f5dI,mode=readline -chardev socket,id=serial_Zm5R,path=/tmp/serial-20100810-181354-WbJi,server,nowait -device isa-serial,chardev=serial_Zm5R -drive file='/tests/kvm/images/RHEL-Server-5.5-PAE-virtio.qcow2',index=0,if=none,id=drive-virtio-disk1,media=disk,cache=none,snapshot=on,boot=on,format=qcow2,aio=native -device virtio-blk-pci,bus=pci.0,addr=0x92,drive=drive-virtio-disk1,id=virtio-disk1 -device virtio-net-pci,netdev=idopXlAo,id=ndev00idopXlAo,mac='02:B7:5E:9A:35:8a',bus=pci.0,addr=0x93 -netdev tap,id=idopXlAo,ifname='virtio_0_8000',script='/tests/kvm/scripts/qemu-ifup-switch',downscript='no',vhost=on -m 4096 -smp 2 -vnc :0 -spice port=8000,disable-ticketing -rtc base=utc,clock=host -M rhel6.0.0 -usbdevice tablet -cpu qemu64,+sse2 -no-kvm-pit-reinjection

2. 
3.
  
Actual results:
segfault and core dumped


Expected results:
error msg should be poped when the addr is illegal (or not supported),
and qemu-kvm exits


Additional info:
# uname -r
2.6.32-59.el6.x86_64

(gdb) bt
#0  0x0000003e49c48007 in vfprintf () from /lib64/libc.so.6
#1  0x0000003e49c493b0 in buffered_vfprintf () from /lib64/libc.so.6
#2  0x0000003e49c4451e in vfprintf () from /lib64/libc.so.6
#3  0x0000003e49cf9007 in __vfprintf_chk () from /lib64/libc.so.6
#4  0x0000000000475317 in error_report (
    fmt=0x582eb8 "PCI: devfn %d not available for %s, in use by %s")
    at qemu-error.c:206
#5  0x0000000000419a0b in do_pci_register_device (pci_dev=0x2bb21a0,
    bus=0x2b8a010, name=<value optimized out>, devfn=1168, config_read=0,
    config_write=0, header_type=0 '\000')
    at /usr/src/debug/qemu-kvm-0.12.1.2/hw/pci.c:646
#6  0x0000000000419db8 in pci_qdev_init (qdev=0x2bb21a0, base=0x8399e0)
    at /usr/src/debug/qemu-kvm-0.12.1.2/hw/pci.c:1485
#7  0x00000000004bd6e8 in qdev_init (dev=0x2bb21a0)
    at /usr/src/debug/qemu-kvm-0.12.1.2/hw/qdev.c:275
#8  0x00000000004bda69 in qdev_device_add (opts=0x23c85b0)
    at /usr/src/debug/qemu-kvm-0.12.1.2/hw/qdev.c:250
#9  0x0000000000408f09 in device_init_func (opts=<value optimized out>,
    opaque=<value optimized out>) at /usr/src/debug/qemu-kvm-0.12.1.2/vl.c:4963
#10 0x0000000000475c3a in qemu_opts_foreach (list=<value optimized out>,
    func=0x408f00 <device_init_func>, opaque=0x0,
    abort_on_failure=<value optimized out>) at qemu-option.c:903
#11 0x000000000040de30 in main (argc=<value optimized out>,
    argv=<value optimized out>, envp=<value optimized out>)
    at /usr/src/debug/qemu-kvm-0.12.1.2/vl.c:6425


also reproduced with the same backtrace when pci addr is 0x21, 0x22:
qemu-kvm -name 'vm1' -chardev socket,id=human_monitor_jJSI,path=/tmp/monitor-humanmonitor1-20100810-181354-WbJi,server,nowait -mon chardev=human_monitor_jJSI,mode=readline -chardev socket,id=serial_b7LS,path=/tmp/serial-20100810-181354-WbJi,server,nowait -device isa-serial,chardev=serial_b7LS -drive file='/root/autotest/client/tests/kvm/images/RHEL-Server-5.5-64-virtio.qcow2',index=0,if=none,id=drive-virtio-disk1,media=disk,cache=none,snapshot=on,boot=on,format=qcow2,aio=native -device virtio-blk-pci,bus=pci.0,addr=0x21,drive=drive-virtio-disk1,id=virtio-disk1 -device virtio-net-pci,netdev=idopXlAo,id=ndev00idopXlAo,mac='02:B7:5E:9A:35:8a',bus=pci.0,addr=0x22 -netdev tap,id=idopXlAo,ifname='virtio_0_8000',script='/root/autotest/client/tests/kvm/scripts/qemu-ifup-switch',downscript='no',vhost=on -m 4096 -smp 2 -vnc :0 -spice port=8000,disable-ticketing -rtc base=utc,clock=host -M rhel6.0.0 -usbdevice tablet -cpu qemu64,+sse2 -no-kvm-pit-reinjection

Comment 1 Cao, Chen 2010-08-11 02:57:45 UTC
or is it a problem of void error_report(const char *fmt, ...)?

make this bug block tier1, and change if it is not a big problem.


Note You need to log in before you can comment on or make changes to this bug.