diff options
author | 2017-04-25 03:31:15 -0700 | |
---|---|---|
committer | 2017-05-22 06:48:08 +0000 | |
commit | bb756eebdac6fd24e8919e2c43f7d2c8c4091f59 (patch) | |
tree | ca11e03542edf2d8f631efeca5e1626d211107e3 /qemu/include/net/filter.h | |
parent | a14b48d18a9ed03ec191cf16b162206998a895ce (diff) |
Adding qemu as a submodule of KVMFORNFV
This Patch includes the changes to add qemu as a submodule to
kvmfornfv repo and make use of the updated latest qemu for the
execution of all testcase
Change-Id: I1280af507a857675c7f81d30c95255635667bdd7
Signed-off-by:RajithaY<rajithax.yerrumsetty@intel.com>
Diffstat (limited to 'qemu/include/net/filter.h')
-rw-r--r-- | qemu/include/net/filter.h | 79 |
1 files changed, 0 insertions, 79 deletions
diff --git a/qemu/include/net/filter.h b/qemu/include/net/filter.h deleted file mode 100644 index 0c4a2ea6c..000000000 --- a/qemu/include/net/filter.h +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Copyright (c) 2015 FUJITSU LIMITED - * Author: Yang Hongyang <yanghy@cn.fujitsu.com> - * - * This work is licensed under the terms of the GNU GPL, version 2 or - * later. See the COPYING file in the top-level directory. - */ - -#ifndef QEMU_NET_FILTER_H -#define QEMU_NET_FILTER_H - -#include "qom/object.h" -#include "qemu-common.h" -#include "net/queue.h" - -#define TYPE_NETFILTER "netfilter" -#define NETFILTER(obj) \ - OBJECT_CHECK(NetFilterState, (obj), TYPE_NETFILTER) -#define NETFILTER_GET_CLASS(obj) \ - OBJECT_GET_CLASS(NetFilterClass, (obj), TYPE_NETFILTER) -#define NETFILTER_CLASS(klass) \ - OBJECT_CLASS_CHECK(NetFilterClass, (klass), TYPE_NETFILTER) - -typedef void (FilterSetup) (NetFilterState *nf, Error **errp); -typedef void (FilterCleanup) (NetFilterState *nf); -/* - * Return: - * 0: finished handling the packet, we should continue - * size: filter stolen this packet, we stop pass this packet further - */ -typedef ssize_t (FilterReceiveIOV)(NetFilterState *nc, - NetClientState *sender, - unsigned flags, - const struct iovec *iov, - int iovcnt, - NetPacketSent *sent_cb); - -typedef void (FilterStatusChanged) (NetFilterState *nf, Error **errp); - -typedef struct NetFilterClass { - ObjectClass parent_class; - - /* optional */ - FilterSetup *setup; - FilterCleanup *cleanup; - FilterStatusChanged *status_changed; - /* mandatory */ - FilterReceiveIOV *receive_iov; -} NetFilterClass; - - -struct NetFilterState { - /* private */ - Object parent; - - /* protected */ - char *netdev_id; - NetClientState *netdev; - NetFilterDirection direction; - bool on; - QTAILQ_ENTRY(NetFilterState) next; -}; - -ssize_t qemu_netfilter_receive(NetFilterState *nf, - NetFilterDirection direction, - NetClientState *sender, - unsigned flags, - const struct iovec *iov, - int iovcnt, - NetPacketSent *sent_cb); - -/* pass the packet to the next filter */ -ssize_t qemu_netfilter_pass_to_next(NetClientState *sender, - unsigned flags, - const struct iovec *iov, - int iovcnt, - void *opaque); - -#endif /* QEMU_NET_FILTER_H */ |