radio_2059.h 1.4 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162
  1. /* SPDX-License-Identifier: GPL-2.0 */
  2. #ifndef B43_RADIO_2059_H_
  3. #define B43_RADIO_2059_H_
  4. #include <linux/types.h>
  5. #include "phy_ht.h"
  6. #define R2059_C1 0x000
  7. #define R2059_C2 0x400
  8. #define R2059_C3 0x800
  9. #define R2059_ALL 0xC00
  10. #define R2059_RCAL_CONFIG 0x004
  11. #define R2059_RFPLL_MASTER 0x011
  12. #define R2059_RFPLL_MISC_EN 0x02b
  13. #define R2059_RFPLL_MISC_CAL_RESETN 0x02e
  14. #define R2059_XTAL_CONFIG2 0x0c0
  15. #define R2059_RCCAL_START_R1_Q1_P1 0x13c
  16. #define R2059_RCCAL_X1 0x13d
  17. #define R2059_RCCAL_TRC0 0x13e
  18. #define R2059_RCCAL_DONE_OSCCAP 0x140
  19. #define R2059_RCAL_STATUS 0x145
  20. #define R2059_RCCAL_MASTER 0x17f
  21. /* Values for various registers uploaded on channel switching */
  22. struct b43_phy_ht_channeltab_e_radio2059 {
  23. /* The channel frequency in MHz */
  24. u16 freq;
  25. /* Values for radio registers */
  26. u8 radio_syn16;
  27. u8 radio_syn17;
  28. u8 radio_syn22;
  29. u8 radio_syn25;
  30. u8 radio_syn27;
  31. u8 radio_syn28;
  32. u8 radio_syn29;
  33. u8 radio_syn2c;
  34. u8 radio_syn2d;
  35. u8 radio_syn37;
  36. u8 radio_syn41;
  37. u8 radio_syn43;
  38. u8 radio_syn47;
  39. u8 radio_rxtx4a;
  40. u8 radio_rxtx58;
  41. u8 radio_rxtx5a;
  42. u8 radio_rxtx6a;
  43. u8 radio_rxtx6d;
  44. u8 radio_rxtx6e;
  45. u8 radio_rxtx92;
  46. u8 radio_rxtx98;
  47. /* Values for PHY registers */
  48. struct b43_phy_ht_channeltab_e_phy phy_regs;
  49. };
  50. void r2059_upload_inittabs(struct b43_wldev *dev);
  51. const struct b43_phy_ht_channeltab_e_radio2059
  52. *b43_phy_ht_get_channeltab_e_r2059(struct b43_wldev *dev, u16 freq);
  53. #endif /* B43_RADIO_2059_H_ */