lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite for Android: free password hash cracker in your pocket
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 7 Oct 2014 21:55:21 -0700
From:	Stephen Hemminger <stephen@...workplumber.org>
To:	Simon Horman <simon.horman@...ronome.com>
Cc:	dev@...nvswitch.org, netdev@...r.kernel.org,
	Pravin Shelar <pshelar@...ira.com>,
	Jesse Gross <jesse@...ira.com>, Jiri Pirko <jiri@...nulli.us>,
	Thomas Graf <tgraf@...g.ch>,
	John Fastabend <john.r.fastabend@...el.com>,
	Scott Feldman <sfeldma@...il.com>,
	Roopa Prabhu <roopa@...ulusnetworks.com>,
	Alexi Starovoitov <alexei.starovoitov@...il.com>,
	Florian Fainelli <f.fainelli@...il.com>,
	Jamal Hadi Salim <jhs@...atatu.com>,
	Bert van Leeuwen <bert.vanleeuwen@...ronome.com>
Subject: Re: [PATCH/RFC] datapath: offload hooks

On Wed,  8 Oct 2014 09:40:51 +0900
Simon Horman <simon.horman@...ronome.com> wrote:

> +
> +struct ovs_offload_ops {
> +	/* Flow offload functions  */
> +	/* Called when a flow entry is added to the flow table */
> +	void (*flow_new)(struct sw_flow *);
> +	/* Called when a flow entry is modified */
> +	void (*flow_set)(struct sw_flow *);
> +	/* Called when a flow entry is removed from the flow table */
> +	void (*flow_del)(struct sw_flow *);
> +	/* Called when flow stats are queried */
> +	void (*flow_stats_get)(const struct sw_flow *, struct ovs_flow_stats *,
> +			      unsigned long *used, __be16 *tcp_flags);
> +	/* Called when flow stats are removed */
> +	void (*flow_stats_clear)(struct sw_flow *);
> +
> +	/* Port offload functions  */
> +	/* Called when a vport is added to the datapath */
> +	void (*vport_new)(struct sk_buff *, struct vport *,
> +			  struct vport_parms *);
> +	/* Called when a vport is modified */
> +	void (*vport_set)(struct sk_buff *, struct vport *);
> +	/* Called when a vport is removed from the datapath */
> +	void (*vport_del)(struct sk_buff *, struct vport *);
> +	/* Called when vport stats are queried */
> +	void (*vport_stats_get)(struct vport *, struct ovs_vport_stats *);
> +	/* Called when vport stats are set */
> +	void (*vport_stats_set)(struct vport *, struct ovs_vport_stats *);
> +
> +	/* Datapath offload functions  */
> +	/* Called when the datapath is created */
> +	void (*dp_new)(struct datapath *);
> +	/* Called when the datapath is modified */
> +	void (*dp_set)(struct datapath *);
> +	/* Called when the datapath is removed */
> +	void (*dp_del)(struct datapath *);
> +	/* Called when the datapath stats are queried */
> +	void (*dp_stats_get)(struct datapath *, struct ovs_dp_stats *);
> +};

What about using netlink and netlink notifiers for event type stuff?
Much easier to extend than all the _ops stuff and you can provide
hook for people that want to do it in user space.
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