Subject: Re: [PATCH net-next 2/2] net/mlx4_en: Copy exact header to SKB linear part

From: Sergei Shtylyov <[email-masked]>
Date: Mon, 28 Jul 2014 14:56:46 +0400

Hello.

On 07/28/2014 02:14 PM, Amir Vadai wrote:

> Based on patch from Eric Dumazet
> When copy received packet header to the linear section of the SKB,

    s/copy/copying/.

> Copy the exact header (best effort) and not the max possible header,

    s/Copy/copy/.

> using the new network helper function __net_get_headlen.

    Not eth_frame_headlen()?

> It will return the size of the header up to the latest known header.

> Signed-off-by: Ido Shamay <[email-masked]>
> Signed-off-by: Amir Vadai <[email-masked]>
> ---
>   drivers/net/ethernet/mellanox/mlx4/en_rx.c | 13 ++++++++-----
>   1 file changed, 8 insertions(+), 5 deletions(-)

> diff --git a/drivers/net/ethernet/mellanox/mlx4/en_rx.c b/drivers/net/ethernet/mellanox/mlx4/en_rx.c
> index 9c909d2..c4471f1 100644
> --- a/drivers/net/ethernet/mellanox/mlx4/en_rx.c
> +++ b/drivers/net/ethernet/mellanox/mlx4/en_rx.c
> @@ -588,6 +588,7 @@ static struct sk_buff *mlx4_en_rx_skb(struct mlx4_en_priv *priv,
>   		skb_copy_to_linear_data(skb, va, length);
>   		skb->tail += length;
>   	} else {
> +		unsigned int hlen;

    Empty line needed here.

>   		/* Move relevant fragments to skb */
>   		used_frags = mlx4_en_complete_rx_desc(priv, rx_desc, frags,
>   							skb, length);

WBR, Sergei