netdev.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Anthony Liguori <anthony@codemonkey.ws>
To: "Ira W. Snyder" <iws@ovro.caltech.edu>
Cc: Kyle Moffett <kyle@moffetthome.net>,
	Gregory Haskins <gregory.haskins@gmail.com>,
	kvm@vger.kernel.org, netdev@vger.kernel.org,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"alacrityvm-devel@lists.sourceforge.net"
	<alacrityvm-devel@lists.sourceforge.net>,
	Avi Kivity <avi@redhat.com>, Ingo Molnar <mingo@elte.hu>,
	torvalds@linux-foundation.org,
	Andrew Morton <akpm@linux-foundation.org>
Subject: Re: [Alacrityvm-devel] [GIT PULL] AlacrityVM guest drivers for 2.6.33
Date: Thu, 24 Dec 2009 11:09:39 -0600	[thread overview]
Message-ID: <4B33A053.9090009@codemonkey.ws> (raw)
In-Reply-To: <20091223234256.GC30700@ovro.caltech.edu>

On 12/23/2009 05:42 PM, Ira W. Snyder wrote:
>
> I've got a single PCI Host (master) with ~20 PCI slots. Physically, it
> is a backplane in a cPCI chassis, but the form factor is irrelevant. It
> is regular PCI from a software perspective.
>
> Into this backplane, I plug up to 20 PCI Agents (slaves). They are
> powerpc computers, almost identical to the Freescale MPC8349EMDS board.
> They're full-featured powerpc computers, with CPU, RAM, etc. They can
> run standalone.
>
> I want to use the PCI backplane as a data transport. Specifically, I
> want to transport ethernet over the backplane, so I can have the powerpc
> boards mount their rootfs via NFS, etc. Everyone knows how to write
> network daemons. It is a good and very well known way to transport data
> between systems.
>
> On the PCI bus, the powerpc systems expose 3 PCI BAR's. The size is
> configureable, as is the memory location at which they point. What I
> cannot do is get notified when a read/write hits the BAR. There is a
> feature on the board which allows me to generate interrupts in either
> direction: agent->master (PCI INTX) and master->agent (via an MMIO
> register). The PCI vendor ID and device ID are not configureable.
>
> One thing I cannot assume is that the PCI master system is capable of
> performing DMA. In my system, it is a Pentium3 class x86 machine, which
> has no DMA engine. However, the PowerPC systems do have DMA engines. In
> virtio terms, it was suggested to make the powerpc systems the "virtio
> hosts" (running the backends) and make the x86 (PCI master) the "virtio
> guest" (running virtio-net, etc.).

IMHO, virtio and vbus are both the wrong model for what you're doing. 
The key reason why is that virtio and vbus are generally designed around 
the concept that there is shared cache coherent memory from which you 
can use lock-less ring queues to implement efficient I/O.

In your architecture, you do not have cache coherent shared memory. 
Instead, you have two systems connected via a PCI backplace with 
non-coherent shared memory.

You probably need to use the shared memory as a bounce buffer and 
implement a driver on top of that.

> I'm not sure what you're suggesting in the paragraph above. I want to
> use virtio-net as the transport, I do not want to write my own
> virtual-network driver. Can you please clarify?

virtio-net and vbus are going to be overly painful for you to use 
because no one end can access arbitrary memory in the other end.

> Hopefully that explains what I'm trying to do. I'd love someone to help
> guide me in the right direction here. I want something to fill this need
> in mainline.

If I were you, I would write a custom network driver.  virtio-net is 
awfully small (just a few hundred lines).  I'd use that as a basis but I 
would not tie into virtio or vbus.  The paradigms don't match.

> I've been contacted seperately by 10+ people also looking
> for a similar solution. I hunch most of them end up doing what I did:
> write a quick-and-dirty network driver. I've been working on this for a
> year, just to give an idea.

The whole architecture of having multiple heterogenous systems on a 
common high speed backplane is what IBM refers to as "hybrid computing". 
  It's a model that I think will be come a lot more common in the 
future.  I think there are typically two types of hybrid models 
depending on whether the memory sharing is cache coherent or not.  If 
you have coherent shared memory, the problem looks an awfully lot like 
virtualization.  If you don't have coherent shared memory, then the 
shared memory basically becomes a pool to bounce into and out-of.

> PS - should I create a new thread on the two mailing lists mentioned
> above? I don't want to go too far off-topic in an alacrityvm thread. :)

Couldn't hurt.

Regards,

Anthony Liguori

  reply	other threads:[~2009-12-24 17:09 UTC|newest]

