__be32 src_vni;
u32 nhid;
__be32 vni;
+ __be16 port;
};
static bool vxlan_fdb_is_default_entry(const struct vxlan_fdb *f,
static bool
vxlan_fdb_flush_should_match_remotes(const struct vxlan_fdb_flush_desc *desc)
{
- return !!desc->vni;
+ return desc->vni || desc->port;
}
static bool
if (desc->vni && rd->remote_vni != desc->vni)
return false;
+ if (desc->port && rd->remote_port != desc->port)
+ return false;
+
return true;
}
[NDA_SRC_VNI] = { .type = NLA_U32 },
[NDA_NH_ID] = { .type = NLA_U32 },
[NDA_VNI] = { .type = NLA_U32 },
+ [NDA_PORT] = { .type = NLA_U16 },
[NDA_NDM_STATE_MASK] = { .type = NLA_U16 },
[NDA_NDM_FLAGS_MASK] = { .type = NLA_U8 },
};
if (tb[NDA_VNI])
desc.vni = cpu_to_be32(nla_get_u32(tb[NDA_VNI]));
+ if (tb[NDA_PORT])
+ desc.port = nla_get_be16(tb[NDA_PORT]);
+
vxlan_flush(vxlan, &desc);
return 0;