git://git.onelab.eu
/
sliver-openvswitch.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
datapath: Add support for kernel 3.14.
[sliver-openvswitch.git]
/
datapath
/
vport.c
diff --git
a/datapath/vport.c
b/datapath/vport.c
index
8f618b5
..
0dcecd0
100644
(file)
--- a/
datapath/vport.c
+++ b/
datapath/vport.c
@@
-142,14
+142,14
@@
struct vport *ovs_vport_alloc(int priv_size, const struct vport_ops *ops,
if (ovs_vport_set_upcall_portids(vport, parms->upcall_portids))
return ERR_PTR(-EINVAL);
if (ovs_vport_set_upcall_portids(vport, parms->upcall_portids))
return ERR_PTR(-EINVAL);
- vport->percpu_stats = alloc_percpu(struct pcpu_tstats);
+ vport->percpu_stats = alloc_percpu(struct pcpu_
sw_ne
tstats);
if (!vport->percpu_stats) {
kfree(vport);
return ERR_PTR(-ENOMEM);
}
for_each_possible_cpu(i) {
if (!vport->percpu_stats) {
kfree(vport);
return ERR_PTR(-ENOMEM);
}
for_each_possible_cpu(i) {
- struct pcpu_tstats *vport_stats;
+ struct pcpu_
sw_ne
tstats *vport_stats;
vport_stats = per_cpu_ptr(vport->percpu_stats, i);
u64_stats_init(&vport_stats->syncp);
}
vport_stats = per_cpu_ptr(vport->percpu_stats, i);
u64_stats_init(&vport_stats->syncp);
}
@@
-302,8
+302,8
@@
void ovs_vport_get_stats(struct vport *vport, struct ovs_vport_stats *stats)
spin_unlock_bh(&vport->stats_lock);
for_each_possible_cpu(i) {
spin_unlock_bh(&vport->stats_lock);
for_each_possible_cpu(i) {
- const struct pcpu_tstats *percpu_stats;
- struct pcpu_tstats local_stats;
+ const struct pcpu_
sw_ne
tstats *percpu_stats;
+ struct pcpu_
sw_ne
tstats local_stats;
unsigned int start;
percpu_stats = per_cpu_ptr(vport->percpu_stats, i);
unsigned int start;
percpu_stats = per_cpu_ptr(vport->percpu_stats, i);
@@
-436,7
+436,7
@@
int ovs_vport_get_upcall_portids(const struct vport *vport,
* @vport: vport from which the missed packet is received.
* @skb: skb that the missed packet was received.
*
* @vport: vport from which the missed packet is received.
* @skb: skb that the missed packet was received.
*
- * Uses the skb_get_
rx
hash() to select the upcall portid to send the
+ * Uses the skb_get_hash() to select the upcall portid to send the
* upcall.
*
* Returns the portid of the target socket. Must be called with rcu_read_lock.
* upcall.
*
* Returns the portid of the target socket. Must be called with rcu_read_lock.
@@
-451,7
+451,7
@@
u32 ovs_vport_find_upcall_portid(const struct vport *p, struct sk_buff *skb)
if (ids->n_ids == 1 && ids->ids[0] == 0)
return 0;
if (ids->n_ids == 1 && ids->ids[0] == 0)
return 0;
- hash = skb_get_
rx
hash(skb);
+ hash = skb_get_hash(skb);
return ids->ids[hash - ids->n_ids * reciprocal_divide(hash, ids->rn_ids)];
}
return ids->ids[hash - ids->n_ids * reciprocal_divide(hash, ids->rn_ids)];
}
@@
-469,7
+469,7
@@
u32 ovs_vport_find_upcall_portid(const struct vport *p, struct sk_buff *skb)
void ovs_vport_receive(struct vport *vport, struct sk_buff *skb,
struct ovs_key_ipv4_tunnel *tun_key)
{
void ovs_vport_receive(struct vport *vport, struct sk_buff *skb,
struct ovs_key_ipv4_tunnel *tun_key)
{
- struct pcpu_tstats *stats;
+ struct pcpu_
sw_ne
tstats *stats;
stats = this_cpu_ptr(vport->percpu_stats);
u64_stats_update_begin(&stats->syncp);
stats = this_cpu_ptr(vport->percpu_stats);
u64_stats_update_begin(&stats->syncp);
@@
-495,7
+495,7
@@
int ovs_vport_send(struct vport *vport, struct sk_buff *skb)
int sent = vport->ops->send(vport, skb);
if (likely(sent > 0)) {
int sent = vport->ops->send(vport, skb);
if (likely(sent > 0)) {
- struct pcpu_tstats *stats;
+ struct pcpu_
sw_ne
tstats *stats;
stats = this_cpu_ptr(vport->percpu_stats);
stats = this_cpu_ptr(vport->percpu_stats);