[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Qemu-devel] [PATCH 2/4] net: add net_is_tap_client()
From: |
Stefan Hajnoczi |
Subject: |
Re: [Qemu-devel] [PATCH 2/4] net: add net_is_tap_client() |
Date: |
Thu, 18 Oct 2012 17:48:55 +0200 |
User-agent: |
Mutt/1.5.21 (2010-09-15) |
On Thu, Oct 18, 2012 at 05:05:51PM +0200, Paolo Bonzini wrote:
> Il 18/10/2012 16:56, Stefan Hajnoczi ha scritto:
> > From: Stefan Hajnoczi <address@hidden>
> >
> > The vhost-net code interacts closely with the net/tap.c backend so that
> > it can pass the underlying file descriptor to the vhost_net.ko driver.
> > We need a check that confirms a NetClientState is indeed a tap backend
> > (and not something else like slirp or socket).
>
> Could you use object_dynamic_cast(OBJECT(backend), TYPE_TAP_NET_CLIENT)
> instead?
Yes.
Stefan