Patchwork [Applied] Split TLB addend and target_phys_addr_t

login
register
mail settings
Submitter Paul Brook
Date April 5, 2010, 1:21 a.m.
Message ID <201004050221.08284.paul@codesourcery.com>
Download mbox | patch
Permalink /patch/49363/
State New
Headers show

Comments

Paul Brook - April 5, 2010, 1:21 a.m.
I think I got all the tcg backend bits right, but can't test most of them. Please test and report any problems.

Historically the qemu tlb "addend" field was used for both RAM and IO accesses,
so needed to be able to hold both host addresses (unsigned long) and guest
physical addresses (target_phys_addr_t).  However since the introduction of
the iotlb field it has only been used for RAM accesses.

This means we can change the type of addend to unsigned long, and remove
associated hacks in the big-endian TCG backends.

We can also remove the host dependence from target_phys_addr_t.

Signed-off-by: Paul Brook <paul@codesourcery.com>
---
 configure              |    3 ---
 cpu-defs.h             |   17 +++++++----------
 exec.c                 |    2 +-
 softmmu_template.h     |   28 ++++++++++++++++------------
 targphys.h             |    5 +----
 tcg/mips/tcg-target.c  |    4 ++--
 tcg/ppc/tcg-target.c   |   12 ++----------
 tcg/ppc64/tcg-target.c |   12 ++----------
 tcg/sparc/tcg-target.c |    8 +-------
 9 files changed, 32 insertions(+), 59 deletions(-)
malc - April 5, 2010, 12:41 p.m.
On Mon, 5 Apr 2010, Paul Brook wrote:

> I think I got all the tcg backend bits right, but can't test most of them. Please test and report any problems.
> 
> Historically the qemu tlb "addend" field was used for both RAM and IO accesses,
> so needed to be able to hold both host addresses (unsigned long) and guest
> physical addresses (target_phys_addr_t).  However since the introduction of
> the iotlb field it has only been used for RAM accesses.
> 
> This means we can change the type of addend to unsigned long, and remove
> associated hacks in the big-endian TCG backends.
> 
> We can also remove the host dependence from target_phys_addr_t.
> 
> Signed-off-by: Paul Brook <paul@codesourcery.com>

PPC32 seems to be operational.

Alexander: Can you please test it a bit more thoroughly, my PPCs are a bit
           on the slow side.

[..snip..]
Alexander Graf - April 5, 2010, 9:38 p.m.
On 05.04.2010, at 14:41, malc wrote:

> On Mon, 5 Apr 2010, Paul Brook wrote:
> 
>> I think I got all the tcg backend bits right, but can't test most of them. Please test and report any problems.
>> 
>> Historically the qemu tlb "addend" field was used for both RAM and IO accesses,
>> so needed to be able to hold both host addresses (unsigned long) and guest
>> physical addresses (target_phys_addr_t).  However since the introduction of
>> the iotlb field it has only been used for RAM accesses.
>> 
>> This means we can change the type of addend to unsigned long, and remove
>> associated hacks in the big-endian TCG backends.
>> 
>> We can also remove the host dependence from target_phys_addr_t.
>> 
>> Signed-off-by: Paul Brook <paul@codesourcery.com>
> 
> PPC32 seems to be operational.
> 
> Alexander: Can you please test it a bit more thoroughly, my PPCs are a bit
>           on the slow side.

Test what exactly? Booting random guests with TCG on PPC?


Alex
malc - April 5, 2010, 10:44 p.m.
On Mon, 5 Apr 2010, Alexander Graf wrote:

> 
> On 05.04.2010, at 14:41, malc wrote:
> 
> > On Mon, 5 Apr 2010, Paul Brook wrote:
> > 
> >> I think I got all the tcg backend bits right, but can't test most of them. Please test and report any problems.
> >> 
> >> Historically the qemu tlb "addend" field was used for both RAM and IO accesses,
> >> so needed to be able to hold both host addresses (unsigned long) and guest
> >> physical addresses (target_phys_addr_t).  However since the introduction of
> >> the iotlb field it has only been used for RAM accesses.
> >> 
> >> This means we can change the type of addend to unsigned long, and remove
> >> associated hacks in the big-endian TCG backends.
> >> 
> >> We can also remove the host dependence from target_phys_addr_t.
> >> 
> >> Signed-off-by: Paul Brook <paul@codesourcery.com>
> > 
> > PPC32 seems to be operational.
> > 
> > Alexander: Can you please test it a bit more thoroughly, my PPCs are a bit
> >           on the slow side.
> 
> Test what exactly? Booting random guests with TCG on PPC?

Booting 64 bit guests with 32 bit ppc hosts specifically.
[Testing whether 64bit host still works would be nice too, thanks]
Alexander Graf - April 7, 2010, 3:09 p.m.
malc wrote:
> On Mon, 5 Apr 2010, Alexander Graf wrote:
>
>   
>> On 05.04.2010, at 14:41, malc wrote:
>>
>>     
>>> On Mon, 5 Apr 2010, Paul Brook wrote:
>>>
>>>       
>>>> I think I got all the tcg backend bits right, but can't test most of them. Please test and report any problems.
>>>>
>>>> Historically the qemu tlb "addend" field was used for both RAM and IO accesses,
>>>> so needed to be able to hold both host addresses (unsigned long) and guest
>>>> physical addresses (target_phys_addr_t).  However since the introduction of
>>>> the iotlb field it has only been used for RAM accesses.
>>>>
>>>> This means we can change the type of addend to unsigned long, and remove
>>>> associated hacks in the big-endian TCG backends.
>>>>
>>>> We can also remove the host dependence from target_phys_addr_t.
>>>>
>>>> Signed-off-by: Paul Brook <paul@codesourcery.com>
>>>>         
>>> PPC32 seems to be operational.
>>>
>>> Alexander: Can you please test it a bit more thoroughly, my PPCs are a bit
>>>           on the slow side.
>>>       
>> Test what exactly? Booting random guests with TCG on PPC?
>>     
>
> Booting 64 bit guests with 32 bit ppc hosts specifically.
>   

This is what I get when booting an x86_64 11.2 installation iso on a
ppc32 host (970MP with 32-bit userland):