Thread overview: 105+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-12-07 18:53 [GIT PULL] AlacrityVM guest drivers for 2.6.33 Gregory Haskins
2009-12-18 21:51 ` Ingo Molnar
2009-12-21 15:34   ` Gregory Haskins
2009-12-21 15:43     ` Avi Kivity
2009-12-21 16:04       ` Gregory Haskins
2009-12-21 16:37         ` Anthony Liguori
2009-12-21 16:40           ` Avi Kivity
2009-12-21 16:56             ` Gregory Haskins
2009-12-21 17:05               ` Avi Kivity
2009-12-21 17:24                 ` Gregory Haskins
2009-12-21 16:46           ` Gregory Haskins
2009-12-21 17:20             ` Anthony Liguori
2009-12-21 17:44               ` Gregory Haskins
2009-12-22  0:12                 ` Anthony Liguori
2009-12-22  7:59                   ` Ingo Molnar
2009-12-22 11:49                   ` Andi Kleen
2009-12-22 15:31                     ` Anthony Liguori
2009-12-22 16:01                       ` Bartlomiej Zolnierkiewicz
2009-12-22 16:21                         ` Anthony Liguori
2009-12-23  6:51                           ` Ingo Molnar
2009-12-23 10:13                             ` Andi Kleen
2009-12-23 10:22                               ` Avi Kivity
2009-12-23 12:14                                 ` Andi Kleen
2009-12-23 12:48                                   ` Avi Kivity
2009-12-23 17:00                                     ` Chris Wright
2009-12-23 17:20                                       ` Andi Kleen
2009-12-23 15:03                                   ` Anthony Liguori
2009-12-23 17:52                                   ` [Alacrityvm-devel] " Peter W. Morreale
2009-12-23 18:17                                     ` Gregory Haskins
2009-12-23 18:22                                     ` Chris Wright
2009-12-23 18:15                                 ` Gregory Haskins
2009-12-23 20:20                                   ` Avi Kivity
2009-12-23 21:21                                     ` Gregory Haskins
2009-12-27  9:15                                       ` Avi Kivity
2009-12-27 13:18                                         ` Gregory Haskins
2009-12-27 13:27                                           ` Avi Kivity
2009-12-27 13:39                                             ` Gregory Haskins
2009-12-27 13:49                                               ` Avi Kivity
2009-12-28  1:01                                                 ` Gregory Haskins
2009-12-23 18:51                               ` Ingo Molnar
2009-12-23 19:27                                 ` Andi Kleen
2009-12-23 20:26                                   ` Avi Kivity
2009-12-24  6:58                                 ` Gleb Natapov
2009-12-24 20:41                                   ` Roland Dreier
2009-12-23 13:07                             ` Bartlomiej Zolnierkiewicz
2009-12-23 13:31                               ` Avi Kivity
2009-12-23 14:08                                 ` Bartlomiej Zolnierkiewicz
2009-12-23 14:28                                   ` Avi Kivity
2009-12-23 14:57                               ` Anthony Liguori
2009-12-23 18:31                                 ` Chris Wright
2009-12-23 16:44                             ` Gregory Haskins
2009-12-23 17:10                               ` Andi Kleen
2009-12-23 17:17                                 ` Gregory Haskins
2009-12-23 17:29                                   ` Linus Torvalds
2009-12-23 23:27                                     ` Anthony Liguori
2009-12-23 17:33                                   ` Andi Kleen
2009-12-23 20:36                               ` Avi Kivity
2009-12-23 21:01                                 ` Avi Kivity
2009-12-24  9:36                                   ` Gregory Haskins
2009-12-27  9:33                                     ` Avi Kivity
2009-12-27 13:34                                       ` Gregory Haskins
2009-12-27 13:49                                         ` Avi Kivity
2009-12-27 14:29                                           ` Gregory Haskins
2009-12-24  9:31                                 ` Gregory Haskins
2009-12-27  9:29                                   ` Avi Kivity
2009-12-22 16:21                       ` Andi Kleen
2009-12-22 16:27                         ` Anthony Liguori
2009-12-22 17:33                           ` Andi Kleen
2009-12-22 17:35                             ` Avi Kivity
2009-12-22 21:14                             ` Anthony Liguori
2009-12-23  0:02                               ` Chris Wright
2009-12-23 15:12                                 ` Anthony Liguori
2009-12-23 15:17                                   ` Chris Wright
2009-12-22 17:05                         ` Avi Kivity
2009-12-22 20:41                   ` Gregory Haskins
2009-12-22  7:22                 ` Gleb Natapov
2009-12-22  7:57     ` Ingo Molnar
2009-12-22 17:36       ` Gregory Haskins
2009-12-22 18:53         ` Avi Kivity
2009-12-22 18:56           ` Gregory Haskins
2009-12-22 19:15           ` Gregory Haskins
2009-12-22 19:25             ` Avi Kivity
2009-12-22 19:32               ` Gregory Haskins
2009-12-22 19:37                 ` Gregory Haskins
2009-12-22 19:38                 ` Avi Kivity
2009-12-22 19:41                   ` Gregory Haskins
2009-12-22 19:43                     ` Avi Kivity
2009-12-22 19:47                       ` Gregory Haskins
2009-12-22 19:40                 ` Avi Kivity
2009-12-22 19:39             ` Davide Libenzi
2009-12-22 19:53               ` Gregory Haskins
2009-12-23  1:05                 ` Davide Libenzi
2009-12-23  6:15         ` Kyle Moffett
2009-12-23 15:09           ` Anthony Liguori
2009-12-23 19:54             ` [Alacrityvm-devel] " Ira W. Snyder
2009-12-23 22:58               ` Anthony Liguori
2009-12-23 23:42                 ` Ira W. Snyder
2009-12-24 17:09                   ` Anthony Liguori [this message]
2009-12-25  0:38                     ` Ira W. Snyder
2009-12-24  4:52                 ` Kyle Moffett
2009-12-24 16:57                   ` Anthony Liguori
2009-12-23 17:34           ` Gregory Haskins
2009-12-23 19:28             ` Ira W. Snyder
2009-12-23 19:50               ` Andi Kleen
2009-12-24 10:01               ` Michael S. Tsirkin

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=4B33A053.9090009@codemonkey.ws \
    --to=anthony@codemonkey.ws \
    --cc=akpm@linux-foundation.org \
    --cc=alacrityvm-devel@lists.sourceforge.net \
    --cc=avi@redhat.com \
    --cc=gregory.haskins@gmail.com \
    --cc=iws@ovro.caltech.edu \
    --cc=kvm@vger.kernel.org \
    --cc=kyle@moffetthome.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mingo@elte.hu \
    --cc=netdev@vger.kernel.org \
    --cc=torvalds@linux-foundation.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).