| 1 | --- a/config.mk |
| 2 | +++ b/config.mk |
| 3 | @@ -132,7 +132,7 @@ CONFIG_COMPAT_MAC80211_RC_DEFAULT=minstr |
| 4 | CONFIG_MAC80211_RC_PID=y |
| 5 | CONFIG_MAC80211_RC_MINSTREL=y |
| 6 | CONFIG_MAC80211_RC_MINSTREL_HT=y |
| 7 | -CONFIG_MAC80211_LEDS=y |
| 8 | +# CONFIG_MAC80211_LEDS=y |
| 9 | |
| 10 | # enable mesh networking too |
| 11 | CONFIG_MAC80211_MESH=y |
| 12 | @@ -240,7 +240,7 @@ CONFIG_B43_PCI_AUTOSELECT=y |
| 13 | ifdef CONFIG_PCMCIA |
| 14 | CONFIG_B43_PCMCIA=y |
| 15 | endif #CONFIG_PCMCIA |
| 16 | -CONFIG_B43_LEDS=y |
| 17 | +# CONFIG_B43_LEDS=y |
| 18 | CONFIG_B43_PHY_LP=y |
| 19 | CONFIG_B43_NPHY=y |
| 20 | # CONFIG_B43_FORCE_PIO=y |
| 21 | @@ -249,7 +249,7 @@ CONFIG_B43_NPHY=y |
| 22 | CONFIG_B43LEGACY=m |
| 23 | CONFIG_B43LEGACY_HWRNG=y |
| 24 | CONFIG_B43LEGACY_PCI_AUTOSELECT=y |
| 25 | -CONFIG_B43LEGACY_LEDS=y |
| 26 | +# CONFIG_B43LEGACY_LEDS=y |
| 27 | # CONFIG_B43LEGACY_DEBUG=y |
| 28 | CONFIG_B43LEGACY_DMA=y |
| 29 | CONFIG_B43LEGACY_PIO=y |
| 30 | @@ -542,7 +542,7 @@ endif |
| 31 | |
| 32 | # p54 |
| 33 | CONFIG_P54_COMMON=m |
| 34 | -CONFIG_P54_LEDS=y |
| 35 | +# CONFIG_P54_LEDS=y |
| 36 | |
| 37 | # Atheros |
| 38 | CONFIG_ATH_COMMON=m |
| 39 | --- a/drivers/net/wireless/ath/ath9k/gpio.c |
| 40 | +++ b/drivers/net/wireless/ath/ath9k/gpio.c |
| 41 | @@ -54,6 +54,7 @@ static void ath_led_blink_work(struct wo |
| 42 | sc->sc_flags |= SC_OP_LED_ON; |
| 43 | } |
| 44 | |
| 45 | +#ifdef CONFIG_LEDS_CLASS |
| 46 | static void ath_led_brightness(struct led_classdev *led_cdev, |
| 47 | enum led_brightness brightness) |
| 48 | { |
| 49 | @@ -90,10 +91,12 @@ static void ath_led_brightness(struct le |
| 50 | break; |
| 51 | } |
| 52 | } |
| 53 | +#endif |
| 54 | |
| 55 | static int ath_register_led(struct ath_softc *sc, struct ath_led *led, |
| 56 | char *trigger) |
| 57 | { |
| 58 | +#ifdef CONFIG_LEDS_CLASS |
| 59 | int ret; |
| 60 | |
| 61 | led->sc = sc; |
| 62 | @@ -108,14 +111,19 @@ static int ath_register_led(struct ath_s |
| 63 | else |
| 64 | led->registered = 1; |
| 65 | return ret; |
| 66 | +#else |
| 67 | + return 0; |
| 68 | +#endif |
| 69 | } |
| 70 | |
| 71 | static void ath_unregister_led(struct ath_led *led) |
| 72 | { |
| 73 | +#ifdef CONFIG_LEDS_CLASS |
| 74 | if (led->registered) { |
| 75 | led_classdev_unregister(&led->led_cdev); |
| 76 | led->registered = 0; |
| 77 | } |
| 78 | +#endif |
| 79 | } |
| 80 | |
| 81 | void ath_deinit_leds(struct ath_softc *sc) |
| 82 | --- a/drivers/net/wireless/ath/ath9k/htc_drv_main.c |
| 83 | +++ b/drivers/net/wireless/ath/ath9k/htc_drv_main.c |
| 84 | @@ -860,6 +860,7 @@ static void ath9k_led_brightness_work(st |
| 85 | } |
| 86 | } |
| 87 | |
| 88 | +#ifdef CONFIG_LEDS_CLASS |
| 89 | static void ath9k_led_brightness(struct led_classdev *led_cdev, |
| 90 | enum led_brightness brightness) |
| 91 | { |
| 92 | @@ -871,6 +872,7 @@ static void ath9k_led_brightness(struct |
| 93 | ieee80211_queue_delayed_work(priv->hw, |
| 94 | &led->brightness_work, 0); |
| 95 | } |
| 96 | +#endif |
| 97 | |
| 98 | static void ath9k_led_stop_brightness(struct ath9k_htc_priv *priv) |
| 99 | { |
| 100 | @@ -883,6 +885,7 @@ static void ath9k_led_stop_brightness(st |
| 101 | static int ath9k_register_led(struct ath9k_htc_priv *priv, struct ath_led *led, |
| 102 | char *trigger) |
| 103 | { |
| 104 | +#ifdef CONFIG_LEDS_CLASS |
| 105 | int ret; |
| 106 | |
| 107 | led->priv = priv; |
| 108 | @@ -900,14 +903,19 @@ static int ath9k_register_led(struct ath |
| 109 | INIT_DELAYED_WORK(&led->brightness_work, ath9k_led_brightness_work); |
| 110 | |
| 111 | return ret; |
| 112 | +#else |
| 113 | + return 0; |
| 114 | +#endif |
| 115 | } |
| 116 | |
| 117 | static void ath9k_unregister_led(struct ath_led *led) |
| 118 | { |
| 119 | +#ifdef CONFIG_LEDS_CLASS |
| 120 | if (led->registered) { |
| 121 | led_classdev_unregister(&led->led_cdev); |
| 122 | led->registered = 0; |
| 123 | } |
| 124 | +#endif |
| 125 | } |
| 126 | |
| 127 | void ath9k_deinit_leds(struct ath9k_htc_priv *priv) |
| 128 | |