From: Thomas Graf <tgraf@noironetworks.com>
To: Andy Zhou <azhou@nicira.com>
Cc: dev@openvswitch.com, netdev@vger.kernel.org
Subject: Re: [ovs-dev] [RFC: add openvswitch actions using BPF 2/9] odp: add a new ODP action: OVS_ACTION_ATTR_BPF_PROG
Date: Thu, 5 Feb 2015 14:56:16 +0100 [thread overview]
Message-ID: <20150205135616.GB5546@pox.localdomain> (raw)
In-Reply-To: <1423090163-19902-3-git-send-email-azhou@nicira.com>
On 02/04/15 at 02:49pm, Andy Zhou wrote:
> /**
> + * struct ovs_action_bpf_prog - %OVS_ACTION_ATTR_BPF_PROG action argument.
> + *
> + * XXX provides bpf program id and execution context.
> + *
> + */
> +struct ovs_action_bpf_prog {
> + __be32 prog_fd;
> + __be32 arg0;
> + __be32 arg1;
> +};
I assume you intend to replace this with a nested Netlink attribute with a
series of U32 attributes to carry args in the future?
> +enum ovs_bpf_func_id {
> + OVS_BPF_FUNC_unspec,
> + OVS_BPF_FUNC_output, /* int ovs_bpf_output(ctxt) */
> + __OVS_BPF_FUNC_MAX_ID,
> +};
The mix of cap / no-cap looks a bit weird.
> +static void
> +format_bpf_prog_action(struct ds *ds, const struct nlattr *a)
> +{
> + struct ovs_action_bpf_prog *bpf_act = (struct ovs_action_bpf_prog *)
> + nl_attr_get(a);
> +
> + ds_put_cstr(ds, "bpf");
> + ds_put_format(ds, "(%u,%u,%u)", ntohl(bpf_act->prog_fd),
> + ntohl(bpf_act->arg0), ntohl(bpf_act->arg1));
> +}
Maybe ds_put_format(ds, "bpf(... ?
next prev parent reply other threads:[~2015-02-05 13:56 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-02-04 22:49 [RFC: add openvswitch actions using BPF 0/9] Andy Zhou
[not found] ` <1423090163-19902-1-git-send-email-azhou-l0M0P4e3n4LQT0dZR+AlfA@public.gmane.org>
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 1/9] hack: Do not compile datapath Andy Zhou
2015-02-05 13:44 ` [ovs-dev] " Thomas Graf
[not found] ` <20150205134454.GA5546-4EA/1caXOu0mYvmMESoHnA@public.gmane.org>
2015-02-05 19:11 ` Andy Zhou
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 2/9] odp: add a new ODP action: OVS_ACTION_ATTR_BPF_PROG Andy Zhou
2015-02-05 13:56 ` Thomas Graf [this message]
2015-02-05 14:11 ` [ovs-dev] " Thomas Graf
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 3/9] tests: add a OVS_ACTION_ATTR_BPF_PROG ation unit test case Andy Zhou
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 4/9] autoconf: support -with-llc options Andy Zhou
2015-02-06 18:12 ` Joe Stringer
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 5/9] bpf: add the first BPF program Andy Zhou
2015-02-05 14:18 ` [ovs-dev] " Thomas Graf
2015-02-05 19:16 ` Andy Zhou
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 6/9] lib: import into libbpf to ovs/lib Andy Zhou
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 7/9] ofproto-dpif: Add eBPF program loader and runtime infrasturcure Andy Zhou
2015-02-06 18:49 ` Joe Stringer
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 8/9] ofproto-dpif: Add datapath eBPF support detection Andy Zhou
2015-02-04 22:49 ` [RFC: add openvswitch actions using BPF 9/9] ofproto-dpif-xlate: generate BPF output action (Hack) Andy Zhou
2015-02-05 14:29 ` [ovs-dev] " Thomas Graf
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=20150205135616.GB5546@pox.localdomain \
--to=tgraf@noironetworks.com \
--cc=azhou@nicira.com \
--cc=dev@openvswitch.com \
--cc=netdev@vger.kernel.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