On 9/9/25 10:41 AM, Ido Schimmel wrote:
> On Fri, Sep 05, 2025 at 03:30:55PM +0200, Ilya Maximets wrote:
>> @@ -220,9 +221,15 @@ static inline struct metadata_dst *ip_tun_rx_dst(struct 
>> sk_buff *skb,
>>                                               int md_size)
>>  {
>>      const struct iphdr *iph = ip_hdr(skb);
>> +    struct metadata_dst *tun_dst;
>> +
>> +    tun_dst = __ip_tun_set_dst(iph->saddr, iph->daddr, iph->tos, iph->ttl,
>> +                               0, flags, tunnel_id, md_size);
>>  
>> -    return __ip_tun_set_dst(iph->saddr, iph->daddr, iph->tos, iph->ttl,
>> -                            0, flags, tunnel_id, md_size);
>> +    if (iph->frag_off & htons(IP_DF))
>> +            __set_bit(IP_TUNNEL_DONT_FRAGMENT_BIT,
>> +                      tun_dst->u.tun_info.key.tun_flags);
> 
> Shouldn't you check that tun_dst isn't NULL?

That's true.  It should be:  if (tun_dst && ...)
I had too many versions of this change and lost the check in the end.

Will wait a bit and then send a v2.

Thanks!

Best regards, Ilya Maximets.

Reply via email to