diff options
author | Steve Hodgson <shodgson@solarflare.com> | 2010-06-01 07:33:17 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-06-02 05:21:08 -0400 |
commit | f7d6f379db61233a1740cb2c6818b9c97531771f (patch) | |
tree | bf9af05c24d928bf6a66699d084912f68faddf05 /drivers/net/sfc/net_driver.h | |
parent | 90d683afd1395016775c8d90508614f8d3000b81 (diff) |
sfc: Support only two rx buffers per page
- Pull the loop handling into efx_init_rx_buffers_(skb|page)
- Remove rx_queue->buf_page, and associated clean up code
- Remove unmap_addr, since unmap_addr is trivially calculable
This will allow us to recycle discarded buffers directly
from efx_rx_packet(), since will never be in the middle of
splitting a page.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/sfc/net_driver.h')
-rw-r--r-- | drivers/net/sfc/net_driver.h | 10 |
1 files changed, 0 insertions, 10 deletions
diff --git a/drivers/net/sfc/net_driver.h b/drivers/net/sfc/net_driver.h index 45398039dee6..59c8ecc39aee 100644 --- a/drivers/net/sfc/net_driver.h +++ b/drivers/net/sfc/net_driver.h | |||
@@ -222,7 +222,6 @@ struct efx_tx_queue { | |||
222 | * If both this and skb are %NULL, the buffer slot is currently free. | 222 | * If both this and skb are %NULL, the buffer slot is currently free. |
223 | * @data: Pointer to ethernet header | 223 | * @data: Pointer to ethernet header |
224 | * @len: Buffer length, in bytes. | 224 | * @len: Buffer length, in bytes. |
225 | * @unmap_addr: DMA address to unmap | ||
226 | */ | 225 | */ |
227 | struct efx_rx_buffer { | 226 | struct efx_rx_buffer { |
228 | dma_addr_t dma_addr; | 227 | dma_addr_t dma_addr; |
@@ -230,7 +229,6 @@ struct efx_rx_buffer { | |||
230 | struct page *page; | 229 | struct page *page; |
231 | char *data; | 230 | char *data; |
232 | unsigned int len; | 231 | unsigned int len; |
233 | dma_addr_t unmap_addr; | ||
234 | }; | 232 | }; |
235 | 233 | ||
236 | /** | 234 | /** |
@@ -257,11 +255,6 @@ struct efx_rx_buffer { | |||
257 | * @alloc_page_count: RX allocation strategy counter. | 255 | * @alloc_page_count: RX allocation strategy counter. |
258 | * @alloc_skb_count: RX allocation strategy counter. | 256 | * @alloc_skb_count: RX allocation strategy counter. |
259 | * @slow_fill: Timer used to defer efx_nic_generate_fill_event(). | 257 | * @slow_fill: Timer used to defer efx_nic_generate_fill_event(). |
260 | * @buf_page: Page for next RX buffer. | ||
261 | * We can use a single page for multiple RX buffers. This tracks | ||
262 | * the remaining space in the allocation. | ||
263 | * @buf_dma_addr: Page's DMA address. | ||
264 | * @buf_data: Page's host address. | ||
265 | * @flushed: Use when handling queue flushing | 258 | * @flushed: Use when handling queue flushing |
266 | */ | 259 | */ |
267 | struct efx_rx_queue { | 260 | struct efx_rx_queue { |
@@ -284,9 +277,6 @@ struct efx_rx_queue { | |||
284 | struct timer_list slow_fill; | 277 | struct timer_list slow_fill; |
285 | unsigned int slow_fill_count; | 278 | unsigned int slow_fill_count; |
286 | 279 | ||
287 | struct page *buf_page; | ||
288 | dma_addr_t buf_dma_addr; | ||
289 | char *buf_data; | ||
290 | enum efx_flush_state flushed; | 280 | enum efx_flush_state flushed; |
291 | }; | 281 | }; |
292 | 282 | ||