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 ******************************************************************************/ 15 16 17 #ifndef __ODM_INTERFACE_H__ 18 #define __ODM_INTERFACE_H__ 19 20 21 22 /* =========== Constant/Structure/Enum/... Define */ 23 24 /* =========== Macro Define */ 25 26 #define _reg_all(_name) ODM_##_name 27 #define _reg_ic(_name, _ic) ODM_##_name##_ic 28 #define _bit_all(_name) BIT_##_name 29 #define _bit_ic(_name, _ic) BIT_##_name##_ic 30 31 /*=================================== 32 33 #define ODM_REG_DIG_11N 0xC50 34 #define ODM_REG_DIG_11AC 0xDDD 35 36 ODM_REG(DIG, _pDM_Odm) 37 =====================================*/ 38 39 #define _reg_11N(_name) ODM_REG_##_name##_11N 40 #define _bit_11N(_name) ODM_BIT_##_name##_11N 41 42 #define _cat(_name, _ic_type, _func) _func##_11N(_name) 43 44 /* _name: name of register or bit. */ 45 /* Example: "ODM_REG(R_A_AGC_CORE1, pDM_Odm)" */ 46 /* gets "ODM_R_A_AGC_CORE1" or "ODM_R_A_AGC_CORE1_8192C", depends on SupportICType. */ 47 #define ODM_REG(_name, _pDM_Odm) _cat(_name, _pDM_Odm->SupportICType, _reg) 48 #define ODM_BIT(_name, _pDM_Odm) _cat(_name, _pDM_Odm->SupportICType, _bit) 49 50 typedef enum _ODM_H2C_CMD { 51 ODM_H2C_RSSI_REPORT = 0, 52 ODM_H2C_PSD_RESULT = 1, 53 ODM_H2C_PathDiv = 2, 54 ODM_H2C_WIFI_CALIBRATION = 3, 55 ODM_MAX_H2CCMD 56 } ODM_H2C_CMD; 57 58 59 #endif /* __ODM_INTERFACE_H__ */ 60