hc
2024-10-22 8ac6c7a54ed1b98d142dce24b11c6de6a1e239a5
kernel/net/ipv6/icmp.c
....@@ -429,7 +429,10 @@
429429 if (unlikely(dev->ifindex == LOOPBACK_IFINDEX || netif_is_l3_master(skb->dev))) {
430430 const struct rt6_info *rt6 = skb_rt6_info(skb);
431431
432
- if (rt6)
432
+ /* The destination could be an external IP in Ext Hdr (SRv6, RPL, etc.),
433
+ * and ip6_null_entry could be set to skb if no route is found.
434
+ */
435
+ if (rt6 && rt6->rt6i_idev)
433436 dev = rt6->rt6i_idev->dev;
434437 }
435438