aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/sfc/selftest.c
diff options
context:
space:
mode:
authorBen Hutchings <bhutchings@solarflare.com>2009-10-23 04:30:58 -0400
committerDavid S. Miller <davem@davemloft.net>2009-10-24 07:27:05 -0400
commit3ffeabdd2bc62e0ebcb1a51a5d959a86a7a915fc (patch)
treea3b17cc4b0f8300aca46d67a6f9a362f6b052975 /drivers/net/sfc/selftest.c
parent12d00cadcc45382fc127712aa35bd0c96cbf81d9 (diff)
sfc: Eliminate indirect lookups of queue size constants
Move size and mask definitions into efx.h; calculate page orders in falcon.c. Signed-off-by: Ben Hutchings <bhutchings@solarflare.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/sfc/selftest.c')
-rw-r--r--drivers/net/sfc/selftest.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/net/sfc/selftest.c b/drivers/net/sfc/selftest.c
index e5c4c9cd4520..7a9386f97c42 100644
--- a/drivers/net/sfc/selftest.c
+++ b/drivers/net/sfc/selftest.c
@@ -526,7 +526,7 @@ efx_test_loopback(struct efx_tx_queue *tx_queue,
526 526
527 for (i = 0; i < 3; i++) { 527 for (i = 0; i < 3; i++) {
528 /* Determine how many packets to send */ 528 /* Determine how many packets to send */
529 state->packet_count = (efx->type->txd_ring_mask + 1) / 3; 529 state->packet_count = EFX_TXQ_SIZE / 3;
530 state->packet_count = min(1 << (i << 2), state->packet_count); 530 state->packet_count = min(1 << (i << 2), state->packet_count);
531 state->skbs = kzalloc(sizeof(state->skbs[0]) * 531 state->skbs = kzalloc(sizeof(state->skbs[0]) *
532 state->packet_count, GFP_KERNEL); 532 state->packet_count, GFP_KERNEL);