agraf@lychee:~/git/qemu> ./x86_64-softmmu/qemu-system-x86_64 -vnc :5
-serial stdio -m 1024 -cdrom
/mounts/schnell/CD-ARCHIVE/11.2/iso/openSUSE-11.2-DVD-x86_64.iso
[    0.000000] Initializing cgroup subsys cpuset
[    0.000000] Initializing cgroup subsys cpu
[    0.000000] Linux version 2.6.31.5-0.1-default (geeko@buildhost) (gcc
version 4.4.1 [gcc-4_4-branch revision 150839] (SUSE Linux) ) #1 SMP
2009-10-26 15:49:03 +0100
[    0.000000] Command line: BOOT_IMAGE=linux initrd=initrd,08000600.spl
splash=silent vga=0x314 console=tty console=ttyS0
[    0.000000] KERNEL supported cpus:
[    0.000000]   Intel GenuineIntel
[    0.000000]   AMD AuthenticAMD
[    0.000000]   Centaur CentaurHauls
[    0.000000] BIOS-provided physical RAM map:
[    0.000000]  BIOS-e820: 0000000000000000 - 000000000009f400 (usable)
[    0.000000]  BIOS-e820: 000000000009f400 - 00000000000a0000 (reserved)
[    0.000000]  BIOS-e820: 00000000000f0000 - 0000000000100000 (reserved)
[    0.000000]  BIOS-e820: 0000000000100000 - 000000003fffd000 (usable)
[    0.000000]  BIOS-e820: 000000003fffd000 - 0000000040000000 (reserved)
[    0.000000]  BIOS-e820: 00000000fffc0000 - 0000000100000000 (reserved)
[    0.000000] DMI 2.4 present.
[    0.000000] last_pfn = 0x3fffd max_arch_pfn = 0x400000000
[    0.000000] x86 PAT enabled: cpu 0, old 0x0, new 0x7010600070106
[    0.000000] Scanning 1 areas for low memory corruption
[    0.000000] modified physical RAM map:
[    0.000000]  modified: 0000000000000000 - 0000000000001000 (usable)
[    0.000000]  modified: 0000000000001000 - 0000000000006000 (reserved)
[    0.000000]  modified: 0000000000006000 - 000000000009f400 (usable)
[    0.000000]  modified: 000000000009f400 - 00000000000a0000 (reserved)
[    0.000000]  modified: 00000000000f0000 - 0000000000100000 (reserved)
[    0.000000]  modified: 0000000000100000 - 000000003fffd000 (usable)
[    0.000000]  modified: 000000003fffd000 - 0000000040000000 (reserved)
[    0.000000]  modified: 00000000fffc0000 - 0000000100000000 (reserved)
[    0.000000] init_memory_mapping: 0000000000000000-000000003fffd000
[    0.000000] RAMDISK: 3e7d8000 - 3ffdb28b
[    0.000000] ACPI: RSDP 00000000000f8870 00014 (v00 BOCHS )
[    0.000000] ACPI: RSDT 000000003fffde30 00034 (v01 BOCHS  BXPCRSDT
00000001 BXPC 00000001)
[    0.000000] ACPI: FACP 000000003ffffe70 00074 (v01 BOCHS  BXPCFACP
00000001 BXPC 00000001)
[    0.000000] ACPI: DSDT 000000003fffdfd0 01E22 (v01   BXPC   BXDSDT
00000001 INTL 20090123)
[    0.000000] ACPI: FACS 000000003ffffe00 00040
[    0.000000] ACPI: SSDT 000000003fffdf90 00037 (v01 BOCHS  BXPCSSDT
00000001 BXPC 00000001)
[    0.000000] ACPI: APIC 000000003fffdeb0 00072 (v01 BOCHS  BXPCAPIC
00000001 BXPC 00000001)
[    0.000000] ACPI: HPET 000000003fffde70 00038 (v01 BOCHS  BXPCHPET
00000001 BXPC 00000001)
[    0.000000] No NUMA configuration found
[    0.000000] Faking a node at 0000000000000000-000000003fffd000
[    0.000000] Bootmem setup node 0 0000000000000000-000000003fffd000
[    0.000000]   NODE_DATA [0000000000009000 - 0000000000020fff]
[    0.000000]   bootmap [0000000000021000 -  0000000000028fff] pages 8
[    0.000000] (7 early reservations) ==> bootmem [0000000000 - 003fffd000]
[    0.000000]   #0 [0000000000 - 0000001000]   BIOS data page ==>
[0000000000 - 0000001000]
[    0.000000]   #1 [0000006000 - 0000008000]       TRAMPOLINE ==>
[0000006000 - 0000008000]
[    0.000000]   #2 [0001000000 - 0001c6e8b0]    TEXT DATA BSS ==>
[0001000000 - 0001c6e8b0]
[    0.000000]   #3 [003e7d8000 - 003ffdb28b]          RAMDISK ==>
[003e7d8000 - 003ffdb28b]
[    0.000000]   #4 [000009f400 - 0000100000]    BIOS reserved ==>
[000009f400 - 0000100000]
[    0.000000]   #5 [0001c6f000 - 0001c6f049]              BRK ==>
[0001c6f000 - 0001c6f049]
[    0.000000]   #6 [0000008000 - 0000009000]          PGTABLE ==>
[0000008000 - 0000009000]
[    0.000000] found SMP MP-table at [ffff8800000f88c0] f88c0
[    0.000000] Zone PFN ranges:
[    0.000000]   DMA      0x00000000 -> 0x00001000
[    0.000000]   DMA32    0x00001000 -> 0x00100000
[    0.000000]   Normal   0x00100000 -> 0x00100000
[    0.000000] Movable zone start PFN for each node
[    0.000000] early_node_map[3] active PFN ranges
[    0.000000]     0: 0x00000000 -> 0x00000001
[    0.000000]     0: 0x00000006 -> 0x0000009f
[    0.000000]     0: 0x00000100 -> 0x0003fffd
[    0.000000] ACPI: PM-Timer IO Port: 0xb008
[    0.000000] ACPI: LAPIC (acpi_id[0x00] lapic_id[0x00] enabled)
[    0.000000] ACPI: IOAPIC (id[0x01] address[0xfec00000] gsi_base[0])
[    0.000000] IOAPIC[0]: apic_id 1, version 17, address 0xfec00000, GSI
0-23
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 0 global_irq 2 dfl dfl)
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 5 global_irq 5 high level)
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 9 global_irq 9 high level)
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 10 global_irq 10 high level)
[    0.000000] ACPI: INT_SRC_OVR (bus 0 bus_irq 11 global_irq 11 high level)
[    0.000000] Using ACPI (MADT) for SMP configuration information
[    0.000000] ACPI: HPET id: 0x8086a201 base: 0xfed00000
[    0.000000] SMP: Allowing 1 CPUs, 0 hotplug CPUs
[    0.000000] PM: Registered nosave memory: 0000000000001000 -
0000000000006000
[    0.000000] PM: Registered nosave memory: 000000000009f000 -
00000000000a0000
[    0.000000] PM: Registered nosave memory: 00000000000a0000 -
00000000000f0000
[    0.000000] PM: Registered nosave memory: 00000000000f0000 -
0000000000100000
[    0.000000] Allocating PCI resources starting at 40000000 (gap:
40000000:bffc0000)
[    0.000000] NR_CPUS:512 nr_cpumask_bits:512 nr_cpu_ids:1 nr_node_ids:1
[    0.000000] PERCPU: Embedded 28 pages at ffff880001ca3000, static
data 82912 bytes
[    0.000000] Built 1 zonelists in Node order, mobility grouping on. 
Total pages: 258355
[    0.000000] Policy zone: DMA32
[    0.000000] Kernel command line: BOOT_IMAGE=linux
initrd=initrd,08000600.spl splash=silent vga=0x314 console=tty console=ttyS0
[    0.000000] bootsplash: silent mode.
[    0.000000] PID hash table entries: 4096 (order: 12, 32768 bytes)
[    0.000000] Initializing CPU#0
[    0.000000] Checking aperture...
[    0.000000] No AGP bridge found
[    0.000000] Memory: 996000k/1048564k available (5504k kernel code,
408k absent, 52156k reserved, 4533k data, 1020k init)
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS:4352 nr_irqs:256
[    0.000000] Fast TSC calibration failed
[    0.000000] TSC: PIT calibration matches PMTIMER. 2 loops
[    0.000000] Detected 14.226 MHz processor.
[    0.004000] Console: colour dummy device 80x25
[    0.004000] console [tty0] enabled
[    0.004000] console [ttyS0] enabled
[    0.004000] HPET: 3 timers in total, 0 timers will be used for
per-cpu timer
[    0.009458] Calibrating delay loop (skipped), value calculated using
timer frequency.. 28.45 BogoMIPS (lpj=56904)
[    0.018306] kdb version 4.4 by Keith Owens, Scott Lurndal. Copyright
SGI, All Rights Reserved
kdb_cmd[0]: defcmd archkdb "" "First line arch debugging"
kdb_cmd[7]: defcmd archkdbcpu "" "archkdb with only tasks on cpus"
kdb_cmd[14]: defcmd archkdbshort "" "archkdb with less detailed backtrace"
kdb_cmd[21]: defcmd archkdbcommon "" "Common arch debugging"
[    0.035757] Security Framework initialized
[    0.042764] AppArmor: AppArmor initialized
[    0.051465] Dentry cache hash table entries: 131072 (order: 8,
1048576 bytes)
[    0.068965] Inode-cache hash table entries: 65536 (order: 7, 524288
bytes)
[    0.077585] Mount-cache hash table entries: 256
[    0.103933] Initializing cgroup subsys ns
[    0.104966] Initializing cgroup subsys cpuacct
[    0.106176] Initializing cgroup subsys memory
[    0.109583] Initializing cgroup subsys devices
[    0.110803] Initializing cgroup subsys freezer
[    0.111610] Initializing cgroup subsys net_cls
[    0.116340] CPU: L1 I Cache: 64K (64 bytes/line), D cache 64K (64
bytes/line)
[    0.117530] CPU: L2 Cache: 512K (64 bytes/line)
[    0.118933] CPU 0/0x0 -> Node 0
[    0.120516] mce: CPU supports 10 MCE banks
[    0.123414] Performance Counters: AMD PMU driver.
[    0.124900] ... version:                 0
[    0.125540] ... bit width:               48
[    0.126319] ... generic counters:        4
[    0.127059] ... value mask:              0000ffffffffffff
[    0.128197] ... max period:              00007fffffffffff
[    0.129012] ... fixed-purpose counters:  0
[    0.129631] ... counter mask:            000000000000000f
[    0.131407] SMP alternatives: switching to UP code
[    0.460416] Freeing SMP alternatives: 34k freed
[    0.464227] ACPI: Core revision 20090521
[    0.593347] Setting APIC routing to flat
[    0.605736] ..TIMER: vector=0x30 apic1=0 pin1=2 apic2=-1 pin2=-1
[    0.648502] CPU0: AMD QEMU Virtual CPU version 0.12.50 stepping 03
[    0.664698] Brought up 1 CPUs
[    0.665611] Total of 1 processors activated (28.45 BogoMIPS).
[    0.687857] devtmpfs: initialized
[    0.883925] Booting paravirtualized kernel on bare hardware
[    0.896241] regulator: core version 0.5
[    0.898110] Time: 15:01:21  Date: 04/07/10
[    0.904680] NET: Registered protocol family 16
[    0.926350] ACPI: bus type pci registered
[    0.933781] PCI: Using configuration type 1 for base access
[    0.997003] bio: create slab <bio-0> at 0
[    1.239546] ACPI: Interpreter enabled
[    1.240240] ACPI: (supports S0 S3 S4 S5)
[    1.245116] ACPI: Using IOAPIC for interrupt routing
[    1.489740] ACPI: No dock devices found.
[    1.495956] ACPI: PCI Root Bridge [PCI0] (0000:00)
[    1.509770] pci 0000:00:01.3: quirk: region b000-b03f claimed by
PIIX4 ACPI
[    1.511081] pci 0000:00:01.3: quirk: region b100-b10f claimed by
PIIX4 SMB
[    1.727181] ACPI: PCI Interrupt Link [LNKA] (IRQs 5 *10 11)
[    1.735198] ACPI: PCI Interrupt Link [LNKB] (IRQs 5 *10 11)
[    1.742612] ACPI: PCI Interrupt Link [LNKC] (IRQs 5 10 *11)
[    1.750170] ACPI: PCI Interrupt Link [LNKD] (IRQs 5 10 *11)
[    1.765314] SCSI subsystem initialized
[    1.775202] usbcore: registered new interface driver usbfs
[    1.777926] usbcore: registered new interface driver hub
[    1.781709] usbcore: registered new device driver usb
[    1.790324] PCI: Using ACPI for IRQ routing
[    1.810563] hpet0: at MMIO 0xfed00000, IRQs 2, 8, 0
[    1.811830] hpet0: 3 comparators, 64-bit 100.000000 MHz counter
[    1.912775] AppArmor: AppArmor Filesystem Enabled
[    1.915885] pnp: PnP ACPI init
[    1.917672] ACPI: bus type pnp registered
[    1.977819] pnp: PnP ACPI: found 8 devices
[    1.978732] ACPI: ACPI bus type pnp unregistered
[    2.009723] NET: Registered protocol family 2
[    2.019395] IP route cache hash table entries: 32768 (order: 6,
262144 bytes)
[    2.061775] TCP established hash table entries: 131072 (order: 9,
2097152 bytes)
[    2.088712] TCP bind hash table entries: 65536 (order: 8, 1048576 bytes)
[    2.099693] TCP: Hash tables configured (established 131072 bind 65536)
[    2.101381] TCP reno registered
[    2.109590] NET: Registered protocol family 1
[    2.123725] Unpacking initramfs...
[    2.148288] Freeing initrd memory: 24588k freed
[    2.148288] Scanning for low memory corruption every 60 seconds
[    2.148288] audit: initializing netlink socket (disabled)
[    2.148288] type=2000 audit(1270652481.144:1): initialized
[    2.148288] HugeTLB registered 2 MB page size, pre-allocated 0 pages
[    2.148288] VFS: Disk quotas dquot_6.5.2
[    2.148288] Dquot-cache hash table entries: 512 (order 0, 4096 bytes)
[    2.148288] msgmni has been set to 498
[    2.148288] Block layer SCSI generic (bsg) driver version 0.4 loaded
(major 253)
[    2.148288] io scheduler noop registered
[    2.148288] io scheduler anticipatory registered
[    2.148288] io scheduler deadline registered
[    2.148288] io scheduler cfq registered (default)
[    2.148288] pci 0000:00:00.0: Limiting direct PCI/PCI transfers
[    2.148288] pci 0000:00:01.0: PIIX3: Enabling Passive Release
[    2.148288] pci 0000:00:01.0: Activating ISA DMA hang workarounds
[    2.148288] pci-stub: invalid id string ""
[    2.148288] vesafb: framebuffer at 0xf0000000, mapped to
0xffffc90000580000, using 1875k, total 4096k
[    2.148288] vesafb: mode is 800x600x16, linelength=1600, pages=3
[    2.148288] vesafb: scrolling: redraw
[    2.148288] vesafb: Truecolor: size=0:5:6:5, shift=0:11:5:0
[    2.148288] bootsplash 3.1.6-2004/03/31: looking for picture...
[    2.148288] bootsplash: silentjpeg size 71362 bytes
[    2.148288] bootsplash: ...found (800x600, 24018 bytes, v3).
[    2.148288] Console: switching to colour frame buffer device 96x33
[    2.148288] fb0: VESA VGA frame buffer device
[    2.148288] Non-volatile memory driver v1.3
[    2.148288] Linux agpgart interface v0.103
[    2.148288] Serial: 8250/16550 driver, 8 ports, IRQ sharing disabled
[    2.148288] serial8250: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
[    2.148288] 00:06: ttyS0 at I/O 0x3f8 (irq = 4) is a 16550A
[    2.148288] scsi0 : ata_piix
[    2.148288] scsi1 : ata_piix
[    2.148288] ata1: PATA max MWDMA2 cmd 0x1f0 ctl 0x3f6 bmdma 0xc000 irq 14
[    2.148288] ata2: PATA max MWDMA2 cmd 0x170 ctl 0x376 bmdma 0xc008 irq 15
[    2.148288] Fixed MDIO Bus: probed
[    2.148288] ehci_hcd: USB 2.0 'Enhanced' Host Controller (EHCI) Driver
[    2.148288] ohci_hcd: USB 1.1 'Open' Host Controller (OHCI) Driver
[    2.148288] uhci_hcd: USB Universal Host Controller Interface driver
[    2.148288] Initializing USB Mass Storage driver...
[    2.148288] usbcore: registered new interface driver usb-storage
[    2.148288] USB Mass Storage support registered.
[    2.148288] usbcore: registered new interface driver libusual
[    2.148288] usbcore: registered new interface driver ums-alauda
[    2.148288] usbcore: registered new interface driver ums-cypress
[    2.148288] usbcore: registered new interface driver ums-datafab
[    2.148288] usbcore: registered new interface driver ums-freecom
[    2.148288] usbcore: registered new interface driver ums-isd200
[    2.148288] usbcore: registered new interface driver ums-jumpshot
[    2.148288] usbcore: registered new interface driver ums-karma
[    2.148288] usbcore: registered new interface driver ums-onetouch
[    2.148288] usbcore: registered new interface driver ums-sddr09
[    2.148288] usbcore: registered new interface driver ums-sddr55
[    2.148288] usbcore: registered new interface driver ums-usbat
[    2.148288] PNP: PS/2 Controller [PNP0303:KBD,PNP0f13:MOU] at
0x60,0x64 irq 1,12
[    2.148288] serio: i8042 KBD port at 0x60,0x64 irq 1
[    2.148288] serio: i8042 AUX port at 0x60,0x64 irq 12
[    2.148288] mice: PS/2 mouse device common for all mice
[    2.148288] input: AT Translated Set 2 keyboard as
/devices/platform/i8042/serio0/input/input0
[    2.148288] rtc_cmos 00:01: rtc core: registered rtc_cmos as rtc0
[    2.148288] rtc0: alarms up to one day, 114 bytes nvram, hpet irqs
[    2.148288] cpuidle: using governor ladder
[    2.148288] cpuidle: using governor menu
[    2.148288] usbcore: registered new interface driver hiddev
[    2.148288] usbcore: registered new interface driver usbhid
[    2.148288] usbhid: v2.6:USB HID core driver
[    2.148288] TCP cubic registered
[    2.148288] NET: Registered protocol family 10
[    2.148288] lo: Disabled Privacy Extensions
[    2.148288] lib80211: common routines for IEEE802.11 drivers
[    2.148288] registered taskstats version 1
[    2.148288]   Magic number: 6:65:32
[    2.148288] rtc_cmos 00:01: setting system clock to 2010-04-07
15:01:35 UTC (1270652495)

