1126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler/*
2126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * drxd_firm.h
3126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler *
4126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * Copyright (C) 2006-2007 Micronas
5126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler *
6126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * This program is free software; you can redistribute it and/or
7126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * modify it under the terms of the GNU General Public License
8126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * version 2 only, as published by the Free Software Foundation.
9126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler *
10126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler *
11126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * This program is distributed in the hope that it will be useful,
12126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * but WITHOUT ANY WARRANTY; without even the implied warranty of
13126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
14126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * GNU General Public License for more details.
15126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler *
16126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler *
17126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * You should have received a copy of the GNU General Public License
18126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * along with this program; if not, write to the Free Software
19126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA
20126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * 02110-1301, USA
21126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler * Or, point your browser to http://www.gnu.org/copyleft/gpl.html
22126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler */
23126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
24126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#ifndef _DRXD_FIRM_H_
25126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define _DRXD_FIRM_H_
26126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
27bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehab#include <linux/types.h>
28126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#include "drxd_map_firm.h"
29126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
30126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define VERSION_MAJOR 1
31126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define VERSION_MINOR 4
32126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define VERSION_PATCH 23
33126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
34126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define HI_TR_FUNC_ADDR HI_IF_RAM_USR_BEGIN__A
35126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
36126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_MAX_RETRIES (1000)
37126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define HI_I2C_DELAY     84
38126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define HI_I2C_BRIDGE_DELAY   750
39126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
406cacdd46e23826c0591238f5f11b1bfa6490797dDevin Heitmueller#define EQ_TD_TPS_PWR_UNKNOWN          0x00C0	/* Unknown configurations */
41126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QPSK             0x016a
42126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QAM16_ALPHAN     0x0195
43126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QAM16_ALPHA1     0x0195
44126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QAM16_ALPHA2     0x011E
45126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QAM16_ALPHA4     0x01CE
46126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QAM64_ALPHAN     0x019F
47126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QAM64_ALPHA1     0x019F
48126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QAM64_ALPHA2     0x00F8
49126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define EQ_TD_TPS_PWR_QAM64_ALPHA4     0x014D
50126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
51126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_DEF_AG_PWD_CONSUMER 0x000E
52126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_DEF_AG_PWD_PRO 0x0000
53126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_DEF_AG_AGC_SIO 0x0000
54126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
55126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_FE_CTRL_MAX 1023
56126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
57126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_OSCDEV_DO_SCAN  (16)
58126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
59126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_OSCDEV_DONT_SCAN  (0)
60126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
61126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_OSCDEV_STEP  (275)
62126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
63126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_SCAN_TIMEOUT    (650)
64126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
65126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_BANDWIDTH_8MHZ_IN_HZ  (0x8B8249L)
66126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_BANDWIDTH_7MHZ_IN_HZ  (0x7A1200L)
67126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DRXD_BANDWIDTH_6MHZ_IN_HZ  (0x68A1B6L)
68126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
69126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define IRLEN_COARSE_8K       (10)
70126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define IRLEN_FINE_8K         (10)
71126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define IRLEN_COARSE_2K       (7)
72126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define IRLEN_FINE_2K         (9)
73126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DIFF_INVALID          (511)
74126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DIFF_TARGET           (4)
75126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#define DIFF_MARGIN           (1)
76126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
77bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitAtomicRead[];
78bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_HiI2cPatch_1[];
79bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_HiI2cPatch_3[];
80bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehab
81bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitSC[];
82bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehab
83bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_ResetCEFR[];
84bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitFEA2_1[];
85bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitFEA2_2[];
86bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitCPA2[];
87bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitCEA2[];
88bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitEQA2[];
89bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitECA2[];
90bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_ResetECA2[];
91bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_ResetECRAM[];
92bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehab
93bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_A2_microcode[];
94bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u32 DRXD_A2_microcode_length;
95bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehab
96bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitFEB1_1[];
97bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitFEB1_2[];
98bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitCPB1[];
99bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitCEB1[];
100bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitEQB1[];
101bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitECB1[];
102bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehab
103bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitDiversityFront[];
104bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_InitDiversityEnd[];
105bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_DisableDiversity[];
106bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_StartDiversityFront[];
107bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_StartDiversityEnd[];
108bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehab
109bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_DiversityDelay8MHZ[];
110bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_DiversityDelay6MHZ[];
111bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehab
112bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u8 DRXD_B1_microcode[];
113bccd2d8a39a65b008e5af96404139c2260a42fc7Mauro Carvalho Chehabextern u32 DRXD_B1_microcode_length;
114126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler
115126f1e61887085aa2c2cfa7644aee8295a94e1f7Ralph Metzler#endif
116