diff options
author | Alexander Duyck <alexander.h.duyck@redhat.com> | 2014-12-09 22:40:56 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2014-12-10 13:31:57 -0500 |
commit | 67fd893ee07db94bcef6c7537f8569b49ff124d4 (patch) | |
tree | 4d0972f930eac9c337238b2cf1d875d911730917 /drivers/net/ethernet/intel/fm10k/fm10k_main.c | |
parent | fd11a83dd3630ec6a60f8a702446532c5c7e1991 (diff) |
ethernet/intel: Use napi_alloc_skb
This change replaces calls to netdev_alloc_skb_ip_align with
napi_alloc_skb. The advantage of napi_alloc_skb is currently the fact that
the page allocation doesn't make use of any irq disable calls.
There are few spots where I couldn't replace the calls as the buffer
allocation routine is called as a part of init which is outside of the
softirq context.
Cc: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: Alexander Duyck <alexander.h.duyck@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/intel/fm10k/fm10k_main.c')
-rw-r--r-- | drivers/net/ethernet/intel/fm10k/fm10k_main.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/net/ethernet/intel/fm10k/fm10k_main.c b/drivers/net/ethernet/intel/fm10k/fm10k_main.c index 91516aed373e..ee1ecb146df7 100644 --- a/drivers/net/ethernet/intel/fm10k/fm10k_main.c +++ b/drivers/net/ethernet/intel/fm10k/fm10k_main.c | |||
@@ -308,8 +308,8 @@ static struct sk_buff *fm10k_fetch_rx_buffer(struct fm10k_ring *rx_ring, | |||
308 | #endif | 308 | #endif |
309 | 309 | ||
310 | /* allocate a skb to store the frags */ | 310 | /* allocate a skb to store the frags */ |
311 | skb = netdev_alloc_skb_ip_align(rx_ring->netdev, | 311 | skb = napi_alloc_skb(&rx_ring->q_vector->napi, |
312 | FM10K_RX_HDR_LEN); | 312 | FM10K_RX_HDR_LEN); |
313 | if (unlikely(!skb)) { | 313 | if (unlikely(!skb)) { |
314 | rx_ring->rx_stats.alloc_failed++; | 314 | rx_ring->rx_stats.alloc_failed++; |
315 | return NULL; | 315 | return NULL; |