[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20110406183913.GB6825@hmsreliant.think-freely.org>
Date: Wed, 6 Apr 2011 14:39:13 -0400
From: Neil Horman <nhorman@...driver.com>
To: Eric Dumazet <eric.dumazet@...il.com>
Cc: netdev@...r.kernel.org, "David S. Miller" <davem@...emloft.net>,
Alexey Kuznetsov <kuznet@....inr.ac.ru>,
"Pekka Savola (ipv6)" <pekkas@...core.fi>,
James Morris <jmorris@...ei.org>,
Hideaki YOSHIFUJI <yoshfuji@...ux-ipv6.org>,
Patrick McHardy <kaber@...sh.net>,
Tom Herbert <therbert@...gle.com>
Subject: Re: [PATCH] ipv6: Enable RFS sk_rxhash tracking for ipv6 sockets
On Wed, Apr 06, 2011 at 08:07:33PM +0200, Eric Dumazet wrote:
> Le mercredi 06 avril 2011 à 13:54 -0400, Neil Horman a écrit :
>
> > diff --git a/net/ipv6/udp.c b/net/ipv6/udp.c
> > index d7037c0..aa3e327 100644
> > --- a/net/ipv6/udp.c
> > +++ b/net/ipv6/udp.c
> > @@ -505,6 +505,8 @@ int udpv6_queue_rcv_skb(struct sock * sk, struct sk_buff *skb)
> > int rc;
> > int is_udplite = IS_UDPLITE(sk);
> >
> > + sock_rps_save_rxhash(sk, skb->rxhash);
> > +
> > if (!xfrm6_policy_check(sk, XFRM_POLICY_IN, skb))
> > goto drop;
> >
>
> Problem is every packet received might have a different rxhash if
> multiple senders are active.
>
> This can hurt performance (cache misses on RFS table) on a DNS server
> workload for example.
>
> This is why we used on ipv4 :
>
> if (inet_sk(sk)->inet_daddr)
> sock_rps_save_rxhash(sk, skb->rxhash);
>
Ok, I can absolutely do that, I'll respin shortly. Just to make sure I
understand how to do this, the ipv6 equivalant of inet_daddr is
inet6_sk(sk)->daddr, correct? I ask because the above v4 equivalent is stored in
the sk_common struct, and I want to make sure I'm testing the right data.
Also, do we have a macro already to see if an ipv6 address is all zeros? I'm
not finding one, but I'd hate to re-invent the wheel if I'm just missing it.
>
> Only arm RFS on UDP if socket is bound to a given remote peer.
>
> BTW you forgot Tom Herbert. (I added him in CC)
Thanks, sorry Tom, Just took the output of get_maintainers.pl without checking
all the results.
Neil
>
>
>
>
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists