600-08-rt2x00-rt2800soc-fix-rt2800soc_disable_radio-for-RT3.patch 1021 B

123456789101112131415161718192021222324252627282930
  1. From 6c2d32478159fffff0b85abb6817a21bb2338231 Mon Sep 17 00:00:00 2001
  2. From: Gabor Juhos <juhosg@openwrt.org>
  3. Date: Sun, 24 Mar 2013 19:26:27 +0100
  4. Subject: [PATCH] rt2x00: rt2800soc: fix rt2800soc_disable_radio for RT3883
  5. Signed-off-by: Gabor Juhos <juhosg@openwrt.org>
  6. ---
  7. drivers/net/wireless/ralink/rt2x00/rt2800soc.c | 9 ++++++++-
  8. 1 file changed, 8 insertions(+), 1 deletion(-)
  9. --- a/drivers/net/wireless/ralink/rt2x00/rt2800soc.c
  10. +++ b/drivers/net/wireless/ralink/rt2x00/rt2800soc.c
  11. @@ -51,9 +51,16 @@ static bool rt2800soc_hwcrypt_disabled(s
  12. static void rt2800soc_disable_radio(struct rt2x00_dev *rt2x00dev)
  13. {
  14. + u32 reg;
  15. +
  16. rt2800_disable_radio(rt2x00dev);
  17. rt2x00mmio_register_write(rt2x00dev, PWR_PIN_CFG, 0);
  18. - rt2x00mmio_register_write(rt2x00dev, TX_PIN_CFG, 0);
  19. +
  20. + reg = 0;
  21. + if (rt2x00_rt(rt2x00dev, RT3883))
  22. + rt2x00_set_field32(&reg, TX_PIN_CFG_RFTR_EN, 1);
  23. +
  24. + rt2x00mmio_register_write(rt2x00dev, TX_PIN_CFG, reg);
  25. }
  26. static int rt2800soc_set_device_state(struct rt2x00_dev *rt2x00dev,