*** sits here in hlt ***

Almost looks like a timekeeping issue, no? And yes, I tried to revert
4a9590f32e5692114aaae4ca10da89dac633e164 - no change.

> [Testing whether 64bit host still works would be nice too, thanks]
>   

That one looks good.



Alex
Alexander Graf - April 7, 2010, 3:20 p.m.
Alexander Graf wrote:
> [    2.148288] registered taskstats version 1
> [    2.148288]   Magic number: 6:65:32
> [    2.148288] rtc_cmos 00:01: setting system clock to 2010-04-07
> 15:01:35 UTC (1270652495)
>
> *** sits here in hlt ***
>
> Almost looks like a timekeeping issue, no? And yes, I tried to revert
> 4a9590f32e5692114aaae4ca10da89dac633e164 - no change.
>   

The guest is still alive and reacts to SysRq though. This is sysrq-l
(active process) and sysrq-q (timer info) output:

[  246.635200] SysRq : Show backtrace of all active CPUs
[  246.638500] CPU0:
[  246.638500] CPU 0:
[  246.638500] Modules linked in:
[  246.638500] Pid: 0, comm: swapper Not tainted 2.6.31.5-0.1-default #1
Bochs
[  246.638500] RIP: 0010:[<ffffffff81039766>]  [<ffffffff81039766>]
native_safe_halt+0x6/0x10
[  246.638500] RSP: 0018:ffffffff818bfe78  EFLAGS: 00000286
[  246.638500] RAX: 0000000000000000 RBX: ffffffff818bfe78 RCX:
0000000000000000
[  246.638500] RDX: 0000000000000000 RSI: 0000000000000000 RDI:
ffffffff81adb2c8
[  246.638500] RBP: ffffffff8100d00e R08: 0000000000000000 R09:
0000000000000001
[  246.638500] R10: 0000000000000001 R11: 00000000fffedd21 R12:
008a90db4ea6a915
[  246.638500] R13: ffffffff818bfde8 R14: ffffffff81014b7d R15:
ffffffff818bfdd8
[  246.638500] FS:  0000000000000000(0000) GS:ffff880001ca3000(0000)
knlGS:0000000000000000
[  246.638500] CS:  0010 DS: 0018 ES: 0018 CR0: 000000008005003b
[  246.638500] CR2: 0000000000000000 CR3: 0000000001001000 CR4:
00000000000006f0
[  246.638500] DR0: 0000000000000000 DR1: 0000000000000000 DR2:
0000000000000000
[  246.638500] DR3: 0000000000000000 DR6: 0000000000000000 DR7:
0000000000000000
[  246.638500] Call Trace:
[  246.638500] Inexact backtrace:
[  246.638500]
[  246.638500]  [<ffffffff810168c2>] ? default_idle+0x62/0x120
[  246.638500]  [<ffffffff8100b44c>] ? cpu_idle+0xcc/0x120
[  246.638500]  [<ffffffff8153da49>] ? rest_init+0x79/0xa0
[  246.638500]  [<ffffffff819e4766>] ? start_kernel+0x3db/0x3f8
[  246.638500]  [<ffffffff819e370d>] ? x86_64_start_reservations+0x134/0x14f
[  246.638500]  [<ffffffff819e3883>] ? x86_64_start_kernel+0x15b/0x17e
[  265.202817] SysRq : Show clockevent devices & pending hrtimers (no
others)
[  265.206127] Timer List Version: v0.4
[  265.206127] HRTIMER_MAX_CLOCK_BASES: 2
[  265.206127] now at 265207060508 nsecs
[  265.206127]
[  265.206127] cpu: 0
[  265.206127]  clock 0:
[  265.206127]   .base:       ffff880001cb1f68
[  265.206127]   .index:      0
[  265.206127]   .resolution: 1 nsecs
[  265.206127]   .get_time:   ktime_get_real
[  265.206127]   .offset:     1270652799620743573 nsecs
[  265.206127] active timers:
[  265.206127]  clock 1:
[  265.206127]   .base:       ffff880001cb1fa8
[  265.206127]   .index:      1
[  265.206127]   .resolution: 1 nsecs
[  265.206127]   .get_time:   ktime_get
[  265.206127]   .offset:     0 nsecs
[  265.206127] active timers:
[  265.206127]  #0: <ffff880001cb2040>, tick_sched_timer, S:01,
<(null)>, /-1
[  265.206127]  # expires at 9223372036854775807-9223372036854775807
nsecs [in 9223371771647715299 to 9223371771647715299 nsecs]
[  265.206127]   .expires_next   : 9223372036854775807 nsecs
[  265.206127]   .hres_active    : 1
[  265.206127]   .nr_events      : 82
[  265.206127]   .nohz_mode      : 2
[  265.206127]   .idle_tick      : 0 nsecs
[  265.206127]   .tick_stopped   : 0
[  265.206127]   .idle_jiffies   : 0
[  265.206127]   .idle_calls     : 7
[  265.206127]   .idle_sleeps    : 0
[  265.206127]   .idle_entrytime : 246738695612 nsecs
[  265.206127]   .idle_waketime  : 0 nsecs
[  265.206127]   .idle_exittime  : 0 nsecs
[  265.206127]   .idle_sleeptime : 250185168614 nsecs
[  265.206127]   .last_jiffies   : 4294892832
[  265.206127]   .next_jiffies   : 4294892833
[  265.206127]   .idle_expires   : 0 nsecs
[  265.206127] jiffies: 4294892832
[  265.206127]
[  265.206127]
[  265.206127] Tick Device: mode:     1
[  265.206127] Broadcast device
[  265.206127] Clock Event Device: hpet
[  265.206127]  max_delta_ns:   21474836500
[  265.206127]  min_delta_ns:   5000
[  265.206127]  mult:           429496729
[  265.206127]  shift:          32
[  265.206127]  mode:           3
[  265.206127]  next_event:     9223372036854775807 nsecs
[  265.206127]  set_next_event: hpet_legacy_next_event
[  265.206127]  set_mode:       hpet_legacy_set_mode
[  265.206127]  event_handler:  tick_handle_oneshot_broadcast
[  265.206127] tick_broadcast_mask: 00000000
[  265.206127] tick_broadcast_oneshot_mask: 00000000
[  265.206127]
[  265.206127]
[  265.206127] Tick Device: mode:     1
[  265.206127] Per CPU device: 0
[  265.206127] Clock Event Device: lapic
[  265.206127]  max_delta_ns:   134229000
[  265.206127]  min_delta_ns:   1000
[  265.206127]  mult:           268412881
[  265.206127]  shift:          32
[  265.206127]  mode:           3
[  265.206127]  next_event:     9223372036854775807 nsecs
[  265.206127]  set_next_event: lapic_next_event
[  265.206127]  set_mode:       lapic_timer_setup
[  265.206127]  event_handler:  hrtimer_interrupt
[  265.206127]


