qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
From: Paolo Bonzini <pbonzini@redhat.com>
To: "Hervé Poussineau" <hpoussin@reactos.org>, qemu-devel@nongnu.org
Cc: Leon Alrae <leon.alrae@imgtec.com>,
	Laurent@Vivier.EU, Aurelien Jarno <aurelien@aurel32.net>
Subject: Re: [Qemu-devel] [PATCH 1/8] rc4030: create custom DMA address space
Date: Thu, 26 Mar 2015 15:15:26 +0100	[thread overview]
Message-ID: <5514147E.8050509@redhat.com> (raw)
In-Reply-To: <5513083D.30008@reactos.org>



On 25/03/2015 20:10, Hervé Poussineau wrote:
> Le 25/03/2015 15:45, Paolo Bonzini a écrit :
>>
>>
>> On 05/03/2015 23:13, Hervé Poussineau wrote:
>>> Add a new memory region in system address space where DMA address space
>>> definition (the 'translation table') belongs, so we can update on the
>>> fly
>>> the DMA address space.
>>>
>>> Signed-off-by: Hervé Poussineau <hpoussin@reactos.org>
>>
>> Would it make sense to just use an IOMMU region for the DMA address
>> space?
> 
> I don't really know. Currently, the first user is the dp8393x network
> card (a sysbus device), which is connected through the DMA address space.
> It means that *every* read or write access needs to be translated, even
> those accessing 1 or 2 bytes. dp8393x has no direct connection to the
> system memory.
> On some other machines, like the m68k Quadra 800, the dp8393x is only
> connected to the system memory.
> 
> A second user is the ESP SCSI card in DMA mode, using the DMA address
> space with the help of the DMA controller.
> 
> As DMA address space mapping doesn't change much (except initialization
> phases), and that it is used for small (1 or 2 bytes) and big transfers
> (network packets and disk accesses), I thought that an address space was
> better.

Both are okay.  The IOMMU makes address space changes faster; your
scheme is basically a form of caching, it trades update performance for
improved translation performance.

The trick you're using with shadowing the RAM is nifty, but it leaks a
memory region.  I'll reply to the main patch.

Paolo

  reply	other threads:[~2015-03-26 14:16 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-05 22:13 [Qemu-devel] [PATCH 0/8] net/dp8393x improvements Hervé Poussineau
2015-03-05 22:13 ` [Qemu-devel] [PATCH 1/8] rc4030: create custom DMA address space Hervé Poussineau
2015-03-25 14:45   ` Paolo Bonzini
2015-03-25 19:10     ` Hervé Poussineau
2015-03-26 14:15       ` Paolo Bonzini [this message]
2015-03-26 14:27   ` Paolo Bonzini
2015-03-05 22:13 ` [Qemu-devel] [PATCH 2/8] rc4030: use AddressSpace and address_space_rw in users Hervé Poussineau
2015-03-05 22:13 ` [Qemu-devel] [PATCH 3/8] net/dp8393x: always calculate proper checksums Hervé Poussineau
2015-03-05 22:13 ` [Qemu-devel] [PATCH 4/8] net/dp8393x: do not use old_mmio accesses Hervé Poussineau
2015-03-05 22:13 ` [Qemu-devel] [PATCH 5/8] net/dp8393x: use dp8393x_ prefix for all functions Hervé Poussineau
2015-03-05 22:13 ` [Qemu-devel] [PATCH 6/8] net/dp8393x: QOM'ify Hervé Poussineau
2015-03-05 22:13 ` [Qemu-devel] [PATCH 7/8] net/dp8393x: add PROM to store MAC address Hervé Poussineau
2015-03-05 22:13 ` [Qemu-devel] [PATCH 8/8] net/dp8393x: add load/save support Hervé Poussineau
2015-03-25 14:13 ` [Qemu-devel] [PATCH 0/8] net/dp8393x improvements Leon Alrae
2015-04-29 14:56   ` Leon Alrae
2015-05-14 21:11     ` Hervé Poussineau

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=5514147E.8050509@redhat.com \
    --to=pbonzini@redhat.com \
    --cc=Laurent@Vivier.EU \
    --cc=aurelien@aurel32.net \
    --cc=hpoussin@reactos.org \
    --cc=leon.alrae@imgtec.com \
    --cc=qemu-devel@nongnu.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).