diff options
author | Ben Hutchings <bhutchings@solarflare.com> | 2010-09-10 08:41:57 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2010-09-10 21:27:33 +0200 |
commit | 8313aca38b3937947fffebca6e34bac8e24300c8 (patch) | |
tree | 725830070d3509459e90b106b668047c25ed880a /drivers/net/sfc/falcon.c | |
parent | sfc: Refactor channel and queue lookup and iteration (diff) | |
download | linux-8313aca38b3937947fffebca6e34bac8e24300c8.tar.xz linux-8313aca38b3937947fffebca6e34bac8e24300c8.zip |
sfc: Allocate each channel separately, along with its RX and TX queues
This will allow for reallocation of channel structures and rings.
Change module parameter separate_tx_channels to be read-only, since we
now require its value to be constant.
Signed-off-by: Ben Hutchings <bhutchings@solarflare.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/sfc/falcon.c')
-rw-r--r-- | drivers/net/sfc/falcon.c | 14 |
1 files changed, 4 insertions, 10 deletions
diff --git a/drivers/net/sfc/falcon.c b/drivers/net/sfc/falcon.c index 4f9d33f3cca1..b4d8efe67772 100644 --- a/drivers/net/sfc/falcon.c +++ b/drivers/net/sfc/falcon.c @@ -159,7 +159,6 @@ irqreturn_t falcon_legacy_interrupt_a1(int irq, void *dev_id) { struct efx_nic *efx = dev_id; efx_oword_t *int_ker = efx->irq_status.addr; - struct efx_channel *channel; int syserr; int queues; @@ -194,15 +193,10 @@ irqreturn_t falcon_legacy_interrupt_a1(int irq, void *dev_id) wmb(); /* Ensure the vector is cleared before interrupt ack */ falcon_irq_ack_a1(efx); - /* Schedule processing of any interrupting queues */ - channel = &efx->channel[0]; - while (queues) { - if (queues & 0x01) - efx_schedule_channel(channel); - channel++; - queues >>= 1; - } - + if (queues & 1) + efx_schedule_channel(efx_get_channel(efx, 0)); + if (queues & 2) + efx_schedule_channel(efx_get_channel(efx, 1)); return IRQ_HANDLED; } /************************************************************************** |