On Fri, Aug 2, 2024 at 10:35 PM Christophe JAILLET
[off-list ref] wrote:
The extra () around "ip_hdrlen(skb)" can be remove.
Also maybe the ones around "ETH_HLEN + ip_hdrlen(skb)" could also be
removed.
Okay, I'll send the next patch which the parenthesis are removed!
But... The parenthesis around `ETH_HLEN + ip_hdrlen(skb) +
sizeof(struct udphdr)`
should be retained, because it makes a clear boundary.
quoted
skb_reset_network_header(skb);
return csum;
}
- skb_set_transport_header(skb,
- ETH_HLEN + (ip_hdr(skb)->ihl << 2));
+ skb_set_transport_header(skb, ETH_HLEN + (ip_hdrlen(skb)));
Same here, the extra () around "ip_hdrlen(skb)" can be remove.
I'll remove it also.
CJ
quoted
csum = udp_hdr(skb)->check;
skb_reset_transport_header(skb);
skb_reset_network_header(skb);
Thank you for reviewing ^오^