summaryrefslogtreecommitdiff
path: root/drivers/net/wireless/ath/ath9k/htc_drv_gpio.c
diff options
context:
space:
mode:
authorMiaoqing Pan <miaoqing@codeaurora.org>2016-03-07 02:38:15 (GMT)
committerKalle Valo <kvalo@qca.qualcomm.com>2016-03-11 12:00:02 (GMT)
commitb2d70d4944c1789bc64376ad97a811f37e230c87 (patch)
tree4e2159a4344b6e9d70e86a434b635bf5160d1ed5 /drivers/net/wireless/ath/ath9k/htc_drv_gpio.c
parenta01ab81b09c55025365c1de1345b941a18e05529 (diff)
downloadlinux-b2d70d4944c1789bc64376ad97a811f37e230c87.tar.xz
ath9k: make GPIO API to support both of WMAC and SOC
commit 61b559dea40e ("ath9k: add extra GPIO led support") added ath9k to support access SOC's GPIOs, but implemented in a separated API: ath9k_hw_request_gpio(). So this patch make the APIs more common, to support both of WMAC and SOC GPIOs. The new APIs as below, void ath9k_hw_gpio_request_in(); void ath9k_hw_gpio_request_out(); void ath9k_hw_gpio_free(); NOTE, the BSP of the SOC chips(AR9340, AR9531, AR9550, AR9561) should set the corresponding MUX registers correctly. Signed-off-by: Miaoqing Pan <miaoqing@codeaurora.org> Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/htc_drv_gpio.c')
-rw-r--r--drivers/net/wireless/ath/ath9k/htc_drv_gpio.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath/ath9k/htc_drv_gpio.c b/drivers/net/wireless/ath/ath9k/htc_drv_gpio.c
index 2aabcbd..d9b640a 100644
--- a/drivers/net/wireless/ath/ath9k/htc_drv_gpio.c
+++ b/drivers/net/wireless/ath/ath9k/htc_drv_gpio.c
@@ -259,11 +259,11 @@ void ath9k_deinit_leds(struct ath9k_htc_priv *priv)
void ath9k_configure_leds(struct ath9k_htc_priv *priv)
{
/* Configure gpio 1 for output */
- ath9k_hw_cfg_output(priv->ah, priv->ah->led_pin,
- AR_GPIO_OUTPUT_MUX_AS_OUTPUT);
+ ath9k_hw_gpio_request_out(priv->ah, priv->ah->led_pin,
+ "ath9k-led",
+ AR_GPIO_OUTPUT_MUX_AS_OUTPUT);
/* LED off, active low */
ath9k_hw_set_gpio(priv->ah, priv->ah->led_pin, 1);
-
}
void ath9k_init_leds(struct ath9k_htc_priv *priv)