rt2x00: Fix rfkill polling prior to interface start.
authorGertjan van Wingerde <gwingerde@gmail.com>
Fri, 31 Aug 2012 17:22:11 +0000 (19:22 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 5 Sep 2012 18:53:36 +0000 (14:53 -0400)
commita396e10019eaf3809b0219c966865aaafec12630
tree5cb623e3695bb2e504afe121866007d8aa2478d3
parent6ced58a5dbb94dbfbea1b33ca3c56d1e929cd548
rt2x00: Fix rfkill polling prior to interface start.

We need to program the rfkill switch GPIO pin direction to input at
device initialization time, not only when the interface is brought up.
Doing this only when the interface is brought up could lead to rfkill
detecting the switch is turned on erroneously and inability to create
the interface and bringing it up.

Reported-and-tested-by: Andreas Messer <andi@bastelmap.de>
Signed-off-by: Gertjan van Wingerde <gwingerde@gmail.com>
Cc: <stable@vger.kernel.org>
Acked-by: Ivo Van Doorn <ivdoorn@gmail.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/rt2x00/rt2400pci.c
drivers/net/wireless/rt2x00/rt2400pci.h
drivers/net/wireless/rt2x00/rt2500pci.c
drivers/net/wireless/rt2x00/rt2500usb.c
drivers/net/wireless/rt2x00/rt2500usb.h
drivers/net/wireless/rt2x00/rt2800pci.c
drivers/net/wireless/rt2x00/rt2800usb.c
drivers/net/wireless/rt2x00/rt61pci.c
drivers/net/wireless/rt2x00/rt61pci.h
drivers/net/wireless/rt2x00/rt73usb.c
drivers/net/wireless/rt2x00/rt73usb.h