Re: [PATCH v2 net] udp: on peeking bad csum, drop packets even if not at head

2017-08-22 Thread David Miller
From: Eric Dumazet Date: Tue, 22 Aug 2017 09:39:28 -0700 > From: Eric Dumazet > > When peeking, if a bad csum is discovered, the skb is unlinked from > the queue with __sk_queue_drop_skb and the peek operation restarted. > > __sk_queue_drop_skb only drops packets that match the queue head. >

Re: [PATCH v2 net] udp: on peeking bad csum, drop packets even if not at head

2017-08-22 Thread Willem de Bruijn
On Tue, Aug 22, 2017 at 12:47 PM, Paolo Abeni wrote: > On Tue, 2017-08-22 at 09:39 -0700, Eric Dumazet wrote: >> From: Eric Dumazet >> >> When peeking, if a bad csum is discovered, the skb is unlinked from >> the queue with __sk_queue_drop_skb and the peek operation restarted. >> >> __sk_queue_dr

Re: [PATCH v2 net] udp: on peeking bad csum, drop packets even if not at head

2017-08-22 Thread Paolo Abeni
On Tue, 2017-08-22 at 09:39 -0700, Eric Dumazet wrote: > From: Eric Dumazet > > When peeking, if a bad csum is discovered, the skb is unlinked from > the queue with __sk_queue_drop_skb and the peek operation restarted. > > __sk_queue_drop_skb only drops packets that match the queue head. > > Th

[PATCH v2 net] udp: on peeking bad csum, drop packets even if not at head

2017-08-22 Thread Eric Dumazet
From: Eric Dumazet When peeking, if a bad csum is discovered, the skb is unlinked from the queue with __sk_queue_drop_skb and the peek operation restarted. __sk_queue_drop_skb only drops packets that match the queue head. This fails if the skb was found after the head, using SO_PEEK_OFF socket