BUG: linux guest with paravirt support thinks it boots on bare hardware

Felix Leimbach
2008-03-30T17:21:20Z

While testing the new virtio drivers in linux-2.6.25 my test
2.6.25-rc7-git5 guest with paravirt support running in KVM-64 thinks it
sits on cold and unfriendly bare metal instead of a safe and cosy KVM
bed ;-)
Because it is very unhappy it emits the following message during boot:
Booting paravirtualized kernel on bare hardware

Of course the guest still runs perfectly and I am indeed very impressed
by KVM and its performance. A big thanks to all the hard working devs
for that!

Relevant config and dmesg below.

regards,
Felix

# zcat /proc/config.gz |grep '\(VIRT\|VMI\|XEN\)'
CONFIG_PARAVIRT_GUEST=y
CONFIG_XEN=y
CONFIG_VMI=y
CONFIG_PARAVIRT=y
CONFIG_VIRT_TO_BUS=y
# CONFIG_XEN_BLKDEV_FRONTEND is not set
CONFIG_VIRTIO_BLK=y
CONFIG_XEN_NETDEV_FRONTEND=y
CONFIG_VIRTIO_NET=y
CONFIG_HVC_XEN=y
# CONFIG_FB_VIRTUAL is not set
CONFIG_VIRTUALIZATION=y
CONFIG_VIRTIO=y
CONFIG_VIRTIO_RING=y
CONFIG_VIRTIO_PCI=y
CONFIG_VIRTIO_BALLOON=y

