From: Jakub Kicinski <kuba@kernel.org>
To: dsahern@kernel.org, Ido Schimmel <idosch@nvidia.com>
Cc: Saranya Panjarathina <plsaranya@gmail.com>,
netdev@vger.kernel.org, Saranya_Panjarathina@dell.com,
davem@davemloft.net, yoshfuji@linux-ipv6.org,
edumazet@google.com, pabeni@redhat.com,
linux-kernel@vger.kernel.org, g_balaji1@dell.com,
Nikolay Aleksandrov <razor@blackwall.org>
Subject: Re: [PATCH net-next] net: PIM register decapsulation and Forwarding.
Date: Tue, 17 May 2022 17:10:26 -0700 [thread overview]
Message-ID: <20220517171026.1230e034@kernel.org> (raw)
In-Reply-To: <20220516112906.2095-1-plsaranya@gmail.com>
On Mon, 16 May 2022 04:29:06 -0700 Saranya Panjarathina wrote:
> PIM register packet is decapsulated but not forwarded in RP
>
> __pim_rcv decapsulates the PIM register packet and reinjects for forwarding
> after replacing the skb->dev to reg_dev (vif with VIFF_Register)
>
> Ideally the incoming device should be same as skb->dev where the
> original PIM register packet is received. mcache would not have
> reg_vif as IIF. Decapsulated packet forwarding is failing
> because of IIF mismatch. In RP for this S,G RPF interface would be
> skb->dev vif only, so that would be IIF for the cache entry.
>
> Signed-off-by: Saranya Panjarathina <plsaranya@gmail.com>
Not sure if this can cause any trouble. And why it had become
a problem now, seems like the code has been this way forever.
David? Ido?
> diff --git a/net/ipv4/ipmr.c b/net/ipv4/ipmr.c
> index 13e6329784fb..7b9586335fb7 100644
> --- a/net/ipv4/ipmr.c
> +++ b/net/ipv4/ipmr.c
> @@ -598,7 +598,7 @@ static int __pim_rcv(struct mr_table *mrt, struct sk_buff *skb,
> skb->protocol = htons(ETH_P_IP);
> skb->ip_summed = CHECKSUM_NONE;
>
> - skb_tunnel_rx(skb, reg_dev, dev_net(reg_dev));
> + skb_tunnel_rx(skb, skb->dev, dev_net(skb->dev));
>
> netif_rx(skb);
>
> diff --git a/net/ipv6/ip6mr.c b/net/ipv6/ip6mr.c
> index 4e74bc61a3db..147e29a818ca 100644
> --- a/net/ipv6/ip6mr.c
> +++ b/net/ipv6/ip6mr.c
> @@ -566,7 +566,7 @@ static int pim6_rcv(struct sk_buff *skb)
> skb->protocol = htons(ETH_P_IPV6);
> skb->ip_summed = CHECKSUM_NONE;
>
> - skb_tunnel_rx(skb, reg_dev, dev_net(reg_dev));
> + skb_tunnel_rx(skb, skb->dev, net);
>
> netif_rx(skb);
>
next prev parent reply other threads:[~2022-05-18 0:10 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-05-12 7:01 [PATCH net-next] net: PIM register decapsulation and Forwarding Saranya_PL
2022-05-13 17:13 ` Jakub Kicinski
2022-05-14 14:33 ` [patch netdev] " Saranya Panjarathina
2022-05-16 11:29 ` [PATCH net-next] " Saranya Panjarathina
2022-05-18 0:10 ` Jakub Kicinski [this message]
2022-05-18 9:08 ` Ido Schimmel
2022-05-18 14:16 ` Ido Schimmel
2022-05-18 14:36 ` David Ahern
2022-05-18 16:18 ` Jakub Kicinski
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20220517171026.1230e034@kernel.org \
--to=kuba@kernel.org \
--cc=Saranya_Panjarathina@dell.com \
--cc=davem@davemloft.net \
--cc=dsahern@kernel.org \
--cc=edumazet@google.com \
--cc=g_balaji1@dell.com \
--cc=idosch@nvidia.com \
--cc=linux-kernel@vger.kernel.org \
--cc=netdev@vger.kernel.org \
--cc=pabeni@redhat.com \
--cc=plsaranya@gmail.com \
--cc=razor@blackwall.org \
--cc=yoshfuji@linux-ipv6.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).