diff options
author | andrey@cozybit.com <andrey@cozybit.com> | 2009-05-20 02:20:13 +0200 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-05-22 20:06:00 +0200 |
commit | ea2d06395b6de717a5e0c4b6e55f3047cae2131f (patch) | |
tree | 7e595306cd1d102eb7231f0784cacdf7cb040daa /drivers | |
parent | mac80211: fix probe response wait timing (diff) | |
download | linux-ea2d06395b6de717a5e0c4b6e55f3047cae2131f.tar.xz linux-ea2d06395b6de717a5e0c4b6e55f3047cae2131f.zip |
libertas: fix GSPI card event handling
The GPSI interface driver does not re-enable the Card Event Interrupt, which
causes problems after a card event (for example: link-loss) comes in. This
can lead, for example, to the card failing to re-associate. This patch
ensures that we re-enable the Card Event Interrupt when we handle card events.
Signed-off-by: Andrey Yurovsky <andrey@cozybit.com>
Acked-by: Dan Williams <dcbw@redhat.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/net/wireless/libertas/if_spi.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/drivers/net/wireless/libertas/if_spi.c b/drivers/net/wireless/libertas/if_spi.c index dccd01fd1f10..5fa55fe1f860 100644 --- a/drivers/net/wireless/libertas/if_spi.c +++ b/drivers/net/wireless/libertas/if_spi.c @@ -814,6 +814,13 @@ static void if_spi_e2h(struct if_spi_card *card) if (err) goto out; + /* re-enable the card event interrupt */ + spu_write_u16(card, IF_SPI_HOST_INT_STATUS_REG, + ~IF_SPI_HICU_CARD_EVENT); + + /* generate a card interrupt */ + spu_write_u16(card, IF_SPI_CARD_INT_CAUSE_REG, IF_SPI_CIC_HOST_EVENT); + spin_lock_irqsave(&priv->driver_lock, flags); lbs_queue_event(priv, cause & 0xff); spin_unlock_irqrestore(&priv->driver_lock, flags); |