#dmesg
BIOS-provided physical RAM map:
BIOS-e820: 0000000000000000 - 000000000009fc00 (usable)
BIOS-e820: 000000000009fc00 - 00000000000a0000 (reserved)
BIOS-e820: 00000000000e8000 - 0000000000100000 (reserved)
BIOS-e820: 0000000000100000 - 0000000036bf0000 (usable)
BIOS-e820: 0000000036bf0000 - 0000000036c00000 (ACPI data)
BIOS-e820: 00000000fffbd000 - 0000000100000000 (reserved)
875MB LOWMEM available.
Entering add_active_range(0, 0, 224240) 0 entries of 256 used
Zone PFN ranges:
DMA 0 -> 4096
Normal 4096 -> 224240
Movable zone start PFN for each node
early_node_map[1] active PFN ranges
0: 0 -> 224240
On node 0 totalpages: 224240
DMA zone: 32 pages used for memmap
DMA zone: 0 pages reserved
DMA zone: 4064 pages, LIFO batch:0
Normal zone: 1719 pages used for memmap
Normal zone: 218425 pages, LIFO batch:31
Movable zone: 0 pages used for memmap
DMI 2.4 present.
ACPI: RSDP 000FB450, 0014 (r0 QEMU )
ACPI: RSDT 36BF0000, 002C (r1 QEMU QEMURSDT 1 QEMU 1)
ACPI: FACP 36BF002C, 0074 (r1 QEMU QEMUFACP 1 QEMU 1)
ACPI: DSDT 36BF0100, 2464 (r1 BXPC BXDSDT 1 INTL 20061109)
ACPI: FACS 36BF00C0, 0040
ACPI: APIC 36BF2568, 00E0 (r1 QEMU QEMUAPIC 1 QEMU 1)
ACPI: PM-Timer IO Port: 0xb008
Allocating PCI resources starting at 40000000 (gap: 36c00000:c93bd000)
Built 1 zonelists in Zone order, mobility grouping on. Total pages: 222489
Kernel command line: root=/dev/vda2 vga=0x314
Enabling fast FPU save and restore... done.
Enabling unmasked SIMD FPU exception support... done.
Initializing CPU#0
PID hash table entries: 4096 (order: 12, 16384 bytes)
Detected 1995.015 MHz processor.
Console: colour dummy device 80x25
console [tty0] enabled
Dentry cache hash table entries: 131072 (order: 7, 524288 bytes)
Inode-cache hash table entries: 65536 (order: 6, 262144 bytes)
Memory: 885668k/896960k available (1728k kernel code, 10740k reserved,
687k data, 192k init, 0k highmem)
virtual kernel memory layout:
fixmap : 0xffff5000 - 0xfffff000 ( 40 kB)
vmalloc : 0xf7800000 - 0xffff3000 ( 135 MB)
lowmem : 0xc0000000 - 0xf6bf0000 ( 875 MB)
.init : 0xc0360000 - 0xc0390000 ( 192 kB)
.data : 0xc02b02f1 - 0xc035c07c ( 687 kB)
.text : 0xc0100000 - 0xc02b02f1 (1728 kB)
Checking if this processor honours the WP bit even in supervisor mode...Ok.
CPA: page pool initialized 1 of 1 pages preallocated
SLUB: Genslabs=12, HWalign=64, Order=0-1, MinObjects=4, CPUs=1, Nodes=1
Calibrating delay using timer specific routine.. 4006.54 BogoMIPS
(lpj=20032716)
Security Framework initialized
Mount-cache hash table entries: 512
CPU: L1 I Cache: 64K (64 bytes/line), D cache 64K (64 bytes/line)
CPU: L2 Cache: 512K (64 bytes/line)
Compat vDSO mapped to ffffe000.
CPU: AMD QEMU Virtual CPU version 0.9.1 stepping 03
Checking 'hlt' instruction... OK.
Freeing SMP alternatives: 0k freed
ACPI: Core revision 20070126
ACPI: setting ELCR to 0200 (from 0c00)
net_namespace: 152 bytes
Booting paravirtualized kernel on bare hardware
NET: Registered protocol family 16
No dock devices found.
ACPI: bus type pci registered
PCI: PCI BIOS revision 2.10 entry at 0xfadb0, last bus=0
PCI: Using configuration type 1
Setting up standard PCI resources
ACPI: EC: Look up EC in DSDT
ACPI: Interpreter enabled
ACPI: (supports S0 S5)
ACPI: Using PIC for interrupt routing
ACPI: PCI Root Bridge [PCI0] (0000:00)
pci 0000:00:01.3: quirk: region b000-b03f claimed by PIIX4 ACPI
pci 0000:00:01.3: quirk: region b100-b10f claimed by PIIX4 SMB
ACPI: PCI Interrupt Routing Table [\_SB_.PCI0._PRT]
ACPI: PCI Interrupt Link [LNKA] (IRQs 5 *10 11)
ACPI: PCI Interrupt Link [LNKB] (IRQs 5 *10 11)
ACPI: PCI Interrupt Link [LNKC] (IRQs 5 10 *11)
ACPI: PCI Interrupt Link [LNKD] (IRQs 5 10 *11)
Linux Plug and Play Support v0.97 (c) Adam Belay
pnp: PnP ACPI init
ACPI: bus type pnp registered
pnp: PnP ACPI: found 7 devices
ACPI: ACPI bus type pnp unregistered
SCSI subsystem initialized
libata version 3.00 loaded.
PCI: Using ACPI for IRQ routing
PCI: If a device doesn't work, try "pci=routeirq". If it helps, post a
report
NET: Registered protocol family 2
IP route cache hash table entries: 32768 (order: 5, 131072 bytes)
TCP established hash table entries: 131072 (order: 8, 1048576 bytes)
TCP bind hash table entries: 65536 (order: 6, 262144 bytes)
TCP: Hash tables configured (established 131072 bind 65536)
TCP reno registered
io scheduler noop registered
io scheduler deadline registered (default)
pci 0000:00:01.0: PIIX3: Enabling Passive Release
pci 0000:00:00.0: Limiting direct PCI/PCI transfers
pci 0000:00:01.0: Activating ISA DMA hang workarounds
pci 0000:00:02.0: Boot video device
pci_hotplug: PCI Hot Plug PCI Core version: 0.5
acpiphp: ACPI Hot Plug PCI Controller Driver version: 0.5
acpiphp_glue: can't get bus number, assuming 0
decode_hpp: Could not get hotplug parameters. Use defaults
acpiphp: Slot [1] registered
acpiphp: Slot [2] registered
acpiphp: Slot [3] registered
acpiphp: Slot [4] registered
acpiphp: Slot [5] registered
acpiphp: Slot [6] registered
acpiphp: Slot [7] registered
acpiphp: Slot [8] registered
acpiphp: Slot [9] registered
acpiphp: Slot [10] registered
acpiphp: Slot [11] registered
acpiphp: Slot [12] registered
acpiphp: Slot [13] registered
acpiphp: Slot [14] registered
acpiphp: Slot [15] registered
acpiphp: Slot [16] registered
acpiphp: Slot [17] registered
acpiphp: Slot [18] registered
acpiphp: Slot [19] registered
acpiphp: Slot [20] registered
acpiphp: Slot [21] registered
acpiphp: Slot [22] registered
acpiphp: Slot [23] registered
acpiphp: Slot [24] registered
acpiphp: Slot [25] registered
acpiphp: Slot [26] registered
acpiphp: Slot [27] registered
acpiphp: Slot [28] registered
acpiphp: Slot [29] registered
acpiphp: Slot [30] registered
acpiphp: Slot [31] registered
vesafb: framebuffer at 0xf0000000, mapped to 0xf7880000, using 1875k,
total 4096k
vesafb: mode is 800x600x16, linelength=1600, pages=3
vesafb: scrolling: redraw
vesafb: Truecolor: size=0:5:6:5, shift=0:11:5:0
Console: switching to colour frame buffer device 100x37
fb0: VESA VGA frame buffer device
input: Power Button (FF) as /class/input/input0
ACPI: Power Button (FF) [PWRF]
ACPI: ACPI0007:00 is registered as cooling_device0
Real Time Clock Driver v1.12ac
loop: module loaded
Driver 'sd' needs updating - please use bus_type methods
Driver 'sr' needs updating - please use bus_type methods
ata_piix 0000:00:01.1: version 2.12
PCI: Setting latency timer of device 0000:00:01.1 to 64
scsi0 : ata_piix
scsi1 : ata_piix
ata1: PATA max MWDMA2 cmd 0x1f0 ctl 0x3f6 bmdma 0xc000 irq 14
ata2: PATA max MWDMA2 cmd 0x170 ctl 0x376 bmdma 0xc008 irq 15
Switched to high resolution mode on CPU 0
ata2.00: ATAPI: QEMU DVD-ROM, 0.9.1, max UDMA/100
ata2.00: configured for MWDMA2
scsi 1:0:0:0: CD-ROM QEMU QEMU DVD-ROM 0.9. PQ: 0 ANSI: 5
sr0: scsi3-mmc drive: 4x/4x xa/form2 tray
Uniform CD-ROM driver Revision: 3.20
sr 1:0:0:0: Attached scsi CD-ROM sr0
PNP: PS/2 Controller [PNP0303:KBD,PNP0f13:MOU] at 0x60,0x64 irq 1,12
serio: i8042 KBD port at 0x60,0x64 irq 1
serio: i8042 AUX port at 0x60,0x64 irq 12
mice: PS/2 mouse device common for all mice
ACPI: PCI Interrupt Link [LNKC] enabled at IRQ 11
PCI: setting IRQ 11 as level-triggered
ACPI: PCI Interrupt 0000:00:03.0[A] -> Link [LNKC] -> GSI 11 (level,
high) -> IRQ 11
input: AT Translated Set 2 keyboard as /class/input/input1
ACPI: PCI Interrupt Link [LNKD] enabled at IRQ 11
ACPI: PCI Interrupt 0000:00:04.0[A] -> Link [LNKD] -> GSI 11 (level,
high) -> IRQ 11
vda: vda1 vda2 vda3
TCP cubic registered
NET: Registered protocol family 1
NET: Registered protocol family 17
NET: Registered protocol family 15
Using IPI Shortcut mode
kjournald starting. Commit interval 5 seconds
EXT3-fs: mounted filesystem with ordered data mode.
VFS: Mounted root (ext3 filesystem) readonly.
Freeing unused kernel memory: 192k freed
EXT3 FS on vda2, internal journal
kjournald starting. Commit interval 5 seconds
EXT3 FS on vda3, internal journal
EXT3-fs: mounted filesystem with ordered data mode.
Adding 524280k swap on /mnt/data/swap. Priority:-1 extents:142
across:1172508k
Clocksource tsc unstable (delta = -80367546 ns)