1 /******************************************************************************
3 * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
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.
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
14 ******************************************************************************/
17 #ifndef __ODM_INTERFACE_H__
18 #define __ODM_INTERFACE_H__
21 /* _cat: implemented by Token-Pasting Operator. */
23 /*===================================
25 #define ODM_REG_DIG_11N 0xC50
26 #define ODM_REG_DIG_11AC 0xDDD
29 =====================================*/
31 #define _reg_11N(_name) ODM_REG_##_name##_11N
32 #define _reg_11AC(_name) ODM_REG_##_name##_11AC
33 #define _bit_11N(_name) ODM_BIT_##_name##_11N
34 #define _bit_11AC(_name) ODM_BIT_##_name##_11AC
36 #define _cat(_name, _func) \
41 /* _name: name of register or bit. */
42 /* Example: "ODM_REG(R_A_AGC_CORE1, pDM_Odm)" */
43 /* gets "ODM_R_A_AGC_CORE1" or "ODM_R_A_AGC_CORE1_8192C", depends on SupportICType. */
44 #define ODM_REG(_name, _pDM_Odm) _cat(_name, _reg)
45 #define ODM_BIT(_name, _pDM_Odm) _cat(_name, _bit)
48 /* 2012/02/17 MH For non-MP compile pass only. Linux does not support workitem. */
49 /* Suggest HW team to use thread instead of workitem. Windows also support the feature. */
51 typedef void (*RT_WORKITEM_CALL_BACK)(struct work_struct *pContext);
54 /* =========== EXtern Function Prototype */
57 void ODM_SetRFReg(struct dm_odm_t *pDM_Odm, enum RF_RADIO_PATH eRFPath,
58 u32 RegAddr, u32 BitMask, u32 Data);
59 u32 ODM_GetRFReg(struct dm_odm_t *pDM_Odm, enum RF_RADIO_PATH eRFPath,
60 u32 RegAddr, u32 BitMask);
62 #endif /* __ODM_INTERFACE_H__ */