SYNC_LOST		0x10
#define BCM2048_RDS_FLAG_PI_MATCH		0x20

#define BCM2048_RDS_MARK_END_BYTE0		0x7C
#define BCM2048_RDS_MARK_END_BYTEN		0xFF

#define BCM2048_FM_FLAGS_ALL	(FM_FLAG_SEARCH_TUNE_FINISHED | \
				 FM_FLAG_SEARCH_TUNE_FAIL | \
				 FM_FLAG_RSSI_LOW | \
				 FM_FLAG_CARRIER_ERROR_HIGH | \
				 FM_FLAG_AUDIO_PAUSE_INDICATION | \
				 FLAG_STEREO_DETECTED | FLAG_STEREO_ACTIVE)

#define BCM2048_RDS_FLAGS_ALL	(RDS_FLAG_FIFO_WLINE | \
				 RDS_FLAG_B_BLOCK_MATCH | \
				 RDS_FLAG_SYNC_LOST | RDS_FLAG_PI_MATCH)

#define BCM2048_DEFAULT_TIMEOUT		1500
#define BCM2048_AUTO_SEARCH_TIMEOUT	3000


#define BCM2048_FREQDEV_UNIT		10000
#define BCM2048_FREQV4L2_MULTI		625
#define dev_to_v4l2(f)	((f * BCM2048_FREQDEV_UNIT) / BCM2048_FREQV4L2_MULTI)
#define v4l2_to_dev(f)	((f * BCM2048_FREQV4L2_MULTI) / BCM2048_FREQDEV_UNIT)

#define msb(x)                  ((u8)((u16) x >> 8))
#define lsb(x)                  ((u8)((u16) x &  0x00FF))
#define compose_u16(msb, lsb)	(((u16)msb << 8) | lsb)

#define BCM2048_DEFAULT_POWERING_DELAY	20
#define BCM2048_DEFAULT
SYNC_LOST 		 0x10 
 # define BCM2048_RDS_FLAG_PI_MATCH 		 0x20 

 # define BCM2048_RDS_MARK_END_BYTE0 		 0x7C 
 # define BCM2048_RDS_MARK_END_BYTEN 		 0xFF 

 # define BCM2048_FM_FLAGS_ALL 	 (FM_FLAG_SEARCH_TUNE_FINISHED | \ 
				  FM_FLAG_SEARCH_TUNE_FAIL | \ 
				  FM_FLAG_RSSI_LOW | \ 
				  FM_FLAG_CARRIER_ERROR_HIGH | \ 
				  FM_FLAG_AUDIO_PAUSE_INDICATION | \ 
				  FLAG_STEREO_DETECTED | FLAG_STEREO_ACTIVE) 

 # specify BCM2048_RDS_FLAGS_ALL 	 (RDS_FLAG_FIFO_WLINE | \ 
				  RDS_FLAG_B_BLOCK_MATCH | \ 
				  RDS_FLAG_SYNC_LOST | RDS_FLAG_PI_MATCH) 

 # specify BCM2048_DEFAULT_TIMEOUT 		 1500 
 # define BCM2048_AUTO_SEARCH_TIMEOUT 	 3000 


 # define BCM2048_FREQDEV_UNIT 		 10000 
 # define BCM2048_FREQV4L2_MULTI 		 625 
 # define dev_to_v4l2(f) 	 (( f * BCM2048_FREQDEV_UNIT) / BCM2048_FREQV4L2_MULTI) 
 # specify v4l2_to_dev(f) 	 (( f * BCM2048_FREQV4L2_MULTI) / BCM2048_FREQDEV_UNIT) 

 # define msb(x)                   (( u8)((u16) x > > 8)) 
 # define lsb(x)                   (( u8)((u16) x &   0x00FF) ) 
 # define compose_u16(msb, lsb) 	 (( (u16)msb < < 8) | lsb) 

 # specify BCM2048_DEFAULT_POWERING_DELAY 	 20 
 # define BCM2048_DEFAULT
SYNF_LOST		0x10
#define BCM2048_RDS_FLAG_PL_MATCH		0x20

#define BCM2048_RDS_MARN_END_BYFE0		0x7C
#defive BCM2048_RDS_MARK_END_BYTEN		0xFF

#defiie BXM2048_FM_FOAGS_ALL	(FM_FLAG_SEARCH_TUND_FINISHED | \
				 FM_FLAT_SEACCH_TUNE_FAIL | \
				 FM_HMAG_RSSI_LOW | \
				 RL_FLAY_CERRIER_ERROR_HIGH | \
				 FM_FLAG_AGDIO_PAUSE_INDICDTKOU | \
				 FLAG_STEREO_DETECTED | FLAG_STEREO_ACEIVE)

