* [PATCH net-2.6] net/ipv6/udp.c: fix typo in flush_stack()
@ 2010-12-09 13:40 Jiri Pirko
2010-12-09 13:48 ` Eric Dumazet
0 siblings, 1 reply; 4+ messages in thread
From: Jiri Pirko @ 2010-12-09 13:40 UTC (permalink / raw)
To: netdev; +Cc: davem, eric.dumazet
skb1 should be passed as parameter to sk_rcvqueues_full() here.
Signed-off-by: Jiri Pirko <jpirko@redhat.com>
diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
index 91def93..d2b268e 100644
--- a/net/ipv6/udp.c
+++ b/net/ipv6/udp.c
@@ -602,7 +602,7 @@ static void flush_stack(struct sock **stack, unsigned int count,
sk = stack[i];
if (skb1) {
- if (sk_rcvqueues_full(sk, skb)) {
+ if (sk_rcvqueues_full(sk, skb1)) {
kfree_skb(skb1);
goto drop;
}
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH net-2.6] net/ipv6/udp.c: fix typo in flush_stack()
2010-12-09 13:40 [PATCH net-2.6] net/ipv6/udp.c: fix typo in flush_stack() Jiri Pirko
@ 2010-12-09 13:48 ` Eric Dumazet
2010-12-09 14:28 ` Jiri Pirko
2010-12-10 22:05 ` David Miller
0 siblings, 2 replies; 4+ messages in thread
From: Eric Dumazet @ 2010-12-09 13:48 UTC (permalink / raw)
To: Jiri Pirko; +Cc: netdev, davem
Le jeudi 09 décembre 2010 à 14:40 +0100, Jiri Pirko a écrit :
> skb1 should be passed as parameter to sk_rcvqueues_full() here.
>
> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
>
> diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
> index 91def93..d2b268e 100644
> --- a/net/ipv6/udp.c
> +++ b/net/ipv6/udp.c
> @@ -602,7 +602,7 @@ static void flush_stack(struct sock **stack, unsigned int count,
>
> sk = stack[i];
> if (skb1) {
> - if (sk_rcvqueues_full(sk, skb)) {
> + if (sk_rcvqueues_full(sk, skb1)) {
> kfree_skb(skb1);
> goto drop;
> }
net-2.6 ? Its the same truesize anyway...
So it's not a bug, but a cosmetic change.
(I am ok with it, but for net-next-2.6)
/*
* Take into account size of receive queue and backlog queue
*/
static inline bool sk_rcvqueues_full(const struct sock *sk, const struct sk_buff *skb)
{
unsigned int qsize = sk->sk_backlog.len + atomic_read(&sk->sk_rmem_alloc);
return qsize + skb->truesize > sk->sk_rcvbuf;
}
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH net-2.6] net/ipv6/udp.c: fix typo in flush_stack()
2010-12-09 13:48 ` Eric Dumazet
@ 2010-12-09 14:28 ` Jiri Pirko
2010-12-10 22:05 ` David Miller
1 sibling, 0 replies; 4+ messages in thread
From: Jiri Pirko @ 2010-12-09 14:28 UTC (permalink / raw)
To: Eric Dumazet; +Cc: netdev, davem
Thu, Dec 09, 2010 at 02:48:08PM CET, eric.dumazet@gmail.com wrote:
>Le jeudi 09 décembre 2010 à 14:40 +0100, Jiri Pirko a écrit :
>> skb1 should be passed as parameter to sk_rcvqueues_full() here.
>>
>> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
>>
>> diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
>> index 91def93..d2b268e 100644
>> --- a/net/ipv6/udp.c
>> +++ b/net/ipv6/udp.c
>> @@ -602,7 +602,7 @@ static void flush_stack(struct sock **stack, unsigned int count,
>>
>> sk = stack[i];
>> if (skb1) {
>> - if (sk_rcvqueues_full(sk, skb)) {
>> + if (sk_rcvqueues_full(sk, skb1)) {
>> kfree_skb(skb1);
>> goto drop;
>> }
>
>net-2.6 ? Its the same truesize anyway...
I know it is.
>
>So it's not a bug, but a cosmetic change.
>(I am ok with it, but for net-next-2.6)
Anything you like.
>
>/*
> * Take into account size of receive queue and backlog queue
> */
>static inline bool sk_rcvqueues_full(const struct sock *sk, const struct sk_buff *skb)
>{
> unsigned int qsize = sk->sk_backlog.len + atomic_read(&sk->sk_rmem_alloc);
>
> return qsize + skb->truesize > sk->sk_rcvbuf;
>}
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH net-2.6] net/ipv6/udp.c: fix typo in flush_stack()
2010-12-09 13:48 ` Eric Dumazet
2010-12-09 14:28 ` Jiri Pirko
@ 2010-12-10 22:05 ` David Miller
1 sibling, 0 replies; 4+ messages in thread
From: David Miller @ 2010-12-10 22:05 UTC (permalink / raw)
To: eric.dumazet; +Cc: jpirko, netdev
From: Eric Dumazet <eric.dumazet@gmail.com>
Date: Thu, 09 Dec 2010 14:48:08 +0100
> Le jeudi 09 décembre 2010 à 14:40 +0100, Jiri Pirko a écrit :
>> skb1 should be passed as parameter to sk_rcvqueues_full() here.
>>
>> Signed-off-by: Jiri Pirko <jpirko@redhat.com>
>>
>> diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
>> index 91def93..d2b268e 100644
>> --- a/net/ipv6/udp.c
>> +++ b/net/ipv6/udp.c
>> @@ -602,7 +602,7 @@ static void flush_stack(struct sock **stack, unsigned int count,
>>
>> sk = stack[i];
>> if (skb1) {
>> - if (sk_rcvqueues_full(sk, skb)) {
>> + if (sk_rcvqueues_full(sk, skb1)) {
>> kfree_skb(skb1);
>> goto drop;
>> }
>
> net-2.6 ? Its the same truesize anyway...
>
> So it's not a bug, but a cosmetic change.
> (I am ok with it, but for net-next-2.6)
Agreed, applied to net-next-2.6, thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2010-12-10 22:05 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2010-12-09 13:40 [PATCH net-2.6] net/ipv6/udp.c: fix typo in flush_stack() Jiri Pirko
2010-12-09 13:48 ` Eric Dumazet
2010-12-09 14:28 ` Jiri Pirko
2010-12-10 22:05 ` David Miller
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).