[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CA+mtBx-zKBV+gd-1gNJTV4SBZtcQUpoYbxvOKn0eeOO36hoMpg@mail.gmail.com>
Date: Wed, 13 Jul 2011 17:44:44 -0700
From: Tom Herbert <therbert@...gle.com>
To: Michał Mirosław <mirq-linux@...e.qmqm.pl>
Cc: netdev@...r.kernel.org
Subject: Re: [PATCH 05/10] net: Disable NOCACHE_COPY by default
On Wed, Jul 13, 2011 at 5:10 PM, Michał Mirosław
<mirq-linux@...e.qmqm.pl> wrote:
>
> Disable NOCACHE_COPY by default as there's no reliable way to tell
> in advance what device(s) will take the packet. Also, allow the
> setting to be inherited by VLAN devices.
>
What problem is this addressing? Is this just to get rid of the
NETIF_NO_CSUM bit, or is there an issue with nocachecopy being enabled
by default?
Tom
> This is the last use of NETIF_F_NO_CSUM.
>
> Signed-off-by: Michał Mirosław <mirq-linux@...e.qmqm.pl>
> ---
> net/core/dev.c | 11 +++++------
> 1 files changed, 5 insertions(+), 6 deletions(-)
>
> diff --git a/net/core/dev.c b/net/core/dev.c
> index e57be02..7b9e2f4 100644
> --- a/net/core/dev.c
> +++ b/net/core/dev.c
> @@ -5480,13 +5480,12 @@ int register_netdevice(struct net_device *dev)
> dev->features |= NETIF_F_SOFT_FEATURES;
> dev->wanted_features = dev->features & dev->hw_features;
>
> - /* Turn on no cache copy if HW is doing checksum */
> + /* Allow changing no-cache copy but disable it by default
> + * as there's no reliable way to tell what device(s) will take
> + * the packet. Allow the setting to be inherited to VLANs.
> + */
> dev->hw_features |= NETIF_F_NOCACHE_COPY;
> - if ((dev->features & NETIF_F_ALL_CSUM) &&
> - !(dev->features & NETIF_F_NO_CSUM)) {
> - dev->wanted_features |= NETIF_F_NOCACHE_COPY;
> - dev->features |= NETIF_F_NOCACHE_COPY;
> - }
> + dev->vlan_features |= NETIF_F_NOCACHE_COPY;
>
> /* Make NETIF_F_HIGHDMA inheritable to VLAN devices.
> */
> --
> 1.7.5.4
>
--
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