diff options
author | Oliver Endriss <o.endriss@gmx.de> | 2011-07-03 12:49:44 -0400 |
---|---|---|
committer | Mauro Carvalho Chehab <mchehab@redhat.com> | 2011-07-27 16:55:41 -0400 |
commit | ebc7de220b729b935c006f00b17e333590db6f75 (patch) | |
tree | 2745e8ed236684f6bdec0515e1c44db1256e9d12 /drivers/media/dvb/frontends/drxk_hard.h | |
parent | 874f6518e7c43a0d73a5ba02cc97b02379f8a9bc (diff) |
[media] DRX-K: Tons of coding-style fixes
Tons of coding-style fixes
Signed-off-by: Oliver Endriss <o.endriss@gmx.de>
Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/dvb/frontends/drxk_hard.h')
-rw-r--r-- | drivers/media/dvb/frontends/drxk_hard.h | 231 |
1 files changed, 114 insertions, 117 deletions
diff --git a/drivers/media/dvb/frontends/drxk_hard.h b/drivers/media/dvb/frontends/drxk_hard.h index 550df3434a9..700f40c1263 100644 --- a/drivers/media/dvb/frontends/drxk_hard.h +++ b/drivers/media/dvb/frontends/drxk_hard.h | |||
@@ -52,7 +52,7 @@ enum OperationMode { | |||
52 | OM_DVBT | 52 | OM_DVBT |
53 | }; | 53 | }; |
54 | 54 | ||
55 | typedef enum { | 55 | enum DRXPowerMode { |
56 | DRX_POWER_UP = 0, | 56 | DRX_POWER_UP = 0, |
57 | DRX_POWER_MODE_1, | 57 | DRX_POWER_MODE_1, |
58 | DRX_POWER_MODE_2, | 58 | DRX_POWER_MODE_2, |
@@ -72,7 +72,7 @@ typedef enum { | |||
72 | DRX_POWER_MODE_15, | 72 | DRX_POWER_MODE_15, |
73 | DRX_POWER_MODE_16, | 73 | DRX_POWER_MODE_16, |
74 | DRX_POWER_DOWN = 255 | 74 | DRX_POWER_DOWN = 255 |
75 | }DRXPowerMode_t, *pDRXPowerMode_t; | 75 | }; |
76 | 76 | ||
77 | 77 | ||
78 | /** /brief Intermediate power mode for DRXK, power down OFDM clock domain */ | 78 | /** /brief Intermediate power mode for DRXK, power down OFDM clock domain */ |
@@ -164,8 +164,7 @@ struct DRXKCfgDvbtEchoThres_t { | |||
164 | enum DRXFftmode_t fftMode; | 164 | enum DRXFftmode_t fftMode; |
165 | } ; | 165 | } ; |
166 | 166 | ||
167 | struct SCfgAgc | 167 | struct SCfgAgc { |
168 | { | ||
169 | enum AGC_CTRL_MODE ctrlMode; /* off, user, auto */ | 168 | enum AGC_CTRL_MODE ctrlMode; /* off, user, auto */ |
170 | u16 outputLevel; /* range dependent on AGC */ | 169 | u16 outputLevel; /* range dependent on AGC */ |
171 | u16 minOutputLevel; /* range dependent on AGC */ | 170 | u16 minOutputLevel; /* range dependent on AGC */ |
@@ -173,19 +172,17 @@ struct SCfgAgc | |||
173 | u16 speed; /* range dependent on AGC */ | 172 | u16 speed; /* range dependent on AGC */ |
174 | u16 top; /* rf-agc take over point */ | 173 | u16 top; /* rf-agc take over point */ |
175 | u16 cutOffCurrent; /* rf-agc is accelerated if output current | 174 | u16 cutOffCurrent; /* rf-agc is accelerated if output current |
176 | is below cut-off current */ | 175 | is below cut-off current */ |
177 | u16 IngainTgtMax; | 176 | u16 IngainTgtMax; |
178 | u16 FastClipCtrlDelay; | 177 | u16 FastClipCtrlDelay; |
179 | }; | 178 | }; |
180 | 179 | ||
181 | struct SCfgPreSaw | 180 | struct SCfgPreSaw { |
182 | { | ||
183 | u16 reference; /* pre SAW reference value, range 0 .. 31 */ | 181 | u16 reference; /* pre SAW reference value, range 0 .. 31 */ |
184 | bool usePreSaw; /* TRUE algorithms must use pre SAW sense */ | 182 | bool usePreSaw; /* TRUE algorithms must use pre SAW sense */ |
185 | }; | 183 | }; |
186 | 184 | ||
187 | struct DRXKOfdmScCmd_t | 185 | struct DRXKOfdmScCmd_t { |
188 | { | ||
189 | u16 cmd; /**< Command number */ | 186 | u16 cmd; /**< Command number */ |
190 | u16 subcmd; /**< Sub-command parameter*/ | 187 | u16 subcmd; /**< Sub-command parameter*/ |
191 | u16 param0; /**< General purpous param */ | 188 | u16 param0; /**< General purpous param */ |
@@ -208,127 +205,127 @@ struct drxk_state { | |||
208 | struct mutex mutex; | 205 | struct mutex mutex; |
209 | struct mutex ctlock; | 206 | struct mutex ctlock; |
210 | 207 | ||
211 | u32 m_Instance; ///< Channel 1,2,3 or 4 | 208 | u32 m_Instance; /**< Channel 1,2,3 or 4 */ |
212 | 209 | ||
213 | int m_ChunkSize; | 210 | int m_ChunkSize; |
214 | u8 Chunk[256]; | 211 | u8 Chunk[256]; |
215 | 212 | ||
216 | bool m_hasLNA; | 213 | bool m_hasLNA; |
217 | bool m_hasDVBT; | 214 | bool m_hasDVBT; |
218 | bool m_hasDVBC; | 215 | bool m_hasDVBC; |
219 | bool m_hasAudio; | 216 | bool m_hasAudio; |
220 | bool m_hasATV; | 217 | bool m_hasATV; |
221 | bool m_hasOOB; | 218 | bool m_hasOOB; |
222 | bool m_hasSAWSW; /**< TRUE if mat_tx is available */ | 219 | bool m_hasSAWSW; /**< TRUE if mat_tx is available */ |
223 | bool m_hasGPIO1; /**< TRUE if mat_rx is available */ | 220 | bool m_hasGPIO1; /**< TRUE if mat_rx is available */ |
224 | bool m_hasGPIO2; /**< TRUE if GPIO is available */ | 221 | bool m_hasGPIO2; /**< TRUE if GPIO is available */ |
225 | bool m_hasIRQN; /**< TRUE if IRQN is available */ | 222 | bool m_hasIRQN; /**< TRUE if IRQN is available */ |
226 | u16 m_oscClockFreq; | 223 | u16 m_oscClockFreq; |
227 | u16 m_HICfgTimingDiv; | 224 | u16 m_HICfgTimingDiv; |
228 | u16 m_HICfgBridgeDelay; | 225 | u16 m_HICfgBridgeDelay; |
229 | u16 m_HICfgWakeUpKey; | 226 | u16 m_HICfgWakeUpKey; |
230 | u16 m_HICfgTimeout; | 227 | u16 m_HICfgTimeout; |
231 | u16 m_HICfgCtrl; | 228 | u16 m_HICfgCtrl; |
232 | s32 m_sysClockFreq ; ///< system clock frequency in kHz | 229 | s32 m_sysClockFreq; /**< system clock frequency in kHz */ |
233 | 230 | ||
234 | enum EDrxkState m_DrxkState; ///< State of Drxk (init,stopped,started) | 231 | enum EDrxkState m_DrxkState; /**< State of Drxk (init,stopped,started) */ |
235 | enum OperationMode m_OperationMode; ///< digital standards | 232 | enum OperationMode m_OperationMode; /**< digital standards */ |
236 | struct SCfgAgc m_vsbRfAgcCfg; ///< settings for VSB RF-AGC | 233 | struct SCfgAgc m_vsbRfAgcCfg; /**< settings for VSB RF-AGC */ |
237 | struct SCfgAgc m_vsbIfAgcCfg; ///< settings for VSB IF-AGC | 234 | struct SCfgAgc m_vsbIfAgcCfg; /**< settings for VSB IF-AGC */ |
238 | u16 m_vsbPgaCfg; ///< settings for VSB PGA | 235 | u16 m_vsbPgaCfg; /**< settings for VSB PGA */ |
239 | struct SCfgPreSaw m_vsbPreSawCfg; ///< settings for pre SAW sense | 236 | struct SCfgPreSaw m_vsbPreSawCfg; /**< settings for pre SAW sense */ |
240 | s32 m_Quality83percent; ///< MER level (*0.1 dB) for 83% quality indication | 237 | s32 m_Quality83percent; /**< MER level (*0.1 dB) for 83% quality indication */ |
241 | s32 m_Quality93percent; ///< MER level (*0.1 dB) for 93% quality indication | 238 | s32 m_Quality93percent; /**< MER level (*0.1 dB) for 93% quality indication */ |
242 | bool m_smartAntInverted; | 239 | bool m_smartAntInverted; |
243 | bool m_bDebugEnableBridge; | 240 | bool m_bDebugEnableBridge; |
244 | bool m_bPDownOpenBridge; ///< only open DRXK bridge before power-down once it has been accessed | 241 | bool m_bPDownOpenBridge; /**< only open DRXK bridge before power-down once it has been accessed */ |
245 | bool m_bPowerDown; ///< Power down when not used | 242 | bool m_bPowerDown; /**< Power down when not used */ |
246 | 243 | ||
247 | u32 m_IqmFsRateOfs; ///< frequency shift as written to DRXK register (28bit fixpoint) | 244 | u32 m_IqmFsRateOfs; /**< frequency shift as written to DRXK register (28bit fixpoint) */ |
248 | 245 | ||
249 | bool m_enableMPEGOutput; /**< If TRUE, enable MPEG output */ | 246 | bool m_enableMPEGOutput; /**< If TRUE, enable MPEG output */ |
250 | bool m_insertRSByte; /**< If TRUE, insert RS byte */ | 247 | bool m_insertRSByte; /**< If TRUE, insert RS byte */ |
251 | bool m_enableParallel; /**< If TRUE, parallel out otherwise serial */ | 248 | bool m_enableParallel; /**< If TRUE, parallel out otherwise serial */ |
252 | bool m_invertDATA; /**< If TRUE, invert DATA signals */ | 249 | bool m_invertDATA; /**< If TRUE, invert DATA signals */ |
253 | bool m_invertERR; /**< If TRUE, invert ERR signal */ | 250 | bool m_invertERR; /**< If TRUE, invert ERR signal */ |
254 | bool m_invertSTR; /**< If TRUE, invert STR signals */ | 251 | bool m_invertSTR; /**< If TRUE, invert STR signals */ |
255 | bool m_invertVAL; /**< If TRUE, invert VAL signals */ | 252 | bool m_invertVAL; /**< If TRUE, invert VAL signals */ |
256 | bool m_invertCLK; /**< If TRUE, invert CLK signals */ | 253 | bool m_invertCLK; /**< If TRUE, invert CLK signals */ |
257 | bool m_DVBCStaticCLK; | 254 | bool m_DVBCStaticCLK; |
258 | bool m_DVBTStaticCLK; /**< If TRUE, static MPEG clockrate will | 255 | bool m_DVBTStaticCLK; /**< If TRUE, static MPEG clockrate will |
259 | be used, otherwise clockrate will | 256 | be used, otherwise clockrate will |
260 | adapt to the bitrate of the TS */ | 257 | adapt to the bitrate of the TS */ |
261 | u32 m_DVBTBitrate; | 258 | u32 m_DVBTBitrate; |
262 | u32 m_DVBCBitrate; | 259 | u32 m_DVBCBitrate; |
263 | 260 | ||
264 | u8 m_TSDataStrength; | 261 | u8 m_TSDataStrength; |
265 | u8 m_TSClockkStrength; | 262 | u8 m_TSClockkStrength; |
266 | 263 | ||
267 | enum DRXMPEGStrWidth_t m_widthSTR; /**< MPEG start width**/ | 264 | enum DRXMPEGStrWidth_t m_widthSTR; /**< MPEG start width */ |
268 | u32 m_mpegTsStaticBitrate; /**< Maximum bitrate in b/s in case | 265 | u32 m_mpegTsStaticBitrate; /**< Maximum bitrate in b/s in case |
269 | static clockrate is selected */ | 266 | static clockrate is selected */ |
270 | 267 | ||
271 | //LARGE_INTEGER m_StartTime; ///< Contains the time of the last demod start | 268 | /* LARGE_INTEGER m_StartTime; */ /**< Contains the time of the last demod start */ |
272 | s32 m_MpegLockTimeOut; ///< WaitForLockStatus Timeout (counts from start time) | 269 | s32 m_MpegLockTimeOut; /**< WaitForLockStatus Timeout (counts from start time) */ |
273 | s32 m_DemodLockTimeOut; ///< WaitForLockStatus Timeout (counts from start time) | 270 | s32 m_DemodLockTimeOut; /**< WaitForLockStatus Timeout (counts from start time) */ |
274 | 271 | ||
275 | bool m_disableTEIhandling; | 272 | bool m_disableTEIhandling; |
276 | 273 | ||
277 | bool m_RfAgcPol; | 274 | bool m_RfAgcPol; |
278 | bool m_IfAgcPol; | 275 | bool m_IfAgcPol; |
279 | 276 | ||
280 | struct SCfgAgc m_atvRfAgcCfg; ///< settings for ATV RF-AGC | 277 | struct SCfgAgc m_atvRfAgcCfg; /**< settings for ATV RF-AGC */ |
281 | struct SCfgAgc m_atvIfAgcCfg; ///< settings for ATV IF-AGC | 278 | struct SCfgAgc m_atvIfAgcCfg; /**< settings for ATV IF-AGC */ |
282 | struct SCfgPreSaw m_atvPreSawCfg; ///< settings for ATV pre SAW sense | 279 | struct SCfgPreSaw m_atvPreSawCfg; /**< settings for ATV pre SAW sense */ |
283 | bool m_phaseCorrectionBypass; | 280 | bool m_phaseCorrectionBypass; |
284 | s16 m_atvTopVidPeak; | 281 | s16 m_atvTopVidPeak; |
285 | u16 m_atvTopNoiseTh; | 282 | u16 m_atvTopNoiseTh; |
286 | enum EDrxkSifAttenuation m_sifAttenuation; | 283 | enum EDrxkSifAttenuation m_sifAttenuation; |
287 | bool m_enableCVBSOutput; | 284 | bool m_enableCVBSOutput; |
288 | bool m_enableSIFOutput; | 285 | bool m_enableSIFOutput; |
289 | bool m_bMirrorFreqSpect; | 286 | bool m_bMirrorFreqSpect; |
290 | enum EDrxkConstellation m_Constellation; ///< Constellation type of the channel | 287 | enum EDrxkConstellation m_Constellation; /**< Constellation type of the channel */ |
291 | u32 m_CurrSymbolRate; ///< Current QAM symbol rate | 288 | u32 m_CurrSymbolRate; /**< Current QAM symbol rate */ |
292 | struct SCfgAgc m_qamRfAgcCfg; ///< settings for QAM RF-AGC | 289 | struct SCfgAgc m_qamRfAgcCfg; /**< settings for QAM RF-AGC */ |
293 | struct SCfgAgc m_qamIfAgcCfg; ///< settings for QAM IF-AGC | 290 | struct SCfgAgc m_qamIfAgcCfg; /**< settings for QAM IF-AGC */ |
294 | u16 m_qamPgaCfg; ///< settings for QAM PGA | 291 | u16 m_qamPgaCfg; /**< settings for QAM PGA */ |
295 | struct SCfgPreSaw m_qamPreSawCfg; ///< settings for QAM pre SAW sense | 292 | struct SCfgPreSaw m_qamPreSawCfg; /**< settings for QAM pre SAW sense */ |
296 | enum EDrxkInterleaveMode m_qamInterleaveMode; ///< QAM Interleave mode | 293 | enum EDrxkInterleaveMode m_qamInterleaveMode; /**< QAM Interleave mode */ |
297 | u16 m_fecRsPlen; | 294 | u16 m_fecRsPlen; |
298 | u16 m_fecRsPrescale; | 295 | u16 m_fecRsPrescale; |
299 | 296 | ||
300 | enum DRXKCfgDvbtSqiSpeed m_sqiSpeed; | 297 | enum DRXKCfgDvbtSqiSpeed m_sqiSpeed; |
301 | 298 | ||
302 | u16 m_GPIO; | 299 | u16 m_GPIO; |
303 | u16 m_GPIOCfg; | 300 | u16 m_GPIOCfg; |
304 | 301 | ||
305 | struct SCfgAgc m_dvbtRfAgcCfg; ///< settings for QAM RF-AGC | 302 | struct SCfgAgc m_dvbtRfAgcCfg; /**< settings for QAM RF-AGC */ |
306 | struct SCfgAgc m_dvbtIfAgcCfg; ///< settings for QAM IF-AGC | 303 | struct SCfgAgc m_dvbtIfAgcCfg; /**< settings for QAM IF-AGC */ |
307 | struct SCfgPreSaw m_dvbtPreSawCfg; ///< settings for QAM pre SAW sense | 304 | struct SCfgPreSaw m_dvbtPreSawCfg; /**< settings for QAM pre SAW sense */ |
308 | 305 | ||
309 | u16 m_agcFastClipCtrlDelay; | 306 | u16 m_agcFastClipCtrlDelay; |
310 | bool m_adcCompPassed; | 307 | bool m_adcCompPassed; |
311 | u16 m_adcCompCoef[64]; | 308 | u16 m_adcCompCoef[64]; |
312 | u16 m_adcState; | 309 | u16 m_adcState; |
313 | 310 | ||
314 | u8 *m_microcode; | 311 | u8 *m_microcode; |
315 | int m_microcode_length; | 312 | int m_microcode_length; |
316 | bool m_DRXK_A1_PATCH_CODE; | 313 | bool m_DRXK_A1_PATCH_CODE; |
317 | bool m_DRXK_A1_ROM_CODE; | 314 | bool m_DRXK_A1_ROM_CODE; |
318 | bool m_DRXK_A2_ROM_CODE; | 315 | bool m_DRXK_A2_ROM_CODE; |
319 | bool m_DRXK_A3_ROM_CODE; | 316 | bool m_DRXK_A3_ROM_CODE; |
320 | bool m_DRXK_A2_PATCH_CODE; | 317 | bool m_DRXK_A2_PATCH_CODE; |
321 | bool m_DRXK_A3_PATCH_CODE; | 318 | bool m_DRXK_A3_PATCH_CODE; |
322 | 319 | ||
323 | bool m_rfmirror; | 320 | bool m_rfmirror; |
324 | u8 m_deviceSpin; | 321 | u8 m_deviceSpin; |
325 | u32 m_iqmRcRate; | 322 | u32 m_iqmRcRate; |
326 | 323 | ||
327 | u16 m_AntennaDVBC; | 324 | u16 m_AntennaDVBC; |
328 | u16 m_AntennaDVBT; | 325 | u16 m_AntennaDVBT; |
329 | u16 m_AntennaSwitchDVBTDVBC; | 326 | u16 m_AntennaSwitchDVBTDVBC; |
330 | 327 | ||
331 | DRXPowerMode_t m_currentPowerMode; | 328 | enum DRXPowerMode m_currentPowerMode; |
332 | }; | 329 | }; |
333 | 330 | ||
334 | #define NEVER_LOCK 0 | 331 | #define NEVER_LOCK 0 |