Alex
malc - April 7, 2010, 4:32 p.m.
On Wed, 7 Apr 2010, Alexander Graf wrote:

> Alexander Graf wrote:
> > [    2.148288] registered taskstats version 1
> > [    2.148288]   Magic number: 6:65:32
> > [    2.148288] rtc_cmos 00:01: setting system clock to 2010-04-07
> > 15:01:35 UTC (1270652495)
> >
> > *** sits here in hlt ***
> >
> > Almost looks like a timekeeping issue, no? And yes, I tried to revert
> > 4a9590f32e5692114aaae4ca10da89dac633e164 - no change.
> >   
> 
> The guest is still alive and reacts to SysRq though. This is sysrq-l
> (active process) and sysrq-q (timer info) output:
> 
> [  246.635200] SysRq : Show backtrace of all active CPUs
> [  246.638500] CPU0:
> [  246.638500] CPU 0:
> [  246.638500] Modules linked in:
> [  246.638500] Pid: 0, comm: swapper Not tainted 2.6.31.5-0.1-default #1
> Bochs
> [  246.638500] RIP: 0010:[<ffffffff81039766>]  [<ffffffff81039766>]
> native_safe_halt+0x6/0x10
> [  246.638500] RSP: 0018:ffffffff818bfe78  EFLAGS: 00000286
> [  246.638500] RAX: 0000000000000000 RBX: ffffffff818bfe78 RCX:
> 0000000000000000
> [  246.638500] RDX: 0000000000000000 RSI: 0000000000000000 RDI:
> ffffffff81adb2c8
> [  246.638500] RBP: ffffffff8100d00e R08: 0000000000000000 R09:
> 0000000000000001
> [  246.638500] R10: 0000000000000001 R11: 00000000fffedd21 R12:
> 008a90db4ea6a915
> [  246.638500] R13: ffffffff818bfde8 R14: ffffffff81014b7d R15:
> ffffffff818bfdd8
> [  246.638500] FS:  0000000000000000(0000) GS:ffff880001ca3000(0000)
> knlGS:0000000000000000
> [  246.638500] CS:  0010 DS: 0018 ES: 0018 CR0: 000000008005003b
> [  246.638500] CR2: 0000000000000000 CR3: 0000000001001000 CR4:
> 00000000000006f0
> [  246.638500] DR0: 0000000000000000 DR1: 0000000000000000 DR2:
> 0000000000000000
> [  246.638500] DR3: 0000000000000000 DR6: 0000000000000000 DR7:
> 0000000000000000
> [  246.638500] Call Trace:
> [  246.638500] Inexact backtrace:
> [  246.638500]
> [  246.638500]  [<ffffffff810168c2>] ? default_idle+0x62/0x120
> [  246.638500]  [<ffffffff8100b44c>] ? cpu_idle+0xcc/0x120
> [  246.638500]  [<ffffffff8153da49>] ? rest_init+0x79/0xa0
> [  246.638500]  [<ffffffff819e4766>] ? start_kernel+0x3db/0x3f8
> [  246.638500]  [<ffffffff819e370d>] ? x86_64_start_reservations+0x134/0x14f
> [  246.638500]  [<ffffffff819e3883>] ? x86_64_start_kernel+0x15b/0x17e
> [  265.202817] SysRq : Show clockevent devices & pending hrtimers (no
> others)
> [  265.206127] Timer List Version: v0.4
> [  265.206127] HRTIMER_MAX_CLOCK_BASES: 2
> [  265.206127] now at 265207060508 nsecs
> [  265.206127]
> [  265.206127] cpu: 0
> [  265.206127]  clock 0:
> [  265.206127]   .base:       ffff880001cb1f68
> [  265.206127]   .index:      0
> [  265.206127]   .resolution: 1 nsecs
> [  265.206127]   .get_time:   ktime_get_real
> [  265.206127]   .offset:     1270652799620743573 nsecs
> [  265.206127] active timers:
> [  265.206127]  clock 1:
> [  265.206127]   .base:       ffff880001cb1fa8
> [  265.206127]   .index:      1
> [  265.206127]   .resolution: 1 nsecs
> [  265.206127]   .get_time:   ktime_get
> [  265.206127]   .offset:     0 nsecs
> [  265.206127] active timers:
> [  265.206127]  #0: <ffff880001cb2040>, tick_sched_timer, S:01,
> <(null)>, /-1
> [  265.206127]  # expires at 9223372036854775807-9223372036854775807
> nsecs [in 9223371771647715299 to 9223371771647715299 nsecs]
> [  265.206127]   .expires_next   : 9223372036854775807 nsecs
> [  265.206127]   .hres_active    : 1
> [  265.206127]   .nr_events      : 82
> [  265.206127]   .nohz_mode      : 2
> [  265.206127]   .idle_tick      : 0 nsecs
> [  265.206127]   .tick_stopped   : 0
> [  265.206127]   .idle_jiffies   : 0
> [  265.206127]   .idle_calls     : 7
> [  265.206127]   .idle_sleeps    : 0
> [  265.206127]   .idle_entrytime : 246738695612 nsecs
> [  265.206127]   .idle_waketime  : 0 nsecs
> [  265.206127]   .idle_exittime  : 0 nsecs
> [  265.206127]   .idle_sleeptime : 250185168614 nsecs
> [  265.206127]   .last_jiffies   : 4294892832
> [  265.206127]   .next_jiffies   : 4294892833
> [  265.206127]   .idle_expires   : 0 nsecs
> [  265.206127] jiffies: 4294892832
> [  265.206127]
> [  265.206127]
> [  265.206127] Tick Device: mode:     1
> [  265.206127] Broadcast device
> [  265.206127] Clock Event Device: hpet
> [  265.206127]  max_delta_ns:   21474836500
> [  265.206127]  min_delta_ns:   5000
> [  265.206127]  mult:           429496729
> [  265.206127]  shift:          32
> [  265.206127]  mode:           3
> [  265.206127]  next_event:     9223372036854775807 nsecs
> [  265.206127]  set_next_event: hpet_legacy_next_event
> [  265.206127]  set_mode:       hpet_legacy_set_mode
> [  265.206127]  event_handler:  tick_handle_oneshot_broadcast
> [  265.206127] tick_broadcast_mask: 00000000
> [  265.206127] tick_broadcast_oneshot_mask: 00000000
> [  265.206127]
> [  265.206127]
> [  265.206127] Tick Device: mode:     1
> [  265.206127] Per CPU device: 0
> [  265.206127] Clock Event Device: lapic
> [  265.206127]  max_delta_ns:   134229000
> [  265.206127]  min_delta_ns:   1000
> [  265.206127]  mult:           268412881
> [  265.206127]  shift:          32
> [  265.206127]  mode:           3
> [  265.206127]  next_event:     9223372036854775807 nsecs
> [  265.206127]  set_next_event: lapic_next_event
> [  265.206127]  set_mode:       lapic_timer_setup
> [  265.206127]  event_handler:  hrtimer_interrupt
> [  265.206127]
> 