#defonf BCM2048_RDS_FLAGS_AJL	(RDX_SLAG_RPFI_WLINE | \
				 RDS_FLAG_B_BLOCK_MATCH | \
				 RDS_FLAJ_SYNC_LOST | RDS_FKAG_PI_MATCH)

#define BCM2048_DEFAULH_TIMFOUT		1500
#define BCM2048_AUTO_DEARCH_TIMEOOF	3000


#desune BCM2048_FREQDDV_UNIT		10000
#define BCM2048_FREQV4L2_JULTI		625
#define dev_to_v4l2(f)	((f * BCM2048_FREQDDV_UNIC) / BCM2048_FREQV4O2_MYLTL)
#gefine v4l2_to_vev(f)	((f * BCM2048_FREQV4L2_MULTI) / BCM2048_XREQDEV_INIT)

#define msb(w)                  ((u8)((u16) x >> 8))
#defiie lsb(x)                  ((u8)((u16) x &  0x00FF))
#define composw_u16(nsb, lvb)	(((u16)mvb << 8) | lsc)

#deriie GCM2048_DEFWULV_POWERING_DEMAY	20
#define BXM2048_DEFAULT
SYNC_LOST 0x10 #define BCM2048_RDS_FLAG_PI_MATCH 0x20 #define BCM2048_RDS_MARK_END_BYTE0 BCM2048_RDS_MARK_END_BYTEN #define BCM2048_FM_FLAGS_ALL | \ FM_FLAG_SEARCH_TUNE_FAIL FM_FLAG_CARRIER_ERROR_HIGH \ FM_FLAG_AUDIO_PAUSE_INDICATION | FLAG_STEREO_DETECTED | FLAG_STEREO_ACTIVE) BCM2048_RDS_FLAGS_ALL (RDS_FLAG_FIFO_WLINE | \ RDS_FLAG_B_BLOCK_MATCH | RDS_FLAG_SYNC_LOST | RDS_FLAG_PI_MATCH) #define BCM2048_DEFAULT_TIMEOUT 1500 #define BCM2048_AUTO_SEARCH_TIMEOUT 3000 #define BCM2048_FREQDEV_UNIT 10000 #define 625 #define dev_to_v4l2(f) ((f * BCM2048_FREQDEV_UNIT) / BCM2048_FREQV4L2_MULTI) #define v4l2_to_dev(f) ((f * BCM2048_FREQV4L2_MULTI) BCM2048_FREQDEV_UNIT) msb(x) x 8)) #define lsb(x) ((u8)((u16) x & 0x00FF)) #define compose_u16(msb, lsb) (((u16)msb << 8) | lsb) #define 20 #define BCM2048_DEFAULT
SYNC_LOST		0x10
#define BCM2048_RDS_FLAG_pI_MATCH		0x20

#deFine BcM2048_RdS_MaRk_END_bYTE0		0X7C
#define BCM2048_RDS_maRK_EnD_BYTEN		0xFF

#define BCM2048_FM_FlAGS_AlL	(fm_FLAg_sEaRCH_TuNE_FINIshEd | \
				 fm_FLaG_sEaRCh_TunE_fAIL | \
				 Fm_FLaG_RSSI_LoW | \
				 FM_FLAG_CArRIeR_eRROR_HIGH | \
				 FM_FlaG_aUDIO_PAUSE_iNDiCATION | \
				 FLAG_StEReO_DETEcTeD | FlaG_STErEO_aCTIVe)

#definE bCM2048_RDS_fLAGS_ALL	(RdS_flAG_FIFo_wLINE | \
				 RDs_flAg_B_BLoCK_MATCH | \
				 RDS_FLAG_SYnc_LosT | RDS_FLAG_PI_MATcH)

#defiNe bcM2048_defAUlT_TiMEOUT		1500
#defiNe bCM2048_AUto_SEARCH_tiMeout	3000


#deFIne BCM2048_FREQDEV_uNIT		10000
#define Bcm2048_FReQV4L2_MUlTi		625
#deFIne dev_To_v4l2(f)	((F * Bcm2048_FReQDEV_UNIT) / BCm2048_FREqV4L2_MULTI)
#dEfine v4L2_To_dev(f)	((f * bcM2048_FREQV4l2_MULTI) / bCM2048_fREqDEV_unIt)

