From mboxrd@z Thu Jan 1 00:00:00 1970 From: Eduard - Gabriel Munteanu Subject: Re: [Qemu-devel] [PATCH 2/7] pci: memory access API and IOMMU support Date: Thu, 2 Sep 2010 19:14:00 +0300 Message-ID: <20100902161400.GA7591@localhost> References: <1283119703-9781-1-git-send-email-eduard.munteanu@linux360.ro> <4C7EB336.40003@mail.berlios.de> <20100902085104.GB7211@localhost> <4C7FCB53.5010503@mail.berlios.de> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: mst@redhat.com, kvm@vger.kernel.org, joro@8bytes.org, qemu-devel@nongnu.org, blauwirbel@gmail.com, yamahata@valinux.co.jp, paul@codesourcery.com, avi@redhat.com To: Stefan Weil Return-path: Received: from mail-fx0-f46.google.com ([209.85.161.46]:50209 "EHLO mail-fx0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753744Ab0IBQQF (ORCPT ); Thu, 2 Sep 2010 12:16:05 -0400 Received: by fxm13 with SMTP id 13so354691fxm.19 for ; Thu, 02 Sep 2010 09:16:04 -0700 (PDT) Content-Disposition: inline In-Reply-To: <4C7FCB53.5010503@mail.berlios.de> Sender: kvm-owner@vger.kernel.org List-ID: On Thu, Sep 02, 2010 at 06:05:39PM +0200, Stefan Weil wrote: > Am 02.09.2010 10:51, schrieb Eduard - Gabriel Munteanu: [snip] > >> The functions pci_memory_read and pci_memory_write not only read > >> or write byte data but many different data types which leads to > >> a lot of type casts in your other patches. > >> > >> I'd prefer "void *buf" and "const void *buf" in the argument lists. > >> Then all those type casts could be removed. > >> > >> Regards > >> Stefan Weil > >> > > I only followed an approach similar to how cpu_physical_memory_{read,write}() > > is defined. I think I should change both cpu_physical_memory_* stuff and > > pci_memory_* stuff, not only the latter, if I decide to go on that > > approach. > > > > > > Eduard > > > > > Yes, cpu_physical_memory_read, cpu_physical_memory_write > and cpu_physical_memory_rw should be changed, too. > > They also require several type casts today. > > But this change can be done in an independent patch. > > Stefan Roger, I'm on it. The existing casts could remain there AFAICT, so it's a pretty simple change. Eduard