diff options
author | Arnd Bergmann <[email protected]> | 2019-12-16 14:18:42 +0100 |
---|---|---|
committer | Kalle Valo <[email protected]> | 2019-12-18 20:24:57 +0200 |
commit | d68f4e43a46ff1f772ff73085f96d44eb4163e9d (patch) | |
tree | 689a162820cc97de9f2027832c697ef518c922be /drivers/fpga/fpga-mgr.c | |
parent | ddd9b5e3e765d8ed5a35786a6cb00111713fe161 (diff) |
mt76: fix LED link time failure
The mt76_led_cleanup() function is called unconditionally, which
leads to a link error when CONFIG_LEDS is a loadable module or
disabled but mt76 is built-in:
drivers/net/wireless/mediatek/mt76/mac80211.o: In function `mt76_unregister_device':
mac80211.c:(.text+0x2ac): undefined reference to `led_classdev_unregister'
Use the same trick that is guarding the registration, using an
IS_ENABLED() check for the CONFIG_MT76_LEDS symbol that indicates
whether LEDs can be used or not.
Fixes: 36f7e2b2bb1d ("mt76: do not use devm API for led classdev")
Signed-off-by: Arnd Bergmann <[email protected]>
Acked-by: Felix Fietkau <[email protected]>
Signed-off-by: Kalle Valo <[email protected]>
Diffstat (limited to 'drivers/fpga/fpga-mgr.c')
0 files changed, 0 insertions, 0 deletions