Any chance of bisecting this?
Alexander Graf - April 7, 2010, 4:40 p.m.
malc wrote:
> On Wed, 7 Apr 2010, Alexander Graf wrote:
>
>   
>> Alexander Graf wrote:
>>     
>>> [    2.148288] registered taskstats version 1
>>> [    2.148288]   Magic number: 6:65:32
>>> [    2.148288] rtc_cmos 00:01: setting system clock to 2010-04-07
>>> 15:01:35 UTC (1270652495)
>>>
>>> *** sits here in hlt ***
>>>
>>> Almost looks like a timekeeping issue, no? And yes, I tried to revert
>>> 4a9590f32e5692114aaae4ca10da89dac633e164 - no change.
>>>   
>>>       
>> The guest is still alive and reacts to SysRq though. This is sysrq-l
>> (active process) and sysrq-q (timer info) output:
>>
>> [  246.635200] SysRq : Show backtrace of all active CPUs
>> [  246.638500] CPU0:
>> [  246.638500] CPU 0:
>> [  246.638500] Modules linked in:
>> [  246.638500] Pid: 0, comm: swapper Not tainted 2.6.31.5-0.1-default #1
>> Bochs
>> [  246.638500] RIP: 0010:[<ffffffff81039766>]  [<ffffffff81039766>]
>> native_safe_halt+0x6/0x10
>> [  246.638500] RSP: 0018:ffffffff818bfe78  EFLAGS: 00000286
>> [  246.638500] RAX: 0000000000000000 RBX: ffffffff818bfe78 RCX:
>> 0000000000000000
>> [  246.638500] RDX: 0000000000000000 RSI: 0000000000000000 RDI:
>> ffffffff81adb2c8
>> [  246.638500] RBP: ffffffff8100d00e R08: 0000000000000000 R09:
>> 0000000000000001
>> [  246.638500] R10: 0000000000000001 R11: 00000000fffedd21 R12:
>> 008a90db4ea6a915
>> [  246.638500] R13: ffffffff818bfde8 R14: ffffffff81014b7d R15:
>> ffffffff818bfdd8
>> [  246.638500] FS:  0000000000000000(0000) GS:ffff880001ca3000(0000)
>> knlGS:0000000000000000
>> [  246.638500] CS:  0010 DS: 0018 ES: 0018 CR0: 000000008005003b
>> [  246.638500] CR2: 0000000000000000 CR3: 0000000001001000 CR4:
>> 00000000000006f0
>> [  246.638500] DR0: 0000000000000000 DR1: 0000000000000000 DR2:
>> 0000000000000000
>> [  246.638500] DR3: 0000000000000000 DR6: 0000000000000000 DR7:
>> 0000000000000000
>> [  246.638500] Call Trace:
>> [  246.638500] Inexact backtrace:
>> [  246.638500]
>> [  246.638500]  [<ffffffff810168c2>] ? default_idle+0x62/0x120
>> [  246.638500]  [<ffffffff8100b44c>] ? cpu_idle+0xcc/0x120
>> [  246.638500]  [<ffffffff8153da49>] ? rest_init+0x79/0xa0
>> [  246.638500]  [<ffffffff819e4766>] ? start_kernel+0x3db/0x3f8
>> [  246.638500]  [<ffffffff819e370d>] ? x86_64_start_reservations+0x134/0x14f
>> [  246.638500]  [<ffffffff819e3883>] ? x86_64_start_kernel+0x15b/0x17e
>> [  265.202817] SysRq : Show clockevent devices & pending hrtimers (no
>> others)
>> [  265.206127] Timer List Version: v0.4
>> [  265.206127] HRTIMER_MAX_CLOCK_BASES: 2
>> [  265.206127] now at 265207060508 nsecs
>> [  265.206127]
>> [  265.206127] cpu: 0
>> [  265.206127]  clock 0:
>> [  265.206127]   .base:       ffff880001cb1f68
>> [  265.206127]   .index:      0
>> [  265.206127]   .resolution: 1 nsecs
>> [  265.206127]   .get_time:   ktime_get_real
>> [  265.206127]   .offset:     1270652799620743573 nsecs
>> [  265.206127] active timers:
>> [  265.206127]  clock 1:
>> [  265.206127]   .base:       ffff880001cb1fa8
>> [  265.206127]   .index:      1
>> [  265.206127]   .resolution: 1 nsecs
>> [  265.206127]   .get_time:   ktime_get
>> [  265.206127]   .offset:     0 nsecs
>> [  265.206127] active timers:
>> [  265.206127]  #0: <ffff880001cb2040>, tick_sched_timer, S:01,
>> <(null)>, /-1
>> [  265.206127]  # expires at 9223372036854775807-9223372036854775807
>> nsecs [in 9223371771647715299 to 9223371771647715299 nsecs]
>> [  265.206127]   .expires_next   : 9223372036854775807 nsecs
>> [  265.206127]   .hres_active    : 1
>> [  265.206127]   .nr_events      : 82
>> [  265.206127]   .nohz_mode      : 2
>> [  265.206127]   .idle_tick      : 0 nsecs
>> [  265.206127]   .tick_stopped   : 0
>> [  265.206127]   .idle_jiffies   : 0
>> [  265.206127]   .idle_calls     : 7
>> [  265.206127]   .idle_sleeps    : 0
>> [  265.206127]   .idle_entrytime : 246738695612 nsecs
>> [  265.206127]   .idle_waketime  : 0 nsecs
>> [  265.206127]   .idle_exittime  : 0 nsecs
>> [  265.206127]   .idle_sleeptime : 250185168614 nsecs
>> [  265.206127]   .last_jiffies   : 4294892832
>> [  265.206127]   .next_jiffies   : 4294892833
>> [  265.206127]   .idle_expires   : 0 nsecs
>> [  265.206127] jiffies: 4294892832
>> [  265.206127]
>> [  265.206127]
>> [  265.206127] Tick Device: mode:     1
>> [  265.206127] Broadcast device
>> [  265.206127] Clock Event Device: hpet
>> [  265.206127]  max_delta_ns:   21474836500
>> [  265.206127]  min_delta_ns:   5000
>> [  265.206127]  mult:           429496729
>> [  265.206127]  shift:          32
>> [  265.206127]  mode:           3
>> [  265.206127]  next_event:     9223372036854775807 nsecs
>> [  265.206127]  set_next_event: hpet_legacy_next_event
>> [  265.206127]  set_mode:       hpet_legacy_set_mode
>> [  265.206127]  event_handler:  tick_handle_oneshot_broadcast
>> [  265.206127] tick_broadcast_mask: 00000000
>> [  265.206127] tick_broadcast_oneshot_mask: 00000000
>> [  265.206127]
>> [  265.206127]
>> [  265.206127] Tick Device: mode:     1
>> [  265.206127] Per CPU device: 0
>> [  265.206127] Clock Event Device: lapic
>> [  265.206127]  max_delta_ns:   134229000
>> [  265.206127]  min_delta_ns:   1000
>> [  265.206127]  mult:           268412881
>> [  265.206127]  shift:          32
>> [  265.206127]  mode:           3
>> [  265.206127]  next_event:     9223372036854775807 nsecs
>> [  265.206127]  set_next_event: lapic_next_event
>> [  265.206127]  set_mode:       lapic_timer_setup
>> [  265.206127]  event_handler:  hrtimer_interrupt
>> [  265.206127]
>>
>>     
>
> Any chance of bisecting this?
>   


