From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:33212) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qqi6g-0004Ip-HX for qemu-devel@nongnu.org; Tue, 09 Aug 2011 04:56:15 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Qqi6f-0003uP-D4 for qemu-devel@nongnu.org; Tue, 09 Aug 2011 04:56:14 -0400 Received: from mx1.redhat.com ([209.132.183.28]:41754) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Qqi6f-0003uF-4o for qemu-devel@nongnu.org; Tue, 09 Aug 2011 04:56:13 -0400 Message-ID: <4E40F628.9050505@redhat.com> Date: Tue, 09 Aug 2011 11:56:08 +0300 From: Avi Kivity MIME-Version: 1.0 References: <1312823229-12822-1-git-send-email-avi@redhat.com> <1312823229-12822-10-git-send-email-avi@redhat.com> <4E40D4F7.3080702@redhat.com> <4E40E4B3.2060304@redhat.com> <4E40F387.5080108@redhat.com> In-Reply-To: <4E40F387.5080108@redhat.com> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 09/24] omap_gpmc/nseries/tusb6010: convert to memory API List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Peter Maydell Cc: qemu-devel@nongnu.org, kvm@vger.kernel.org On 08/09/2011 11:44 AM, Avi Kivity wrote: >> ...isn't this just throwing away the warnings on bad-width accesses? > > > It is; will fix. Reading the original code, it seems broken: uint32_t omap_badwidth_read32(void *opaque, target_phys_addr_t addr) { uint32_t ret; OMAP_32B_REG(addr); cpu_physical_memory_read(addr, (void *) &ret, 4); return ret; } The code issues a read from addr, but that is not the original address used by the guest, since addresses are relative to the start of the region (in both the old and new APIs), not to physical address start. So I'll just set access size validity in the new code. -- error compiling committee.c: too many arguments to function