openvswitch: Simplify datapath locking.
Currently OVS uses combination of genl and rtnl lock to protect datapath state. This was done due to networking stack locking. But this has complicated locking and there are few lock ordering issues with new tunneling protocols. Following patch simplifies locking by introducing new ovs mutex and now this lock is used to protect entire ovs state. Signed-off-by: Pravin B Shelar <pshelar@nicira.com> Signed-off-by: Jesse Gross <jesse@nicira.com>
This commit is contained in:
committed by
Jesse Gross
parent
b4f9e8cdc8
commit
8e4e1713e4
@@ -138,14 +138,14 @@ struct vport_parms {
|
||||
struct vport_ops {
|
||||
enum ovs_vport_type type;
|
||||
|
||||
/* Called with RTNL lock. */
|
||||
/* Called with ovs_mutex. */
|
||||
struct vport *(*create)(const struct vport_parms *);
|
||||
void (*destroy)(struct vport *);
|
||||
|
||||
int (*set_options)(struct vport *, struct nlattr *);
|
||||
int (*get_options)(const struct vport *, struct sk_buff *);
|
||||
|
||||
/* Called with rcu_read_lock or RTNL lock. */
|
||||
/* Called with rcu_read_lock or ovs_mutex. */
|
||||
const char *(*get_name)(const struct vport *);
|
||||
void (*get_config)(const struct vport *, void *);
|
||||
int (*get_ifindex)(const struct vport *);
|
||||
|
Reference in New Issue
Block a user