Netdev List
 help / color / mirror / Atom feed
From: Eric Dumazet <eric.dumazet@gmail.com>
To: Neil Horman <nhorman@tuxdriver.com>
Cc: netdev@vger.kernel.org, "David S. Miller" <davem@davemloft.net>,
	Alexey Kuznetsov <kuznet@ms2.inr.ac.ru>,
	"Pekka Savola (ipv6)" <pekkas@netcore.fi>,
	James Morris <jmorris@namei.org>,
	Hideaki YOSHIFUJI <yoshfuji@linux-ipv6.org>,
	Patrick McHardy <kaber@trash.net>,
	Tom Herbert <therbert@google.com>
Subject: Re: [PATCH] ipv6: Enable RFS sk_rxhash tracking for ipv6 sockets
Date: Wed, 06 Apr 2011 20:07:33 +0200	[thread overview]
Message-ID: <1302113253.3209.126.camel@edumazet-laptop> (raw)
In-Reply-To: <1302112465-6842-1-git-send-email-nhorman@tuxdriver.com>

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);


Only arm RFS on UDP if socket is bound to a given remote peer.

BTW you forgot Tom Herbert. (I added him in CC)




  reply	other threads:[~2011-04-06 18:07 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-06 17:54 [PATCH] ipv6: Enable RFS sk_rxhash tracking for ipv6 sockets Neil Horman
2011-04-06 18:07 ` Eric Dumazet [this message]
2011-04-06 18:17   ` David Miller
2011-04-06 18:23     ` Eric Dumazet
2011-04-06 18:27       ` David Miller
2011-04-06 18:37         ` Eric Dumazet
2011-04-06 18:40           ` Neil Horman
2011-04-06 18:33       ` Neil Horman
2011-04-06 18:38         ` Eric Dumazet
2011-04-06 18:39   ` Neil Horman
2011-04-06 18:53     ` Brian Haley
2011-04-06 19:19       ` Neil Horman
2011-04-06 19:37 ` [PATCH] ipv6: Enable RFS sk_rxhash tracking for ipv6 sockets (v2) Neil Horman
2011-04-06 20:07   ` David Miller
2011-04-06 20:42     ` Neil Horman

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1302113253.3209.126.camel@edumazet-laptop \
    --to=eric.dumazet@gmail.com \
    --cc=davem@davemloft.net \
    --cc=jmorris@namei.org \
    --cc=kaber@trash.net \
    --cc=kuznet@ms2.inr.ac.ru \
    --cc=netdev@vger.kernel.org \
    --cc=nhorman@tuxdriver.com \
    --cc=pekkas@netcore.fi \
    --cc=therbert@google.com \
    --cc=yoshfuji@linux-ipv6.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox