diff options
author | Daniel Pieczko <dpieczko@solarflare.com> | 2013-02-13 05:54:41 -0500 |
---|---|---|
committer | Ben Hutchings <bhutchings@solarflare.com> | 2013-03-07 15:22:15 -0500 |
commit | 1648a23fa159e5c433aac06dc5e0d9db36146016 (patch) | |
tree | c60a40e25d368f34e73b6abffa9a62a890dc9bbf /drivers/net/ethernet/sfc/net_driver.h | |
parent | 179ea7f039f68ae4247a340bfb59fd861e7def12 (diff) |
sfc: allocate more RX buffers per page
Allocating 2 buffers per page is insanely inefficient when MTU is 1500
and PAGE_SIZE is 64K (as it usually is on POWER). Allocate as many as
we can fit, and choose the refill batch size at run-time so that we
still always use a whole page at once.
[bwh: Fix loop condition to allow for compound pages; rebase]
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Diffstat (limited to 'drivers/net/ethernet/sfc/net_driver.h')
-rw-r--r-- | drivers/net/ethernet/sfc/net_driver.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/ethernet/sfc/net_driver.h b/drivers/net/ethernet/sfc/net_driver.h index e22e75c8f635..9bd433a095c5 100644 --- a/drivers/net/ethernet/sfc/net_driver.h +++ b/drivers/net/ethernet/sfc/net_driver.h | |||
@@ -825,7 +825,9 @@ struct efx_nic { | |||
825 | unsigned int rx_dma_len; | 825 | unsigned int rx_dma_len; |
826 | unsigned int rx_buffer_order; | 826 | unsigned int rx_buffer_order; |
827 | unsigned int rx_buffer_truesize; | 827 | unsigned int rx_buffer_truesize; |
828 | unsigned int rx_page_buf_step; | ||
828 | unsigned int rx_bufs_per_page; | 829 | unsigned int rx_bufs_per_page; |
830 | unsigned int rx_pages_per_batch; | ||
829 | u8 rx_hash_key[40]; | 831 | u8 rx_hash_key[40]; |
830 | u32 rx_indir_table[128]; | 832 | u32 rx_indir_table[128]; |
831 | bool rx_scatter; | 833 | bool rx_scatter; |