Bug 1004532 - qemu-system-ppc64 hangs at "Trying to read invalid spr 896 380 at .."
qemu-system-ppc64 hangs at "Trying to read invalid spr 896 380 at .."
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: qemu (Show other bugs)
19
ppc64 All
unspecified Severity medium
: ---
: ---
Assigned To: Fedora Virtualization Maintainers
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2013-09-04 17:10 EDT by IBM Bug Proxy
Modified: 2013-09-13 22:31 EDT (History)
13 users (show)

See Also:
Fixed In Version: qemu-1.4.2-9.fc19
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2013-09-13 22:31:17 EDT
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)


External Trackers
Tracker ID Priority Status Summary Last Updated
IBM Linux Technology Center 96915 None None None Never

  None (edit)
Description IBM Bug Proxy 2013-09-04 17:10:55 EDT
-- Problem Description --
Trying to do a qemu emulation inside Fedora 19 on PPC, but it hangs at 

Trying to read invalid spr 896 380 at 0000000000000394
Trying to read invalid spr 896 380 at 0000000000000714

Command used ->
/usr/bin/qemu-system-ppc64 -global virtio-blk-pci.scsi=off -nodefconfig -nodefaults -nographic -device virtio-scsi-pci,id=scsi -drive file=/root/Qemu.img/root.12578,snapshot=on,id=appliance,if=none,cache=unsafe -device scsi-hd,drive=appliance -machine pseries -m 500 -no-reboot -device virtio-serial -serial stdio -kernel /root/Qemu.img/kernel.12578 -initrd /root/Qemu.img/initrd.12578 -append "panic=1 console=ttyS0 udevtimeout=600 no_timer_check acpi=off printk.time=1 cgroup_disable=memory root=/dev/sda selinux=0 TERM=xterm"


[root@islcitm41 ~]# qemu-system-ppc -M ?
Supported machines are:
none                 empty machine
ref405ep             ref405ep
taihu                taihu
bamboo               bamboo
virtex-ml507         Xilinx Virtex ML507 reference design
ppce500              generic paravirt e500 platform
mac99                Mac99 based PowerMAC
g3beige              Heathrow based PowerMAC (default)
mpc8544ds            mpc8544ds
prep                 PowerPC PREP platform

[root@islcitm41 ~]# qemu-system-ppc64 -M ?
Supported machines are:
none                 empty machine
ref405ep             ref405ep
taihu                taihu
bamboo               bamboo
pseries              pSeries Logical Partition (PAPR compliant)
virtex-ml507         Xilinx Virtex ML507 reference design
ppce500              generic paravirt e500 platform
mac99                Mac99 based PowerMAC (default)
g3beige              Heathrow based PowerMAC
mpc8544ds            mpc8544ds
prep                 PowerPC PREP platform

[root@islcitm41 ~]# uname -a
Linux islcitm41.in.ibm.com 3.9.5-301.fc19.ppc64p7 #1 SMP Tue Jun 11 15:07:47 MST 2013 ppc64 ppc64 ppc64 GNU/Linux

Installed QEMU version is 1.4.2-3.fc19.ppc64

qemu-system-ppc-1.4.2-3.fc19.ppc64
qemu-1.4.2-3.fc19.ppc64

Console output while running qemu. ->

[root@islcitm41 ~]# /usr/bin/qemu-system-ppc64 -global virtio-blk-pci.scsi=off -nodefconfig -nodefaults -nographic -device virtio-scsi-pci,id=scsi -drive file=/root/Qemu.img/root.12578,snapshot=on,id=appliance,if=none,cache=unsafe -device scsi-hd,drive=appliance -machine pseries -m 500 -no-reboot -device virtio-serial -serial stdio -kernel /root/Qemu.img/kernel.12578 -initrd /root/Qemu.img/initrd.12578 -append "panic=1 console=ttyS0 udevtimeout=600 no_timer_check acpi=off printk.time=1 cgroup_disable=memory root=/dev/sda selinux=0 TERM=xterm"
Warning: Disabling some instructions which are not emulated by TCG (0x0, 0x6)


SLOF **********************************************************************
QEMU Starting
 Build Date = Feb 20 2013 00:43:40
 FW Version = mockbuild@(private build)
 Press "s" to enter Open Firmware.