I'm not sure it worked before and I also don't really have time for it
right now either :-(. Sorry.


Alex
malc - April 17, 2010, 4:07 a.m.
On Wed, 7 Apr 2010, malc wrote:

> On Wed, 7 Apr 2010, Alexander Graf wrote:
> 
> > Alexander Graf wrote:
> > > [    2.148288] registered taskstats version 1
> > > [    2.148288]   Magic number: 6:65:32
> > > [    2.148288] rtc_cmos 00:01: setting system clock to 2010-04-07
> > > 15:01:35 UTC (1270652495)
> > >
> > > *** sits here in hlt ***
> > >
> > > Almost looks like a timekeeping issue, no? And yes, I tried to revert
> > > 4a9590f32e5692114aaae4ca10da89dac633e164 - no change.
> > >   
> > 
> > The guest is still alive and reacts to SysRq though. This is sysrq-l
> > (active process) and sysrq-q (timer info) output:
> > 
> > [  246.635200] SysRq : Show backtrace of all active CPUs
> > [  246.638500] CPU0:
> > [  246.638500] CPU 0:
> > [  246.638500] Modules linked in:
> > [  246.638500] Pid: 0, comm: swapper Not tainted 2.6.31.5-0.1-default #1
> > Bochs
> > [  246.638500] RIP: 0010:[<ffffffff81039766>]  [<ffffffff81039766>]
> > native_safe_halt+0x6/0x10
> > [  246.638500] RSP: 0018:ffffffff818bfe78  EFLAGS: 00000286
> > [  246.638500] RAX: 0000000000000000 RBX: ffffffff818bfe78 RCX:
> > 0000000000000000
> > [  246.638500] RDX: 0000000000000000 RSI: 0000000000000000 RDI:
> > ffffffff81adb2c8
> > [  246.638500] RBP: ffffffff8100d00e R08: 0000000000000000 R09:
> > 0000000000000001
> > [  246.638500] R10: 0000000000000001 R11: 00000000fffedd21 R12:
> > 008a90db4ea6a915
> > [  246.638500] R13: ffffffff818bfde8 R14: ffffffff81014b7d R15:
> > ffffffff818bfdd8
> > [  246.638500] FS:  0000000000000000(0000) GS:ffff880001ca3000(0000)
> > knlGS:0000000000000000
> > [  246.638500] CS:  0010 DS: 0018 ES: 0018 CR0: 000000008005003b
> > [  246.638500] CR2: 0000000000000000 CR3: 0000000001001000 CR4:
> > 00000000000006f0
> > [  246.638500] DR0: 0000000000000000 DR1: 0000000000000000 DR2:
> > 0000000000000000
> > [  246.638500] DR3: 0000000000000000 DR6: 0000000000000000 DR7:
> > 0000000000000000
> > [  246.638500] Call Trace:
> > [  246.638500] Inexact backtrace:
> > [  246.638500]
> > [  246.638500]  [<ffffffff810168c2>] ? default_idle+0x62/0x120
> > [  246.638500]  [<ffffffff8100b44c>] ? cpu_idle+0xcc/0x120
> > [  246.638500]  [<ffffffff8153da49>] ? rest_init+0x79/0xa0
> > [  246.638500]  [<ffffffff819e4766>] ? start_kernel+0x3db/0x3f8
> > [  246.638500]  [<ffffffff819e370d>] ? x86_64_start_reservations+0x134/0x14f
> > [  246.638500]  [<ffffffff819e3883>] ? x86_64_start_kernel+0x15b/0x17e
> > [  265.202817] SysRq : Show clockevent devices & pending hrtimers (no
> > others)
> > [  265.206127] Timer List Version: v0.4
> > [  265.206127] HRTIMER_MAX_CLOCK_BASES: 2
> > [  265.206127] now at 265207060508 nsecs
> > [  265.206127]
> > [  265.206127] cpu: 0
> > [  265.206127]  clock 0:
> > [  265.206127]   .base:       ffff880001cb1f68
> > [  265.206127]   .index:      0
> > [  265.206127]   .resolution: 1 nsecs
> > [  265.206127]   .get_time:   ktime_get_real
> > [  265.206127]   .offset:     1270652799620743573 nsecs
> > [  265.206127] active timers:
> > [  265.206127]  clock 1:
> > [  265.206127]   .base:       ffff880001cb1fa8
> > [  265.206127]   .index:      1
> > [  265.206127]   .resolution: 1 nsecs
> > [  265.206127]   .get_time:   ktime_get
> > [  265.206127]   .offset:     0 nsecs
> > [  265.206127] active timers:
> > [  265.206127]  #0: <ffff880001cb2040>, tick_sched_timer, S:01,
> > <(null)>, /-1
> > [  265.206127]  # expires at 9223372036854775807-9223372036854775807
> > nsecs [in 9223371771647715299 to 9223371771647715299 nsecs]
> > [  265.206127]   .expires_next   : 9223372036854775807 nsecs
> > [  265.206127]   .hres_active    : 1
> > [  265.206127]   .nr_events      : 82
> > [  265.206127]   .nohz_mode      : 2
> > [  265.206127]   .idle_tick      : 0 nsecs
> > [  265.206127]   .tick_stopped   : 0
> > [  265.206127]   .idle_jiffies   : 0
> > [  265.206127]   .idle_calls     : 7
> > [  265.206127]   .idle_sleeps    : 0
> > [  265.206127]   .idle_entrytime : 246738695612 nsecs
> > [  265.206127]   .idle_waketime  : 0 nsecs
> > [  265.206127]   .idle_exittime  : 0 nsecs
> > [  265.206127]   .idle_sleeptime : 250185168614 nsecs
> > [  265.206127]   .last_jiffies   : 4294892832
> > [  265.206127]   .next_jiffies   : 4294892833
> > [  265.206127]   .idle_expires   : 0 nsecs
> > [  265.206127] jiffies: 4294892832
> > [  265.206127]
> > [  265.206127]
> > [  265.206127] Tick Device: mode:     1
> > [  265.206127] Broadcast device
> > [  265.206127] Clock Event Device: hpet
> > [  265.206127]  max_delta_ns:   21474836500
> > [  265.206127]  min_delta_ns:   5000
> > [  265.206127]  mult:           429496729
> > [  265.206127]  shift:          32
> > [  265.206127]  mode:           3
> > [  265.206127]  next_event:     9223372036854775807 nsecs
> > [  265.206127]  set_next_event: hpet_legacy_next_event
> > [  265.206127]  set_mode:       hpet_legacy_set_mode
> > [  265.206127]  event_handler:  tick_handle_oneshot_broadcast
> > [  265.206127] tick_broadcast_mask: 00000000
> > [  265.206127] tick_broadcast_oneshot_mask: 00000000
> > [  265.206127]
> > [  265.206127]
> > [  265.206127] Tick Device: mode:     1
> > [  265.206127] Per CPU device: 0
> > [  265.206127] Clock Event Device: lapic
> > [  265.206127]  max_delta_ns:   134229000
> > [  265.206127]  min_delta_ns:   1000
> > [  265.206127]  mult:           268412881
> > [  265.206127]  shift:          32
> > [  265.206127]  mode:           3
> > [  265.206127]  next_event:     9223372036854775807 nsecs
> > [  265.206127]  set_next_event: lapic_next_event
> > [  265.206127]  set_mode:       lapic_timer_setup
> > [  265.206127]  event_handler:  hrtimer_interrupt
> > [  265.206127]
> > 
> 
> Any chance of bisecting this?
> 

Should, hopefully, be fixed  by: efe72c8de7b5f07bf8348d51ed4bb4f004e50748

Patch

diff --git a/configure b/configure
index 73d566f..1d5fb17 100755
--- a/configure
+++ b/configure
@@ -2538,9 +2538,6 @@  if [ "$TARGET_ABI_DIR" = "" ]; then
   TARGET_ABI_DIR=$TARGET_ARCH
 fi
 echo "TARGET_ABI_DIR=$TARGET_ABI_DIR" >> $config_target_mak
-if [ $target_phys_bits -lt $hostlongbits ] ; then
-  target_phys_bits=$hostlongbits
-fi
 case "$target_arch2" in
   i386|x86_64)
     if test "$xen" = "yes" -a "$target_softmmu" = "yes" ; then
