xref: /linux/drivers/staging/rtl8723bs/hal/odm_CfoTracking.h (revision 762f99f4f3cb41a775b5157dd761217beba65873)
1 /* SPDX-License-Identifier: GPL-2.0 */
2 /******************************************************************************
3  *
4  * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
5  *
6  ******************************************************************************/
7 
8 #ifndef	__ODMCFOTRACK_H__
9 #define    __ODMCFOTRACK_H__
10 
11 #define		CFO_TH_XTAL_HIGH		20		/*  kHz */
12 #define		CFO_TH_XTAL_LOW			10		/*  kHz */
13 #define		CFO_TH_ATC			80		/*  kHz */
14 
15 struct cfo_tracking {
16 	bool bATCStatus;
17 	bool largeCFOHit;
18 	bool bAdjust;
19 	u8 CrystalCap;
20 	u8 DefXCap;
21 	int CFO_tail[2];
22 	int CFO_ave_pre;
23 	u32 packetCount;
24 	u32 packetCount_pre;
25 
26 	bool bForceXtalCap;
27 	bool bReset;
28 };
29 
30 void ODM_CfoTrackingReset(void *pDM_VOID
31 );
32 
33 void ODM_CfoTrackingInit(void *pDM_VOID);
34 
35 void ODM_CfoTracking(void *pDM_VOID);
36 
37 void odm_parsing_cfo(void *pDM_VOID, void *pPktinfo_VOID, s8 *pcfotail);
38 
39 #endif
40