rtw_android.h 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. /******************************************************************************
  2. *
  3. * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
  4. *
  5. * This program is free software; you can redistribute it and/or modify it
  6. * under the terms of version 2 of the GNU General Public License as
  7. * published by the Free Software Foundation.
  8. *
  9. * This program is distributed in the hope that it will be useful, but WITHOUT
  10. * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
  11. * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
  12. * more details.
  13. *
  14. * You should have received a copy of the GNU General Public License along with
  15. * this program; if not, write to the Free Software Foundation, Inc.,
  16. * 51 Franklin Street, Fifth Floor, Boston, MA 02110, USA
  17. *
  18. *
  19. ******************************************************************************/
  20. #ifndef __RTW_ANDROID_H__
  21. #define __RTW_ANDROID_H__
  22. enum ANDROID_WIFI_CMD {
  23. ANDROID_WIFI_CMD_START,
  24. ANDROID_WIFI_CMD_STOP,
  25. ANDROID_WIFI_CMD_SCAN_ACTIVE,
  26. ANDROID_WIFI_CMD_SCAN_PASSIVE,
  27. ANDROID_WIFI_CMD_RSSI,
  28. ANDROID_WIFI_CMD_LINKSPEED,
  29. ANDROID_WIFI_CMD_RXFILTER_START,
  30. ANDROID_WIFI_CMD_RXFILTER_STOP,
  31. ANDROID_WIFI_CMD_RXFILTER_ADD,
  32. ANDROID_WIFI_CMD_RXFILTER_REMOVE,
  33. ANDROID_WIFI_CMD_BTCOEXSCAN_START,
  34. ANDROID_WIFI_CMD_BTCOEXSCAN_STOP,
  35. ANDROID_WIFI_CMD_BTCOEXMODE,
  36. ANDROID_WIFI_CMD_SETSUSPENDOPT,
  37. ANDROID_WIFI_CMD_P2P_DEV_ADDR,
  38. ANDROID_WIFI_CMD_SETFWPATH,
  39. ANDROID_WIFI_CMD_SETBAND,
  40. ANDROID_WIFI_CMD_GETBAND,
  41. ANDROID_WIFI_CMD_COUNTRY,
  42. ANDROID_WIFI_CMD_P2P_SET_NOA,
  43. ANDROID_WIFI_CMD_P2P_GET_NOA,
  44. ANDROID_WIFI_CMD_P2P_SET_PS,
  45. ANDROID_WIFI_CMD_SET_AP_WPS_P2P_IE,
  46. #ifdef PNO_SUPPORT
  47. ANDROID_WIFI_CMD_PNOSSIDCLR_SET,
  48. ANDROID_WIFI_CMD_PNOSETUP_SET,
  49. ANDROID_WIFI_CMD_PNOENABLE_SET,
  50. ANDROID_WIFI_CMD_PNODEBUG_SET,
  51. #endif
  52. ANDROID_WIFI_CMD_MACADDR,
  53. ANDROID_WIFI_CMD_BLOCK,
  54. ANDROID_WIFI_CMD_WFD_ENABLE,
  55. ANDROID_WIFI_CMD_WFD_DISABLE,
  56. ANDROID_WIFI_CMD_WFD_SET_TCPPORT,
  57. ANDROID_WIFI_CMD_WFD_SET_MAX_TPUT,
  58. ANDROID_WIFI_CMD_WFD_SET_DEVTYPE,
  59. ANDROID_WIFI_CMD_MAX
  60. };
  61. int rtw_android_cmdstr_to_num(char *cmdstr);
  62. int rtw_android_priv_cmd(struct net_device *net, struct ifreq *ifr, int cmd);
  63. #if defined(RTW_ENABLE_WIFI_CONTROL_FUNC)
  64. int rtw_android_wifictrl_func_add(void);
  65. void rtw_android_wifictrl_func_del(void);
  66. void* wl_android_prealloc(int section, unsigned long size);
  67. int wifi_get_irq_number(unsigned long *irq_flags_ptr);
  68. int wifi_set_power(int on, unsigned long msec);
  69. int wifi_get_mac_addr(unsigned char *buf);
  70. void *wifi_get_country_code(char *ccode);
  71. #else
  72. static int rtw_android_wifictrl_func_add(void) { return 0; }
  73. static void rtw_android_wifictrl_func_del(void) {}
  74. #endif /* defined(RTW_ENABLE_WIFI_CONTROL_FUNC) */
  75. #endif //__RTW_ANDROID_H__