diff options
author | David S. Miller <davem@davemloft.net> | 2016-09-23 06:46:57 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-09-23 06:46:57 -0400 |
commit | d6989d4bbe6c4d1c2a76696833a07f044e85694d (patch) | |
tree | 2d9a70d0feee4d4a20568be1b39a961fa0d27d81 /drivers/net/ethernet/netronome | |
parent | 0364a8824c020f12e2d5e9fad963685b58f7574e (diff) | |
parent | b1f2beb87bb034bb209773807994279f90cace78 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Diffstat (limited to 'drivers/net/ethernet/netronome')
-rw-r--r-- | drivers/net/ethernet/netronome/nfp/nfp_net_common.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c index 415691edcaa5..aee3fd2b6538 100644 --- a/drivers/net/ethernet/netronome/nfp/nfp_net_common.c +++ b/drivers/net/ethernet/netronome/nfp/nfp_net_common.c @@ -2094,12 +2094,16 @@ static int nfp_net_netdev_open(struct net_device *netdev) nn->rx_rings = kcalloc(nn->num_rx_rings, sizeof(*nn->rx_rings), GFP_KERNEL); - if (!nn->rx_rings) + if (!nn->rx_rings) { + err = -ENOMEM; goto err_free_lsc; + } nn->tx_rings = kcalloc(nn->num_tx_rings, sizeof(*nn->tx_rings), GFP_KERNEL); - if (!nn->tx_rings) + if (!nn->tx_rings) { + err = -ENOMEM; goto err_free_rx_rings; + } for (r = 0; r < nn->num_r_vecs; r++) { err = nfp_net_prepare_vector(nn, &nn->r_vecs[r], r); |