550-ath9k_add_ar9280_gpio_chip.patch 900 B

123456789101112131415161718192021222324252627
  1. From: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
  2. Date: Thu, 21 Apr 2016 23:00:54 +0200
  3. Subject: [PATCH] mac80211: ath9k: add GPIO support for AR9280 chip
  4. Enable access to GPIO on Atheros wireless chip AR9280.
  5. Support for 9280 is added to existing 9285/9287 subsystem
  6. because these 3 chips differ only in number of GPIO pins.
  7. Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
  8. ---
  9. --- a/drivers/net/wireless/ath/ath9k/gpio.c
  10. +++ b/drivers/net/wireless/ath/ath9k/gpio.c
  11. @@ -88,11 +88,13 @@ static void ath9k_register_gpio_chip(str
  12. struct ath9k_gpio_chip *gc;
  13. u16 ng;
  14. - /* for now only AR9285 and AR9287 are recognized */
  15. + /* supported chips are AR9280, AR9285 and AR9287 */
  16. if (AR_SREV_9287(sc->sc_ah))
  17. ng = AR9287_NUM_GPIO;
  18. else if (AR_SREV_9285(sc->sc_ah))
  19. ng = AR9285_NUM_GPIO;
  20. + else if (AR_SREV_9280(sc->sc_ah))
  21. + ng = AR9280_NUM_GPIO;
  22. else
  23. return;