mirror of
https://github.com/openvswitch/ovs
synced 2025-08-31 14:25:26 +00:00
datapath: Strip down vport interface - ifIndex.
Following patch removes ifIndex attribute of vport which is not used in userspace. Signed-off-by: Pravin B Shelar <pshelar@nicira.com> Acked-by: Jesse Gross <jesse@nicira.com> Bug #7114
This commit is contained in:
@@ -1299,7 +1299,6 @@ dpif_linux_vport_from_ofpbuf(struct dpif_linux_vport *vport,
|
||||
.max_len = ETH_ADDR_LEN,
|
||||
.optional = true },
|
||||
[OVS_VPORT_ATTR_OPTIONS] = { .type = NL_A_NESTED, .optional = true },
|
||||
[OVS_VPORT_ATTR_IFINDEX] = { .type = NL_A_U32, .optional = true },
|
||||
};
|
||||
|
||||
struct nlattr *a[ARRAY_SIZE(ovs_vport_policy)];
|
||||
@@ -1339,9 +1338,6 @@ dpif_linux_vport_from_ofpbuf(struct dpif_linux_vport *vport,
|
||||
vport->options = nl_attr_get(a[OVS_VPORT_ATTR_OPTIONS]);
|
||||
vport->options_len = nl_attr_get_size(a[OVS_VPORT_ATTR_OPTIONS]);
|
||||
}
|
||||
if (a[OVS_VPORT_ATTR_IFINDEX]) {
|
||||
vport->ifindex = nl_attr_get_u32(a[OVS_VPORT_ATTR_IFINDEX]);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
@@ -1387,10 +1383,6 @@ dpif_linux_vport_to_ofpbuf(const struct dpif_linux_vport *vport,
|
||||
nl_msg_put_nested(buf, OVS_VPORT_ATTR_OPTIONS,
|
||||
vport->options, vport->options_len);
|
||||
}
|
||||
|
||||
if (vport->ifindex) {
|
||||
nl_msg_put_u32(buf, OVS_VPORT_ATTR_IFINDEX, vport->ifindex);
|
||||
}
|
||||
}
|
||||
|
||||
/* Clears 'vport' to "empty" values. */
|
||||
|
Reference in New Issue
Block a user