From owner-svn-soc-all@FreeBSD.ORG Mon Jul 2 21:24:08 2012 Return-Path: Delivered-To: svn-soc-all@FreeBSD.org Received: from socsvn.FreeBSD.org (unknown [IPv6:2001:4f8:fff6::2f]) by hub.freebsd.org (Postfix) with SMTP id 24241106564A for ; Mon, 2 Jul 2012 21:24:06 +0000 (UTC) (envelope-from syuu@FreeBSD.org) Received: by socsvn.FreeBSD.org (sSMTP sendmail emulation); Mon, 02 Jul 2012 21:24:06 +0000 Date: Mon, 02 Jul 2012 21:24:06 +0000 From: syuu@FreeBSD.org To: svn-soc-all@FreeBSD.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Message-Id: <20120702212406.24241106564A@hub.freebsd.org> Cc: Subject: socsvn commit: r238853 - soc2012/syuu/bhyve-bios/lib/libvmmapi X-BeenThere: svn-soc-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: SVN commit messages for the entire Summer of Code repository List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 02 Jul 2012 21:24:08 -0000 Author: syuu Date: Mon Jul 2 21:24:05 2012 New Revision: 238853 URL: http://svnweb.FreeBSD.org/socsvn/?view=rev&rev=238853 Log: change register values for boot from disk Modified: soc2012/syuu/bhyve-bios/lib/libvmmapi/vmmapi_bios.c Modified: soc2012/syuu/bhyve-bios/lib/libvmmapi/vmmapi_bios.c ============================================================================== --- soc2012/syuu/bhyve-bios/lib/libvmmapi/vmmapi_bios.c Mon Jul 2 21:21:54 2012 (r238852) +++ soc2012/syuu/bhyve-bios/lib/libvmmapi/vmmapi_bios.c Mon Jul 2 21:24:05 2012 (r238853) @@ -50,10 +50,7 @@ uint32_t desc_access, desc_limit; uint16_t gsel; -#if 0 - rip = 0xfff0; -#endif - rip = 0x0; + rip = 0x7c00; if ((error = vm_set_register(vmctx, vcpu, VM_REG_GUEST_RIP, rip)) != 0) goto done; @@ -73,9 +70,6 @@ if ((error = vm_set_register(vmctx, vcpu, VM_REG_GUEST_CR4, cr4)) != 0) goto done; -#if 0 - desc_base = 0xffff0000; -#endif desc_base = 0x0; desc_limit = 0xffff; /* PRESENT | DESC_TYPE_CODEDATA | SEG_TYPE_DATA_RW_ACCESSED */ @@ -85,9 +79,6 @@ if (error) goto done; -#if 0 - gsel = 0xf000; -#endif gsel = 0x0; if ((error = vm_set_register(vmctx, vcpu, VM_REG_GUEST_CS, gsel)) != 0) goto done; @@ -173,7 +164,7 @@ if ((error = vm_set_register(vmctx, vcpu, VM_REG_GUEST_RBP, rbp)) != 0) goto done; - rsp = 0; + rsp = 0x8000 - 2; if ((error = vm_set_register(vmctx, vcpu, VM_REG_GUEST_RSP, rsp)) != 0) goto done;