Subject: Re: [PATCH 1/2] [IPV4] UDP: Always checksum even if without socket filter

From: Wang Chen <[email-masked]>
Date: Mon, 19 Nov 2007 10:02:03 +0800

David Miller said the following on 2007-11-19 6:40:
> We could defer the increment until we check the checksum,
> but that is likely to break even more things because people
> (as Wang Chen did initially) will send a packet to some
> port with an app that doesn't eat the packets, and expect the
> InDatagrams counter to increase once the stack eats the packet.

As Herbert referred, RFC1213 says that udpInDatagrams records
"The total number of UDP datagrams delivered to UDP users."

So if "udp_queue_rcv_skb() doing sucessfully" means "a UDP
datagrams delivered to UDP users", the InDatagrams should be
increased in udp_queue_rcv_skb().
Otherwise it should be increased until the UDP datagrams is
actually delivered to UDP users.