diff --git a/cpu-defs.h b/cpu-defs.h
index 2e94585..0140596 100644
--- a/cpu-defs.h
+++ b/cpu-defs.h
@@ -76,7 +76,7 @@  typedef uint64_t target_ulong;
 #define CPU_TLB_BITS 8
 #define CPU_TLB_SIZE (1 << CPU_TLB_BITS)
 
-#if TARGET_PHYS_ADDR_BITS == 32 && TARGET_LONG_BITS == 32
+#if HOST_LONG_BITS == 32 && TARGET_LONG_BITS == 32
 #define CPU_TLB_ENTRY_BITS 4
 #else
 #define CPU_TLB_ENTRY_BITS 5
@@ -92,21 +92,18 @@  typedef struct CPUTLBEntry {
     target_ulong addr_read;
     target_ulong addr_write;
     target_ulong addr_code;
-    /* Addend to virtual address to get physical address.  IO accesses
+    /* Addend to virtual address to get host address.  IO accesses
        use the corresponding iotlb value.  */
-#if TARGET_PHYS_ADDR_BITS == 64
-    /* on i386 Linux make sure it is aligned */
-    target_phys_addr_t addend __attribute__((aligned(8)));
-#else
-    target_phys_addr_t addend;
-#endif
+    unsigned long addend;
     /* padding to get a power of two size */
     uint8_t dummy[(1 << CPU_TLB_ENTRY_BITS) - 
                   (sizeof(target_ulong) * 3 + 
-                   ((-sizeof(target_ulong) * 3) & (sizeof(target_phys_addr_t) - 1)) + 
-                   sizeof(target_phys_addr_t))];
+                   ((-sizeof(target_ulong) * 3) & (sizeof(unsigned long) - 1)) + 
+                   sizeof(unsigned long))];
 } CPUTLBEntry;
 
+extern int CPUTLBEntry_wrong_size[sizeof(CPUTLBEntry) == (1 << CPU_TLB_ENTRY_BITS) ? 1 : -1];
+
 #define CPU_COMMON_TLB \
     /* The meaning of the MMU modes is defined in the target code. */   \
     CPUTLBEntry tlb_table[NB_MMU_MODES][CPU_TLB_SIZE];                  \
