[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <1421276039.11734.25.camel@edumazet-glaptop2.roam.corp.google.com>
Date: Wed, 14 Jan 2015 14:53:59 -0800
From: Eric Dumazet <eric.dumazet@...il.com>
To: Martin KaFai Lau <kafai@...com>
Cc: netdev@...r.kernel.org, kernel-team@...com
Subject: Re: [PATCH RFC v2 net-next 2/2] ip_tunnel: Remove struct gro_cells
On Tue, 2015-01-13 at 15:42 -0800, Martin KaFai Lau wrote:
> After adding percpu gro_cells, struct gro_cells can be removed.
>
> Signed-off-by: Martin KaFai Lau <kafai@...com>
> ---
> include/net/gro_cells.h | 34 ++++++++++++++++------------------
> include/net/ip_tunnels.h | 2 +-
> net/ipv4/ip_tunnel.c | 11 +++++------
> 3 files changed, 22 insertions(+), 25 deletions(-)
>
> diff --git a/include/net/gro_cells.h b/include/net/gro_cells.h
> index 0f712c0..b1aeea1 100644
> --- a/include/net/gro_cells.h
> +++ b/include/net/gro_cells.h
> @@ -10,21 +10,18 @@ struct gro_cell {
> struct napi_struct napi;
> };
>
> -struct gro_cells {
> - struct gro_cell __percpu *cells;
> -};
> -
This seems a lot of code churn for no runtime difference ?
If we ever want to add an additional 'field', we likely have to revert
this patch.
-static inline void gro_cells_destroy(struct gro_cells *gcells)
+static inline void gro_cell_free_percpu(struct gro_cell __percpu *gcells)
{
int i;
- if (!gcells->cells)
+ if (IS_ERR_OR_NULL(gcells))
return;
For example, I have no idea why this part is needed.
--
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