ath9k: Pass LED polarity to ath_create_gpio_led when initializing the LEDs.

Signed-off-by: Vittorio Gambaletta <openwrt@vittgam.net>

SVN-Revision: 47909
lede-17.01
John Crispin 2015-12-17 09:27:18 +00:00
parent 7de7bd0201
commit 4a4b0b82ec
2 changed files with 2 additions and 2 deletions

View File

@ -159,7 +159,7 @@
+ trigger = ieee80211_get_radio_led_name(sc->hw); + trigger = ieee80211_get_radio_led_name(sc->hw);
- sc->led_registered = true; - sc->led_registered = true;
+ ath_create_gpio_led(sc, sc->sc_ah->led_pin, led_name, trigger, 1); + ath_create_gpio_led(sc, sc->sc_ah->led_pin, led_name, trigger, !sc->sc_ah->config.led_active_high);
} }
void ath_fill_led_pin(struct ath_softc *sc) void ath_fill_led_pin(struct ath_softc *sc)

View File

@ -59,7 +59,7 @@
@@ -120,6 +141,12 @@ void ath_init_leds(struct ath_softc *sc) @@ -120,6 +141,12 @@ void ath_init_leds(struct ath_softc *sc)
trigger = ieee80211_get_radio_led_name(sc->hw); trigger = ieee80211_get_radio_led_name(sc->hw);
ath_create_gpio_led(sc, sc->sc_ah->led_pin, led_name, trigger, 1); ath_create_gpio_led(sc, sc->sc_ah->led_pin, led_name, trigger, !sc->sc_ah->config.led_active_high);
+ +
+ if (!pdata) + if (!pdata)
+ return; + return;