]> git.baikalelectronics.ru Git - kernel.git/commit
mwifiex: fix IRQ enable/disable
authorDaniel Drake <dsd@laptop.org>
Sat, 13 Jul 2013 14:57:10 +0000 (10:57 -0400)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 22 Jul 2013 20:04:07 +0000 (16:04 -0400)
commit14f4e474e1d862bd701d7195774ff688bc87efd2
treeaf56e90fe7fcc21b1c5b15041f088fccabf1a3f5
parentcf30892a94383840ada9a9180bde075dc3711c32
mwifiex: fix IRQ enable/disable

During tear down (e.g. mwifiex_sdio_remove during system suspend),
mwifiex left IRQs enabled for a significant period of time when it was
unable to handle them correctly. This caused interrupt storms and
interfered with the bluetooth interface on the same SDIO card.

Solve this by disabling interrupts at the point when they can no longer
be handled correctly, which is at the start of mwifiex_remove_card().

For cleanliness, we now enable interrupts in the mwifiex_add_card() path,
to be symmetrical with the disabling of interrupts. We also couple the
registration of the sdio IRQ handler with the actual enable/disable of
interrupts at the hardware level.

I also removed a write to this register in mwifiex_init_sdio which seemed
pointless and won't cause any ill effects now that we only register
the SDIO IRQ handler when we are ready to accept interrupts.

Includes some corrections from Amitkumar Karwar.

Signed-off-by: Daniel Drake <dsd@laptop.org>
Acked-by: Bing Zhao <bzhao@marvell.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/mwifiex/init.c
drivers/net/wireless/mwifiex/main.c
drivers/net/wireless/mwifiex/main.h
drivers/net/wireless/mwifiex/sdio.c
drivers/net/wireless/mwifiex/sdio.h