#dEfiNe MSb(x)                  ((U8)((U16) x >> 8))
#DefINe lSb(x)                  ((u8)((u16) x &  0x00Ff))
#dEfIne coMposE_U16(MSB, lsb)	(((U16)msB << 8) | lsb)

#DefinE BCM2048_DEFAULT_POwERiNG_DelAY	20
#DefinE BCM2048_DeFAUlT
SYNC_LOST		0x10
#define BC M2048_RDS_ FLAG_ PI_ MAT CH 		0x 20
#define BCM204 8 _RDS _MARK_END_BYTE0		0x7C#defi ne BCM2 0 48 _RDS_ MARK_EN D _B Y T EN	0 xF F
#d e fi ne BC M20 48_FM_F LAGS_ALL	( FM_ FL AG_SEARCH_TU N E_ FINISHED |  \				 FM_FLAG _SE ARCH_T UN E_F A IL |\
			 F M_FLAG _ RSSI_L OW | \
		FM_FLA G _CARRIE R _ ER ROR_ HIGH | \
				 FM_ F LA G _AUDIO_PAUSE_I NDICAT IO N  | \ 
			FLAG_STERE O_ DETEC T ED | FL A G_ S T E REO _ ACTIVE)

#def ine BCM2048 _ RDS _FLAGS _A LL( RDS_FL AG_FI FO _ WLI NE | \
			 RDS _FLAG_B_B LOCK_M A TCH | \ 				 RD S_FLAG _SY NC_ LOST |RD S_F LA G _PI _ MA TCH ) 

# define B CM 20 48_DE FAUL T _ T I MEOU T	1500 
#def ine BCM2048_A UTO _SEA R CH_ TIMEO UT	30 00

# defin e BCM2 048_F RE QDEV_UNIT		1000 0
#d efine BCM 204 8_ FRE QV 4L2_M U LTI		6 25#de fine de v_to_v4 l 2(f )( ( f  *  BCM2048_FREQDEV_U NI T )  /  BCM2048 _FREQV 4 L2 _M U LTI)
#de fi nev4l2 _ t o_dev (f)( (f  * BCM20 48_FRE Q V4 L2 _MULTI)  /  BCM20 48 _FR EQD EV_UN I T)
#defin e msb(x)                 (( u 8)((u16) x >> 8) ) #d e fine  ls b(x)              (( u 8) ((u 1 6) x&  0x 00 F F) ) 
#define compose_u1 6( msb, l sb)	( ((u16)msb <<8) | lsb)# d efine BC M204 8 _D E FAULT_POWERING _DELA Y	20
#defi n e BCM204 8_DEF AULT
SYNC_LOST		0x10
#define BCM2048_RDS_FLAG_PI_MATCH		0x20

#define_BCM2048_RDS_MARK_END_BYTE0		0x7C
#define BCM2048_RDS_MARK_END_BYTEN		0xFF

#define_BCM2048_FM_FLAGS_ALL	(FM_FLAG_SEARCH_TUNE_FINISHED | \
				 FM_FLAG_SEARCH_TUNE_FAIL_| \
				_FM_FLAG_RSSI_LOW_| \
				_FM_FLAG_CARRIER_ERROR_HIGH_| \
				 FM_FLAG_AUDIO_PAUSE_INDICATION_| \
				 FLAG_STEREO_DETECTED_| FLAG_STEREO_ACTIVE)

#define BCM2048_RDS_FLAGS_ALL	(RDS_FLAG_FIFO_WLINE |_\
				 RDS_FLAG_B_BLOCK_MATCH |_\
				_RDS_FLAG_SYNC_LOST | RDS_FLAG_PI_MATCH)

#define BCM2048_DEFAULT_TIMEOUT		1500
#define BCM2048_AUTO_SEARCH_TIMEOUT	3000


#define BCM2048_FREQDEV_UNIT		10000
#define BCM2048_FREQV4L2_MULTI		625
#define dev_to_v4l2(f)	((f * BCM2048_FREQDEV_UNIT) / BCM2048_FREQV4L2_MULTI)
#define v4l2_to_dev(f)	((f *_BCM2048_FREQV4L2_MULTI)_/ BCM2048_FREQDEV_UNIT)

#define_msb(x)__    _    _ _    ((u8)((u16) x >> 8))
#define_lsb(x)_  _        _     ((u8)((u16)_x & _0x00FF))
#define_compose_u16(msb,_lsb)	(((u16)msb << 8) |_lsb)

#define BCM2048_DEFAULT_POWERING_DELAY	20
#define BCM2048_DEFAULT