* [PATCH net] vxlan: fix last fdb index during dump of fdb with nhid
@ 2020-06-24 21:02 Roopa Prabhu
2020-06-25 23:13 ` David Miller
0 siblings, 1 reply; 2+ messages in thread
From: Roopa Prabhu @ 2020-06-24 21:02 UTC (permalink / raw)
To: davem, kuba; +Cc: netdev, nikolay, julien
From: Roopa Prabhu <roopa@cumulusnetworks.com>
This patch fixes last saved fdb index in fdb dump handler when
handling fdb's with nhid.
Fixes: 1274e1cc4226 ("vxlan: ecmp support for mac fdb entries")
Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
---
drivers/net/vxlan.c | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/drivers/net/vxlan.c b/drivers/net/vxlan.c
index e8085ab..89d85dc 100644
--- a/drivers/net/vxlan.c
+++ b/drivers/net/vxlan.c
@@ -1380,6 +1380,8 @@ static int vxlan_fdb_dump(struct sk_buff *skb, struct netlink_callback *cb,
struct vxlan_rdst *rd;
if (rcu_access_pointer(f->nh)) {
+ if (*idx < cb->args[2])
+ goto skip_nh;
err = vxlan_fdb_info(skb, vxlan, f,
NETLINK_CB(cb->skb).portid,
cb->nlh->nlmsg_seq,
@@ -1387,6 +1389,8 @@ static int vxlan_fdb_dump(struct sk_buff *skb, struct netlink_callback *cb,
NLM_F_MULTI, NULL);
if (err < 0)
goto out;
+skip_nh:
+ *idx += 1;
continue;
}
--
2.1.4
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: [PATCH net] vxlan: fix last fdb index during dump of fdb with nhid
2020-06-24 21:02 [PATCH net] vxlan: fix last fdb index during dump of fdb with nhid Roopa Prabhu
@ 2020-06-25 23:13 ` David Miller
0 siblings, 0 replies; 2+ messages in thread
From: David Miller @ 2020-06-25 23:13 UTC (permalink / raw)
To: roopa; +Cc: kuba, netdev, nikolay, julien
From: Roopa Prabhu <roopa@cumulusnetworks.com>
Date: Wed, 24 Jun 2020 14:02:36 -0700
> From: Roopa Prabhu <roopa@cumulusnetworks.com>
>
> This patch fixes last saved fdb index in fdb dump handler when
> handling fdb's with nhid.
>
> Fixes: 1274e1cc4226 ("vxlan: ecmp support for mac fdb entries")
> Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com>
Applied, thanks Roopa.
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-06-25 23:13 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-24 21:02 [PATCH net] vxlan: fix last fdb index during dump of fdb with nhid Roopa Prabhu
2020-06-25 23:13 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).