Subject: Re: [net-next 01/15] i40e: fix null dereference

From: Sergei Shtylyov <[email-masked]>
Date: Thu, 12 Dec 2013 18:30:16 +0400

Hello.

On 12-12-2013 16:40, Jeff Kirsher wrote:

> From: Jesse Brandeburg <[email-masked]>

> If the vsi->tx_rings structure is NULL we don't want to panic.

> Change-Id: Ic694f043701738c434e8ebe0caf0673f4410dc10
> Signed-off-by: Jesse Brandeburg <[email-masked]>
> Tested-by: Kavindya Deegala <[email-masked]>
> Signed-off-by: Jeff Kirsher <[email-masked]>
> ---
>   drivers/net/ethernet/intel/i40e/i40e_main.c | 3 +++
>   1 file changed, 3 insertions(+)

> diff --git a/drivers/net/ethernet/intel/i40e/i40e_main.c b/drivers/net/ethernet/intel/i40e/i40e_main.c
> index a6291e2..1ef311a 100644
> --- a/drivers/net/ethernet/intel/i40e/i40e_main.c
> +++ b/drivers/net/ethernet/intel/i40e/i40e_main.c
> @@ -354,6 +354,9 @@ static struct rtnl_link_stats64 *i40e_get_netdev_stats_struct(
>   	struct rtnl_link_stats64 *vsi_stats = i40e_get_vsi_stats_struct(vsi);
>   	int i;
>
> +	if (!vsi->tx_rings)
> +		return stats;
> +

    This looks like a fix, so should go to net.git, not net-next.git?

WBR, Sergei