Populating /vdevice methods
Populating /vdevice/vty@71000000
Populating /vdevice/nvram@71000001

NVRAM: size=65536, fetch=200E, store=200F
Populating /pci@800000020000000
 Adapters on 0800000020000000
                     00 0000 (D) : 1af4 1004    scsi*
                     00 0800 (D) : 1af4 1003    communication-controller*
No NVRAM common partition, re-initializing...
Using default console: /vdevice/vty@71000000
Detected RAM kernel at 400000 (15d85f4 bytes)
  Welcome to Open Firmware

  Copyright (c) 2004, 2011 IBM Corporation All rights reserved.
  This program and the accompanying materials are made available
  under the terms of the BSD License available at
  http://www.opensource.org/licenses/bsd-license.php

Booting from memory...
OF stdout device is: /vdevice/vty@71000000
Preparing to boot Linux version 3.9.5-301.fc19.ppc64p7 (mockbuild@ppc-builder3.qa.fedoraproject.org) (gcc version 4.8.1 20130603 (Red Hat 4.8.1-1) (GCC) ) #1 SMP Tue Jun 11 15:07:47 MST 2013
Detected machine type: 0000000000000101
Max number of cores passed to firmware: 1024 (NR_CPUS = 1024)
Calling ibm,client-architecture-support... not implemented
couldn't open /packages/elf-loader
command line: panic=1 console=ttyS0 udevtimeout=600 no_timer_check acpi=off printk.time=1 cgroup_disable=memory root=/dev/sda selinux=0 TERM=xterm
memory layout at init:
  memory_limit : 0000000000000000 (16 MB aligned)
  alloc_bottom : 00000000019f0000
  alloc_top    : 000000001f400000
  alloc_top_hi : 000000001f400000
  rmo_top      : 000000001f400000
  ram_top      : 000000001f400000
instantiating rtas at 0x000000001cff0000... done
Querying for OPAL presence... not there.
boot cpu hw idx 0
copying OF device tree...
Building dt strings...
Building dt structure...
Device tree strings 0x0000000001c00000 -> 0x0000000001c0070a
Device tree struct  0x0000000001c10000 -> 0x0000000001c20000
Calling quiesce...
returning from prom_init
[    0.000000] Using pSeries machine description
[    0.000000] Using 1TB segments
[    0.000000] Found initrd at 0xc0000000019f0000:0xc000000001b27200
[    0.000000] bootconsole [udbg0] enabled
[    0.000000] CPU maps initialized for 1 thread per core
[    0.000000] Starting Linux PPC64 #1 SMP Tue Jun 11 15:07:47 MST 2013
[    0.000000] -----------------------------------------------------
[    0.000000] ppc64_pft_size                = 0x16
[    0.000000] physicalMemorySize            = 0x1f400000
[    0.000000] htab_hash_mask                = 0x7fff
[    0.000000] -----------------------------------------------------
[    0.000000] Initializing cgroup subsys cpuset
[    0.000000] Initializing cgroup subsys cpu
[    0.000000] Linux version 3.9.5-301.fc19.ppc64p7 (mockbuild@ppc-builder3.qa.fedoraproject.org) (gcc version 4.8.1 20130603 (Red Hat 4.8.1-1) (GCC) ) #1 SMP Tue Jun 11 15:07:47 MST 2013
CF000012
Setup Arch[    0.000000] [boot]0012 Setup Arch
[    0.000000] PCI host bridge /pci@800000020000000  ranges:
[    0.000000]   IO 0x0000010080000000..0x000001008000ffff -> 0x0000000000000000
[    0.000000]  MEM 0x00000100a0000000..0x00000100bfffffff -> 0x0000000080000000
[    0.000000] PPC64 nvram contains 65536 bytes
[    0.000000] Zone ranges:
[    0.000000]   DMA      [mem 0x00000000-0x1f3fffff]
[    0.000000]   Normal   empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x00000000-0x1f3fffff]
Trying to read invalid spr 896 380 at 0000000000000394
Trying to read invalid spr 896 380 at 0000000000000714

This bug was fixed upstream:

http://git.qemu.org/?p=qemu.git;a=commitdiff;h=04559d5210860ea5853db09c75ea8ff2f8843e16
Comment 1 Fedora Update System 2013-09-05 05:56:25 EDT
qemu-1.4.2-9.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/qemu-1.4.2-9.fc19
Comment 2 Fedora Update System 2013-09-09 09:22:43 EDT
qemu-1.4.2-9.fc19 has been submitted as an update for Fedora 19.
https://admin.fedoraproject.org/updates/FEDORA-2013-15914/qemu-1.4.2-9.fc19
Comment 3 Richard W.M. Jones 2013-09-09 17:21:50 EDT
Just a note that I'm seeing this error on
qemu-system-ppc-1.6.0-6.fc21.ppc64, even though this version
of qemu seems to include the patch which supposedly fixes
this bug.  So either this fix is insufficient or something
odd is going on with qemu 1.6 as well.

[...]
[    0.000000] Zone ranges:
[    0.000000]   DMA      [mem 0x00000000-0x1f3fffff]
[    0.000000]   Normal   empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x00000000-0x1f3fffff]
Trying to read invalid spr 896 380 at 0000000000000394
Trying to read invalid spr 896 380 at 0000000000000714
Comment 4 Gustavo Luiz Duarte 2013-09-09 17:52:05 EDT
(In reply to Richard W.M. Jones from comment #3)
> Just a note that I'm seeing this error on
> qemu-system-ppc-1.6.0-6.fc21.ppc64, even though this version
> of qemu seems to include the patch which supposedly fixes
> this bug.  So either this fix is insufficient or something
> odd is going on with qemu 1.6 as well.

Which command line did you use?
It should work if you pass "-M pseries" with no -cpu option. Though we might try to fix other cpu variants as well.
Comment 5 Richard W.M. Jones 2013-09-09 17:56:03 EDT
For reasons I don't really understand, qemu-system-ppc64
compiled from git works fine.
Comment 6 Richard W.M. Jones 2013-09-09 17:56:53 EDT
(In reply to Gustavo Luiz Duarte from comment #4)
> (In reply to Richard W.M. Jones from comment #3)
> > Just a note that I'm seeing this error on
> > qemu-system-ppc-1.6.0-6.fc21.ppc64, even though this version
> > of qemu seems to include the patch which supposedly fixes
> > this bug.  So either this fix is insufficient or something
> > odd is going on with qemu 1.6 as well.
> 
> Which command line did you use?
> It should work if you pass "-M pseries" with no -cpu option. Though we might
> try to fix other cpu variants as well.

In both cases I'm using -M pseries.

The full command line was:

qemu-system-ppc64 \
    -global virtio-blk-pci.scsi=off \
    -nodefconfig \
    -nodefaults \
    -nographic \
    -M pseries \
    -machine accel=kvm:tcg \
    -m 500 \
    -no-reboot \
    -kernel /home/rjones/d/libguestfs/tmp/.guestfs-1000/kernel.15893 \
    -initrd /home/rjones/d/libguestfs/tmp/.guestfs-1000/initrd.15893 \
    -device virtio-scsi-pci,id=scsi \
    -drive file=/home/rjones/d/libguestfs/tmp/libguestfsedQ0NF/scratch.1,cache=unsafe,format=raw,id=hd0,if=none \
    -device scsi-hd,drive=hd0 \
    -drive file=/home/rjones/d/libguestfs/tmp/.guestfs-1000/root.15893,snapshot=on,id=appliance,cache=unsafe,if=none \
    -device scsi-hd,drive=appliance \
    -device virtio-serial-pci \
    -serial stdio \
    -chardev socket,path=/home/rjones/d/libguestfs/tmp/libguestfsedQ0NF/guestfsd.sock,id=channel0 \
    -device virtserialport,chardev=channel0,name=org.libguestfs.channel.0 \
    -append 'panic=1 console=ttyS0 udevtimeout=600 no_timer_check acpi=off printk.time=1 cgroup_disable=memory root=/dev/sdb selinux=0 guestfs_verbose=1 TERM=xterm-256color'
Comment 7 Fedora Update System 2013-09-13 22:31:17 EDT
qemu-1.4.2-9.fc19 has been pushed to the Fedora 19 stable repository.  If problems still persist, please make note of it in this bug report.

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