From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([2001:4830:134:3::10]:57001) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YXeK0-0000kM-7J for qemu-devel@nongnu.org; Mon, 16 Mar 2015 19:21:21 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1YXeJt-0000Qp-Lg for qemu-devel@nongnu.org; Mon, 16 Mar 2015 19:21:20 -0400 Received: from omzsmtpe04.verizonbusiness.com ([199.249.25.207]:50369) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1YXeJt-0000QQ-GG for qemu-devel@nongnu.org; Mon, 16 Mar 2015 19:21:13 -0400 From: Don Slutz Date: Mon, 16 Mar 2015 19:20:58 -0400 Message-Id: <1426548064-21182-2-git-send-email-dslutz@verizon.com> In-Reply-To: <1426548064-21182-1-git-send-email-dslutz@verizon.com> References: <1426548064-21182-1-git-send-email-dslutz@verizon.com> Subject: [Qemu-devel] [PATCH v2 1/7] vmport.c: Fix vmport_cmd_ram_size List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: qemu-devel@nongnu.org Cc: "Michael S. Tsirkin" , Markus Armbruster , Don Slutz , Luiz Capitulino , Anthony Liguori , Paolo Bonzini , =?UTF-8?q?Andreas=20F=C3=A4rber?= , Richard Henderson Based on https://sites.google.com/site/chitchatvmback/backdoor and testing on ESXi, this should be in MB not bytes. Signed-off-by: Don Slutz --- hw/misc/vmport.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/hw/misc/vmport.c b/hw/misc/vmport.c index 7fcc00d..6b350ce 100644 --- a/hw/misc/vmport.c +++ b/hw/misc/vmport.c @@ -110,7 +110,7 @@ static uint32_t vmport_cmd_ram_size(void *opaque, uint32_t addr) X86CPU *cpu = X86_CPU(current_cpu); cpu->env.regs[R_EBX] = 0x1177; - return ram_size; + return ram_size >> 20; /* in MB */ } static uint32_t vmport_cmd_xtest(void *opaque, uint32_t addr) -- 1.8.4