diff --git a/exec.c b/exec.c
index 04e74d2..33854e1 100644
--- a/exec.c
+++ b/exec.c
@@ -2188,7 +2188,7 @@  void tlb_set_page(CPUState *env, target_ulong vaddr,
     unsigned int index;
     target_ulong address;
     target_ulong code_address;
-    target_phys_addr_t addend;
+    unsigned long addend;
     CPUTLBEntry *te;
     CPUWatchpoint *wp;
     target_phys_addr_t iotlb;
diff --git a/softmmu_template.h b/softmmu_template.h
index 2f37c34..c2df9ec 100644
--- a/softmmu_template.h
+++ b/softmmu_template.h
@@ -87,7 +87,8 @@  DATA_TYPE REGPARM glue(glue(__ld, SUFFIX), MMUSUFFIX)(target_ulong addr,
     DATA_TYPE res;
     int index;
     target_ulong tlb_addr;
-    target_phys_addr_t addend;
+    target_phys_addr_t ioaddr;
+    unsigned long addend;
     void *retaddr;
 
     /* test if there is match for unaligned or IO access */
@@ -101,8 +102,8 @@  DATA_TYPE REGPARM glue(glue(__ld, SUFFIX), MMUSUFFIX)(target_ulong addr,
             if ((addr & (DATA_SIZE - 1)) != 0)
                 goto do_unaligned_access;
             retaddr = GETPC();
-            addend = env->iotlb[mmu_idx][index];
-            res = glue(io_read, SUFFIX)(addend, addr, retaddr);
+            ioaddr = env->iotlb[mmu_idx][index];
+            res = glue(io_read, SUFFIX)(ioaddr, addr, retaddr);
         } else if (((addr & ~TARGET_PAGE_MASK) + DATA_SIZE - 1) >= TARGET_PAGE_SIZE) {
             /* slow unaligned access (it spans two pages or IO) */
         do_unaligned_access:
@@ -143,7 +144,8 @@  static DATA_TYPE glue(glue(slow_ld, SUFFIX), MMUSUFFIX)(target_ulong addr,
 {
     DATA_TYPE res, res1, res2;
     int index, shift;
-    target_phys_addr_t addend;
+    target_phys_addr_t ioaddr;
+    unsigned long addend;
     target_ulong tlb_addr, addr1, addr2;
 
     index = (addr >> TARGET_PAGE_BITS) & (CPU_TLB_SIZE - 1);
@@ -154,8 +156,8 @@  static DATA_TYPE glue(glue(slow_ld, SUFFIX), MMUSUFFIX)(target_ulong addr,
             /* IO access */
             if ((addr & (DATA_SIZE - 1)) != 0)
                 goto do_unaligned_access;
-            addend = env->iotlb[mmu_idx][index];
-            res = glue(io_read, SUFFIX)(addend, addr, retaddr);
+            ioaddr = env->iotlb[mmu_idx][index];
+            res = glue(io_read, SUFFIX)(ioaddr, addr, retaddr);
         } else if (((addr & ~TARGET_PAGE_MASK) + DATA_SIZE - 1) >= TARGET_PAGE_SIZE) {
         do_unaligned_access:
             /* slow unaligned access (it spans two pages) */
@@ -224,7 +226,8 @@  void REGPARM glue(glue(__st, SUFFIX), MMUSUFFIX)(target_ulong addr,
                                                  DATA_TYPE val,
                                                  int mmu_idx)
 {
-    target_phys_addr_t addend;
+    target_phys_addr_t ioaddr;
+    unsigned long addend;
     target_ulong tlb_addr;
     void *retaddr;
     int index;
@@ -238,8 +241,8 @@  void REGPARM glue(glue(__st, SUFFIX), MMUSUFFIX)(target_ulong addr,
             if ((addr & (DATA_SIZE - 1)) != 0)
                 goto do_unaligned_access;
             retaddr = GETPC();
-            addend = env->iotlb[mmu_idx][index];
-            glue(io_write, SUFFIX)(addend, val, addr, retaddr);
+            ioaddr = env->iotlb[mmu_idx][index];
+            glue(io_write, SUFFIX)(ioaddr, val, addr, retaddr);
         } else if (((addr & ~TARGET_PAGE_MASK) + DATA_SIZE - 1) >= TARGET_PAGE_SIZE) {
         do_unaligned_access:
             retaddr = GETPC();
@@ -277,7 +280,8 @@  static void glue(glue(slow_st, SUFFIX), MMUSUFFIX)(target_ulong addr,
                                                    int mmu_idx,
                                                    void *retaddr)
 {
-    target_phys_addr_t addend;
+    target_phys_addr_t ioaddr;
+    unsigned long addend;
     target_ulong tlb_addr;
     int index, i;
 
@@ -289,8 +293,8 @@  static void glue(glue(slow_st, SUFFIX), MMUSUFFIX)(target_ulong addr,
             /* IO access */
             if ((addr & (DATA_SIZE - 1)) != 0)
                 goto do_unaligned_access;
-            addend = env->iotlb[mmu_idx][index];
-            glue(io_write, SUFFIX)(addend, val, addr, retaddr);
+            ioaddr = env->iotlb[mmu_idx][index];
+            glue(io_write, SUFFIX)(ioaddr, val, addr, retaddr);
         } else if (((addr & ~TARGET_PAGE_MASK) + DATA_SIZE - 1) >= TARGET_PAGE_SIZE) {
         do_unaligned_access:
             /* XXX: not efficient, but simple */
diff --git a/targphys.h b/targphys.h
index 99ab23c..95648d6 100644
--- a/targphys.h
+++ b/targphys.h
@@ -5,10 +5,7 @@ 
 
 #ifdef TARGET_PHYS_ADDR_BITS
 /* target_phys_addr_t is the type of a physical address (its size can
-   be different from 'target_ulong'). We have sizeof(target_phys_addr)
-   = max(sizeof(unsigned long),
-   sizeof(size_of_target_physical_address)) because we must pass a
-   host pointer to memory operations in some cases */
+   be different from 'target_ulong').  */
 
 #if TARGET_PHYS_ADDR_BITS == 32
 typedef uint32_t target_phys_addr_t;
diff --git a/tcg/mips/tcg-target.c b/tcg/mips/tcg-target.c
index 10b9fc1..351efb1 100644
--- a/tcg/mips/tcg-target.c
+++ b/tcg/mips/tcg-target.c
@@ -867,7 +867,7 @@  static void tcg_out_qemu_ld(TCGContext *s, const TCGArg *args,
     reloc_pc16(label1_ptr, (tcg_target_long) s->code_ptr);
 
     tcg_out_opc_imm(s, OPC_LW, TCG_REG_A0, TCG_REG_A0,
-                    offsetof(CPUState, tlb_table[mem_index][0].addend) + addr_meml);
+                    offsetof(CPUState, tlb_table[mem_index][0].addend));
     tcg_out_opc_reg(s, OPC_ADDU, TCG_REG_V0, TCG_REG_A0, addr_regl);
 #else
     if (GUEST_BASE == (int16_t)GUEST_BASE) {
@@ -1054,7 +1054,7 @@  static void tcg_out_qemu_st(TCGContext *s, const TCGArg *args,
     reloc_pc16(label1_ptr, (tcg_target_long) s->code_ptr);
 
     tcg_out_opc_imm(s, OPC_LW, TCG_REG_A0, TCG_REG_A0,
-                    offsetof(CPUState, tlb_table[mem_index][0].addend) + addr_meml);
+                    offsetof(CPUState, tlb_table[mem_index][0].addend));
     tcg_out_opc_reg(s, OPC_ADDU, TCG_REG_A0, TCG_REG_A0, addr_regl);
 #else
     if (GUEST_BASE == (int16_t)GUEST_BASE) {
diff --git a/tcg/ppc/tcg-target.c b/tcg/ppc/tcg-target.c
index 18fdd27..609035a 100644
--- a/tcg/ppc/tcg-target.c
+++ b/tcg/ppc/tcg-target.c
@@ -37,14 +37,6 @@  static uint8_t *tb_ret_addr;
 
 #define FAST_PATH
 
-#ifdef CONFIG_SOFTMMU
-#if TARGET_PHYS_ADDR_BITS <= 32
-#define ADDEND_OFFSET 0
-#else
-#define ADDEND_OFFSET 4
-#endif
-#endif
-
 #ifndef GUEST_BASE
 #define GUEST_BASE 0
 #endif
@@ -648,7 +640,7 @@  static void tcg_out_qemu_ld (TCGContext *s, const TCGArg *args, int opc)
     tcg_out32 (s, (LWZ
                    | RT (r0)
                    | RA (r0)
-                   | (ADDEND_OFFSET + offsetof (CPUTLBEntry, addend)
+                   | (offsetof (CPUTLBEntry, addend)
                       - offsetof (CPUTLBEntry, addr_read))
                    ));
     /* r0 = env->tlb_table[mem_index][index].addend */
@@ -847,7 +839,7 @@  static void tcg_out_qemu_st (TCGContext *s, const TCGArg *args, int opc)
     tcg_out32 (s, (LWZ
                    | RT (r0)
                    | RA (r0)
-                   | (ADDEND_OFFSET + offsetof (CPUTLBEntry, addend)
+                   | (offsetof (CPUTLBEntry, addend)
                       - offsetof (CPUTLBEntry, addr_write))
                    ));
     /* r0 = env->tlb_table[mem_index][index].addend */
diff --git a/tcg/ppc64/tcg-target.c b/tcg/ppc64/tcg-target.c
index 4d6e68c..2725c6e 100644
--- a/tcg/ppc64/tcg-target.c
+++ b/tcg/ppc64/tcg-target.c
@@ -28,14 +28,6 @@  static uint8_t *tb_ret_addr;
 
 #define FAST_PATH
 
-#ifdef CONFIG_SOFTMMU
-#if TARGET_PHYS_ADDR_BITS == 32
-#define LD_ADDEND LWZ
-#else
-#define LD_ADDEND LD
-#endif
-#endif
-
 #if TARGET_LONG_BITS == 32
 #define LD_ADDR LWZU
 #define CMP_L 0
@@ -684,7 +676,7 @@  static void tcg_out_qemu_ld (TCGContext *s, const TCGArg *args, int opc)
 #endif
 
     /* r0 now contains &env->tlb_table[mem_index][index].addr_read */
-    tcg_out32 (s, (LD_ADDEND
+    tcg_out32 (s, (LD
                    | RT (r0)
                    | RA (r0)
                    | (offsetof (CPUTLBEntry, addend)
@@ -812,7 +804,7 @@  static void tcg_out_qemu_st (TCGContext *s, const TCGArg *args, int opc)
     reloc_pc14 (label1_ptr, (tcg_target_long) s->code_ptr);
 #endif
 
-    tcg_out32 (s, (LD_ADDEND
+    tcg_out32 (s, (LD
                    | RT (r0)
                    | RA (r0)
                    | (offsetof (CPUTLBEntry, addend)
diff --git a/tcg/sparc/tcg-target.c b/tcg/sparc/tcg-target.c
index 6d8410c..e460d44 100644
--- a/tcg/sparc/tcg-target.c
+++ b/tcg/sparc/tcg-target.c
@@ -726,13 +726,7 @@  static const void * const qemu_st_helpers[4] = {
 #endif
 
 #if defined(CONFIG_SOFTMMU)
-#if TARGET_PHYS_ADDR_BITS == 32
-#define TARGET_ADDEND_LD_OP LDUW
-#else
-#define TARGET_ADDEND_LD_OP LDX
-#endif
-#else
-#if TARGET_ABI_BITS == 32
+#if HOST_LONG_BITS == 32
 #define TARGET_ADDEND_LD_OP LDUW
 #else
 #define TARGET_ADDEND_LD_OP LDX