From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gerd Hoffmann Subject: Re: VT/ioemu: vga memory access? Date: Tue, 16 May 2006 18:49:48 +0200 Message-ID: <446A02AC.9010601@suse.de> References: <907625E08839C4409CE5768403633E0BA7FC75@sefsexmb1.amd.com> Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------040009060905080806040904" Return-path: In-Reply-To: <907625E08839C4409CE5768403633E0BA7FC75@sefsexmb1.amd.com> List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: "Petersson, Mats" Cc: Xen devel list List-Id: xen-devel@lists.xenproject.org This is a multi-part message in MIME format. --------------040009060905080806040904 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable Hi, > I'll write some simple test code to check it out, and let you know...=20 Fix attached, seems to work ok on a quick test. cheers, Gerd --=20 Gerd Hoffmann Erst mal heiraten, ein, zwei Kinder, und wenn alles l=E4uft geh' ich nach drei Jahren mit der Familie an die B=F6rse. http://www.suse.de/~kraxel/julika-dora.jpeg --------------040009060905080806040904 Content-Type: text/plain; name="fix" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="fix" diff -r be5a6188cd9f xen/arch/x86/hvm/platform.c --- a/xen/arch/x86/hvm/platform.c Thu May 11 10:34:34 2006 +++ b/xen/arch/x86/hvm/platform.c Tue May 16 18:11:57 2006 @@ -865,7 +865,7 @@ * copy ourself. After this copy succeeds, "rep movs" is executed * again. */ - if ((addr & PAGE_MASK) != ((addr + size - 1) & PAGE_MASK)) { + if ((addr & PAGE_MASK) != ((addr + sign * (size - 1)) & PAGE_MASK)) { unsigned long value = 0; mmio_opp->flags |= OVERLAP; @@ -876,7 +876,7 @@ hvm_copy(&value, addr, size, HVM_COPY_IN); send_mmio_req(IOREQ_TYPE_COPY, gpa, 1, size, value, dir, 0); } else { - if ((addr & PAGE_MASK) != ((addr + count * size - 1) & PAGE_MASK)) { + if ((addr & PAGE_MASK) != ((addr + sign * (count * size - 1)) & PAGE_MASK)) { regs->eip -= inst_len; /* do not advance %eip */ if (sign > 0) --------------040009060905080806040904 Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Xen-devel mailing list Xen-devel@lists.xensource.com http://lists.xensource.com/xen-devel --------------040009060905080806040904--