From patchwork Fri Jun 25 15:55:06 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Cole Robinson X-Patchwork-Id: 56978 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from lists.gnu.org (lists.gnu.org [199.232.76.165]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (Client did not present a certificate) by ozlabs.org (Postfix) with ESMTPS id AE1EDB6EF7 for ; Sat, 26 Jun 2010 05:39:10 +1000 (EST) Received: from localhost ([127.0.0.1]:33129 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OSEjt-0000BN-VQ for incoming@patchwork.ozlabs.org; Fri, 25 Jun 2010 15:39:02 -0400 Received: from [140.186.70.92] (port=44167 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OSCwd-0002Dc-8Z for qemu-devel@nongnu.org; Fri, 25 Jun 2010 13:44:04 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OSBKn-0007tY-JD for qemu-devel@nongnu.org; Fri, 25 Jun 2010 12:00:54 -0400 Received: from adelie.canonical.com ([91.189.90.139]:58298) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OSBKn-0007tS-CU for qemu-devel@nongnu.org; Fri, 25 Jun 2010 12:00:53 -0400 Received: from loganberry.canonical.com ([91.189.90.37]) by adelie.canonical.com with esmtp (Exim 4.69 #1 (Debian)) id 1OSBKj-0007N3-Ro for ; Fri, 25 Jun 2010 17:00:50 +0100 Received: from loganberry.canonical.com (localhost [127.0.0.1]) by loganberry.canonical.com (Postfix) with ESMTP id 4DC122E8217 for ; Fri, 25 Jun 2010 17:00:47 +0100 (BST) MIME-Version: 1.0 Date: Fri, 25 Jun 2010 15:55:06 -0000 From: Cole Robinson To: qemu-devel@nongnu.org X-Launchpad-Bug: product=qemu; status=Incomplete; importance=Undecided; assignee=None; X-Launchpad-Bug: distribution=debian; sourcepackage=None; component=None; status=New; importance=Unknown; assignee=None; X-Launchpad-Bug: distribution=fedora; sourcepackage=None; component=None; status=Unknown; importance=Unknown; assignee=None; X-Launchpad-Bug-Tags: windows X-Launchpad-Bug-Private: no X-Launchpad-Bug-Security-Vulnerability: no X-Launchpad-Bug-Commenters: anthony-codemonkey claunia crobinso raharper vekmitt-tekditt References: <20100527023758.1600.77688.malonedeb@soybean.canonical.com> Message-Id: <20100625155506.24259.20859.malone@palladium.canonical.com> X-Launchpad-Message-Rationale: Subscriber (QEMU) @qemu-devel-ml Precedence: bulk X-Generated-By: Launchpad (canonical.com); Revision="None"; Instance="initZopeless config overlay" X-Launchpad-Hash: d66eb7d295c16fcb46872a93d1a8e49b321a477d X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) Subject: [Qemu-devel] [Bug 586175] Re: Windows XP/2003 doesn't boot X-BeenThere: qemu-devel@nongnu.org X-Mailman-Version: 2.1.5 Reply-To: Bug 586175 <586175@bugs.launchpad.net> List-Id: qemu-devel.nongnu.org List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org Errors-To: qemu-devel-bounces+incoming=patchwork.ozlabs.org@nongnu.org I can reproduce with qemu-kvm 0.12.4 like the original reporter. I cannot reproduce with qemu-kvm upstream, qemu stable, or qemu upstream. So boot=on could be the culprit. Libvirt generated command line: LC_ALL=C PATH=/sbin:/usr/sbin:/bin:/usr/bin QEMU_AUDIO_DRV=none /usr/bin /qemu-system-x86_64 -S -M pc-0.12 -no-kvm -m 512 -smp 1,sockets=1,cores=1,threads=1 -name winxp_test -uuid 634dff56-8c5a-fdbb- b5fc-091bcf78e586 -nodefaults -chardev socket,id=monitor,path=/var/lib/libvirt/qemu/winxp_test.monitor,server,nowait -mon chardev=monitor,mode=readline -rtc base=localtime -boot c -drive file=/var/lib/libvirt/images/winxp_test.img,if=none,id=drive- ide0-0-0,boot=on,format=raw -device ide-drive,bus=ide.0,unit=0,drive =drive-ide0-0-0,id=ide0-0-0 -drive file=/mnt/data/media/win_xp_sp3_32.iso,if=none,media=cdrom,id=drive- ide0-1-0,readonly=on,format=raw -device ide-drive,bus=ide.1,unit=0,drive =drive-ide0-1-0,id=ide0-1-0 -device rtl8139,vlan=0,id=net0,mac=52:54:00:ac:e8:ca,bus=pci.0,addr=0x4 -net tap,fd=20,vlan=0,name=hostnet0 -chardev pty,id=serial0 -device isa- serial,chardev=serial0 -usb -device usb-tablet,id=input0 -vnc 127.0.0.1:1 -k en-us -vga std -device virtio-balloon- pci,id=balloon0,bus=pci.0,addr=0x3 Markus has a patch internally against an older qemu-kvm release that apparently fixes the issue, however the upstream code is different so it doesn't cleanly apply. Maybe this will give someone a hint for a proper upstream solution: hw/pc.c | 4 ++++ 1 files changed, 4 insertions(+), 0 deletions(-) diff --git a/hw/pc.c b/hw/pc.c index d142282..c60a79a 100644 --- a/hw/pc.c +++ b/hw/pc.c @@ -271,12 +271,16 @@ static void cmos_init(ram_addr_t ram_size, ram_addr_t above_4g_mem_size, */ for (i = 0; i < 4; i++) { char id[32]; + int cylinders, heads, secs; if (hd_table[i]) continue; snprintf(id, sizeof(id), "drive-ide0-%d-%d", i / MAX_IDE_DEVS, i % MAX_IDE_DEVS); hd_table[i] = drive_get_by_id(id); + if (hd_table[i]) { + bdrv_guess_geometry(hd_table[i]->bdrv, &cylinders, &heads, &secs); + } } /* various important CMOS locations needed by PC/Bochs bios */