From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([208.118.235.92]:50899) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Ugswa-0000NU-3I for qemu-devel@nongnu.org; Mon, 27 May 2013 04:38:18 -0400 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1UgswT-0007WF-DZ for qemu-devel@nongnu.org; Mon, 27 May 2013 04:38:16 -0400 Received: from thoth.sbs.de ([192.35.17.2]:34124) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1UgswT-0007Vx-3n for qemu-devel@nongnu.org; Mon, 27 May 2013 04:38:09 -0400 Message-ID: <51A31B65.4010209@siemens.com> Date: Mon, 27 May 2013 10:37:57 +0200 From: Jan Kiszka MIME-Version: 1.0 References: <1369133851-1894-1-git-send-email-pbonzini@redhat.com> <1369133851-1894-18-git-send-email-pbonzini@redhat.com> <51A05CDF.1090106@web.de> <51A06C9B.5060302@redhat.com> <51A09018.7000901@web.de> <51A09E6F.7030109@redhat.com> <51A0A0D5.5000706@web.de> <51A1CE2F.5050508@redhat.com> <51A1CF92.7030708@web.de> <51A30933.9080307@redhat.com> <51A309E9.2010903@siemens.com> <51A31709.40601@redhat.com> In-Reply-To: <51A31709.40601@redhat.com> Content-Type: text/plain; charset=ISO-8859-15 Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH 17/30] memory: add address_space_translate List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Paolo Bonzini Cc: "peter.maydell@linaro.org" , "qemu-devel@nongnu.org" , David Gibson On 2013-05-27 10:19, Paolo Bonzini wrote: > Il 27/05/2013 09:23, Jan Kiszka ha scritto: >> On 2013-05-27 09:20, Paolo Bonzini wrote: >>> Il 26/05/2013 11:02, Jan Kiszka ha scritto: >>>>>> >>>>>> Nice patches. Only one thing, how is .impl.unaligned different >>>>>> from the existing .valid.unaligned? >>>> See memory.h: valid controls is an unaligned access traps or gets >>>> processed, impl manages if it is passed as-is to the device or >>>> broken up and aligned first. >>> >>> I took the following patches: >>> >>> exec: Allow unaligned address_space_rw >>> exec: Resolve subpages in one step except for IOTLB fills >>> exec: Implement subpage_read/write via address_space_rw >>> >>> to limit the conflicts and because I realized that TCG should never >>> encounter an IOMMU. >> >> Err, why? Will we emulate IOMMUs for TCG differently? > > Because IOMMUs should never be added to address_space_memory. > > TCG should only encounter an IOMMU during device emulation (DMA), not > because of reads/writes from the CPU. So the IOTLBs should never point > to an IOMMU region. OK. That's true for the current QEMU architecture, but may no longer be like this if we once emulate device controllers via TCG (in hybrid system setups). Anyway, I guess it's fine to optimize this for now. Jan -- Siemens AG, Corporate Technology, CT RTC ITP SDP-DE Corporate Competence Center Embedded Linux