Commit 3a990f39 authored by Aaro Koskinen's avatar Aaro Koskinen Committed by Greg Kroah-Hartman

staging: octeon-ethernet: eliminate USE_SKBUFFS_IN_HW define

We always try to use skbuffs for packet buffers, so eliminate
a redundant define.
Signed-off-by: default avatarAaro Koskinen <aaro.koskinen@iki.fi>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent 6646baf7
......@@ -27,10 +27,6 @@
/*
* A few defines are used to control the operation of this driver:
* USE_SKBUFFS_IN_HW
* Tells the driver to populate the packet buffers with kernel skbuffs.
* This allows the driver to receive packets without copying them. It also
* means that 32bit userspace can't access the packet buffers.
* USE_ASYNC_IOBDMA
* Use asynchronous IO access to hardware. This uses Octeon's asynchronous
* IOBDMAs to issue IO accesses without stalling. Set this to zero
......@@ -50,7 +46,6 @@
#define OCTEON_ETHERNET_VERSION "1.9"
#define USE_SKBUFFS_IN_HW 1
#ifdef CONFIG_NETFILTER
#define REUSE_SKBUFFS_WITHOUT_FREE 0
#else
......
......@@ -160,7 +160,7 @@ int cvm_oct_mem_fill_fpa(int pool, int size, int elements)
{
int freed;
if (USE_SKBUFFS_IN_HW && pool == CVMX_FPA_PACKET_POOL)
if (pool == CVMX_FPA_PACKET_POOL)
freed = cvm_oct_fill_hw_skbuff(pool, size, elements);
else
freed = cvm_oct_fill_hw_memory(pool, size, elements);
......@@ -169,7 +169,7 @@ int cvm_oct_mem_fill_fpa(int pool, int size, int elements)
void cvm_oct_mem_empty_fpa(int pool, int size, int elements)
{
if (USE_SKBUFFS_IN_HW && pool == CVMX_FPA_PACKET_POOL)
if (pool == CVMX_FPA_PACKET_POOL)
cvm_oct_free_hw_skbuff(pool, size, elements);
else
cvm_oct_free_hw_memory(pool, size, elements);
......
......@@ -230,7 +230,7 @@ static int cvm_oct_napi_poll(struct napi_struct *napi, int budget)
}
rx_count++;
skb_in_hw = USE_SKBUFFS_IN_HW && work->word2.s.bufs == 1;
skb_in_hw = work->word2.s.bufs == 1;
if (likely(skb_in_hw)) {
skb = *pskb;
prefetch(&skb->head);
......@@ -391,7 +391,7 @@ static int cvm_oct_napi_poll(struct napi_struct *napi, int budget)
* Check to see if the skbuff and work share the same
* packet buffer.
*/
if (USE_SKBUFFS_IN_HW && likely(packet_not_copied)) {
if (likely(packet_not_copied)) {
/*
* This buffer needs to be replaced, increment
* the number of buffers we need to free by
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment