Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
L
linux
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
linux
Commits
c61843a8
Commit
c61843a8
authored
Dec 01, 2002
by
Art Haas
Committed by
Linus Torvalds
Dec 01, 2002
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[PATCH] C99 initializers for drivers/media/dvb/frontends
parent
ef0df73b
Changes
7
Hide whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
114 additions
and
139 deletions
+114
-139
drivers/media/dvb/frontends/alps_bsru6.c
drivers/media/dvb/frontends/alps_bsru6.c
+21
-21
drivers/media/dvb/frontends/alps_bsrv2.c
drivers/media/dvb/frontends/alps_bsrv2.c
+18
-18
drivers/media/dvb/frontends/alps_tdlb7.c
drivers/media/dvb/frontends/alps_tdlb7.c
+14
-20
drivers/media/dvb/frontends/alps_tdmb7.c
drivers/media/dvb/frontends/alps_tdmb7.c
+14
-20
drivers/media/dvb/frontends/grundig_29504-401.c
drivers/media/dvb/frontends/grundig_29504-401.c
+15
-19
drivers/media/dvb/frontends/grundig_29504-491.c
drivers/media/dvb/frontends/grundig_29504-491.c
+18
-20
drivers/media/dvb/frontends/ves1820.c
drivers/media/dvb/frontends/ves1820.c
+14
-21
No files found.
drivers/media/dvb/frontends/alps_bsru6.c
View file @
c61843a8
...
@@ -39,22 +39,22 @@ static int debug = 0;
...
@@ -39,22 +39,22 @@ static int debug = 0;
static
static
struct
dvb_frontend_info
bsru6_info
=
{
struct
dvb_frontend_info
bsru6_info
=
{
#ifdef CONFIG_ALPS_BSRU6_IS_LG_TDQBS00X
#ifdef CONFIG_ALPS_BSRU6_IS_LG_TDQBS00X
name:
"LG TDQB-S00x"
,
.
name
=
"LG TDQB-S00x"
,
#else
#else
name:
"Alps BSRU6"
,
.
name
=
"Alps BSRU6"
,
#endif
#endif
type:
FE_QPSK
,
.
type
=
FE_QPSK
,
frequency_min:
950000
,
.
frequency_min
=
950000
,
frequency_max:
2150000
,
.
frequency_max
=
2150000
,
frequency_stepsize:
125
,
/* kHz for QPSK frontends */
.
frequency_stepsize
=
125
,
/* kHz for QPSK frontends */
frequency_tolerance:
M_CLK
/
2000
,
.
frequency_tolerance
=
M_CLK
/
2000
,
symbol_rate_min:
1000000
,
.
symbol_rate_min
=
1000000
,
symbol_rate_max:
45000000
,
.
symbol_rate_max
=
45000000
,
symbol_rate_tolerance:
500
,
/* ppm */
.
symbol_rate_tolerance
=
500
,
/* ppm */
notifier_delay:
0
,
.
caps
=
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
caps:
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
FE_CAN_FEC_3_4
|
FE_CAN_FEC_3_4
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_7_8
|
FE_CAN_FEC_AUTO
|
FE_CAN_FEC_7_8
|
FE_CAN_FEC_AUTO
|
FE_CAN_QPSK
FE_CAN_QPSK
};
};
...
@@ -158,7 +158,7 @@ int stv0299_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
...
@@ -158,7 +158,7 @@ int stv0299_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
{
{
int
ret
;
int
ret
;
u8
buf
[]
=
{
reg
,
data
};
u8
buf
[]
=
{
reg
,
data
};
struct
i2c_msg
msg
=
{
addr
:
0x68
,
flags
:
0
,
buf
:
buf
,
len
:
2
};
struct
i2c_msg
msg
=
{
.
addr
=
0x68
,
.
flags
=
0
,
.
buf
=
buf
,
.
len
=
2
};
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
...
@@ -178,8 +178,8 @@ u8 stv0299_readreg (struct dvb_i2c_bus *i2c, u8 reg)
...
@@ -178,8 +178,8 @@ u8 stv0299_readreg (struct dvb_i2c_bus *i2c, u8 reg)
int
ret
;
int
ret
;
u8
b0
[]
=
{
reg
};
u8
b0
[]
=
{
reg
};
u8
b1
[]
=
{
0
};
u8
b1
[]
=
{
0
};
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x68
,
flags
:
0
,
buf
:
b0
,
len
:
1
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x68
,
.
flags
=
0
,
.
buf
=
b0
,
.
len
=
1
},
{
addr
:
0x68
,
flags
:
I2C_M_RD
,
buf
:
b1
,
len
:
1
}
};
{
.
addr
=
0x68
,
.
flags
=
I2C_M_RD
,
.
buf
=
b1
,
.
len
=
1
}
};
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
...
@@ -196,8 +196,8 @@ static
...
@@ -196,8 +196,8 @@ static
int
stv0299_readregs
(
struct
dvb_i2c_bus
*
i2c
,
u8
reg1
,
u8
*
b
,
u8
len
)
int
stv0299_readregs
(
struct
dvb_i2c_bus
*
i2c
,
u8
reg1
,
u8
*
b
,
u8
len
)
{
{
int
ret
;
int
ret
;
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x68
,
flags
:
0
,
buf
:
&
reg1
,
len
:
1
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x68
,
.
flags
=
0
,
.
buf
=
&
reg1
,
.
len
=
1
},
{
addr
:
0x68
,
flags
:
I2C_M_RD
,
buf
:
b
,
len
:
len
}
};
{
.
addr
=
0x68
,
.
flags
=
I2C_M_RD
,
.
buf
=
b
,
.
len
=
len
}
};
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
...
@@ -216,8 +216,8 @@ int tsa5059_write (struct dvb_i2c_bus *i2c, u8 data [4])
...
@@ -216,8 +216,8 @@ int tsa5059_write (struct dvb_i2c_bus *i2c, u8 data [4])
{
{
int
ret
;
int
ret
;
u8
rpt1
[]
=
{
0x05
,
0xb5
};
/* enable i2c repeater on stv0299 */
u8
rpt1
[]
=
{
0x05
,
0xb5
};
/* enable i2c repeater on stv0299 */
struct
i2c_msg
msg
[]
=
{{
addr
:
0x68
,
flags
:
0
,
buf
:
rpt1
,
len
:
2
},
struct
i2c_msg
msg
[]
=
{{
.
addr
=
0x68
,
.
flags
=
0
,
.
buf
=
rpt1
,
.
len
=
2
},
{
addr
:
0x61
,
flags
:
0
,
buf
:
data
,
len
:
4
}};
{
.
addr
=
0x61
,
.
flags
=
0
,
.
buf
=
data
,
.
len
=
4
}};
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
...
...
drivers/media/dvb/frontends/alps_bsrv2.c
View file @
c61843a8
...
@@ -32,20 +32,20 @@ static int debug = 0;
...
@@ -32,20 +32,20 @@ static int debug = 0;
static
static
struct
dvb_frontend_info
bsrv2_info
=
{
struct
dvb_frontend_info
bsrv2_info
=
{
name:
"Alps BSRV2"
,
.
name
=
"Alps BSRV2"
,
type:
FE_QPSK
,
.
type
=
FE_QPSK
,
frequency_min:
950000
,
.
frequency_min
=
950000
,
frequency_max:
2150000
,
.
frequency_max
=
2150000
,
frequency_stepsize:
250
,
/* kHz for QPSK frontends */
.
frequency_stepsize
=
250
,
/* kHz for QPSK frontends */
frequency_tolerance:
29500
,
.
frequency_tolerance
=
29500
,
symbol_rate_min:
1000000
,
.
symbol_rate_min
=
1000000
,
symbol_rate_max:
45000000
,
.
symbol_rate_max
=
45000000
,
/* symbol_rate_tolerance: ???,
*/
.
notifier_delay
=
50
,
/* 1/20 s
*/
notifier_delay:
50
,
/* 1/20 s */
.
caps
=
FE_CAN_INVERSION_AUTO
|
caps:
FE_CAN_INVERSION_AUTO
|
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
FE_CAN_FEC_3_4
|
FE_CAN_FEC_3_4
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_7_8
|
FE_CAN_FEC_AUTO
|
FE_CAN_FEC_7_8
|
FE_CAN_FEC_AUTO
|
FE_CAN_QPSK
FE_CAN_QPSK
};
};
...
@@ -76,7 +76,7 @@ static
...
@@ -76,7 +76,7 @@ static
int
ves1893_writereg
(
struct
dvb_i2c_bus
*
i2c
,
int
reg
,
int
data
)
int
ves1893_writereg
(
struct
dvb_i2c_bus
*
i2c
,
int
reg
,
int
data
)
{
{
u8
buf
[]
=
{
0x00
,
reg
,
data
};
u8
buf
[]
=
{
0x00
,
reg
,
data
};
struct
i2c_msg
msg
=
{
addr
:
0x08
,
flags
:
0
,
buf
:
buf
,
len
:
3
};
struct
i2c_msg
msg
=
{
.
addr
=
0x08
,
.
flags
=
0
,
.
buf
=
buf
,
.
len
=
3
};
int
err
;
int
err
;
if
((
err
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
))
!=
1
)
{
if
((
err
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
))
!=
1
)
{
...
@@ -94,8 +94,8 @@ u8 ves1893_readreg (struct dvb_i2c_bus *i2c, u8 reg)
...
@@ -94,8 +94,8 @@ u8 ves1893_readreg (struct dvb_i2c_bus *i2c, u8 reg)
int
ret
;
int
ret
;
u8
b0
[]
=
{
0x00
,
reg
};
u8
b0
[]
=
{
0x00
,
reg
};
u8
b1
[]
=
{
0
};
u8
b1
[]
=
{
0
};
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x08
,
flags
:
0
,
buf
:
b0
,
len
:
2
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x08
,
.
flags
=
0
,
.
buf
=
b0
,
.
len
=
2
},
{
addr
:
0x08
,
flags
:
I2C_M_RD
,
buf
:
b1
,
len
:
1
}
};
{
.
addr
=
0x08
,
.
flags
=
I2C_M_RD
,
.
buf
=
b1
,
.
len
=
1
}
};
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
...
@@ -110,7 +110,7 @@ static
...
@@ -110,7 +110,7 @@ static
int
sp5659_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
int
sp5659_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
{
{
int
ret
;
int
ret
;
struct
i2c_msg
msg
=
{
addr
:
0x61
,
flags
:
0
,
buf
:
data
,
len
:
4
};
struct
i2c_msg
msg
=
{
.
addr
=
0x61
,
.
flags
=
0
,
.
buf
=
data
,
.
len
=
4
};
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
...
...
drivers/media/dvb/frontends/alps_tdlb7.c
View file @
c61843a8
...
@@ -73,21 +73,15 @@ static int errno;
...
@@ -73,21 +73,15 @@ static int errno;
static
static
struct
dvb_frontend_info
tdlb7_info
=
{
struct
dvb_frontend_info
tdlb7_info
=
{
name:
"Alps TDLB7"
,
.
name
=
"Alps TDLB7"
,
type:
FE_OFDM
,
.
type
=
FE_OFDM
,
frequency_min:
470000000
,
.
frequency_min
=
470000000
,
frequency_max:
860000000
,
.
frequency_max
=
860000000
,
frequency_stepsize:
166666
,
.
frequency_stepsize
=
166666
,
#if 0
.
caps
=
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
frequency_tolerance: ???,
FE_CAN_FEC_3_4
|
FE_CAN_FEC_5_6
|
symbol_rate_min: ???,
FE_CAN_FEC_7_8
|
FE_CAN_FEC_AUTO
|
symbol_rate_max: ???,
FE_CAN_QPSK
|
FE_CAN_QAM_16
|
FE_CAN_QAM_64
symbol_rate_tolerance: ???,
notifier_delay: 0,
#endif
caps:
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
FE_CAN_FEC_3_4
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_7_8
|
FE_CAN_FEC_AUTO
|
FE_CAN_QPSK
|
FE_CAN_QAM_16
|
FE_CAN_QAM_64
};
};
...
@@ -95,7 +89,7 @@ static
...
@@ -95,7 +89,7 @@ static
int
sp8870_writereg
(
struct
dvb_i2c_bus
*
i2c
,
u16
reg
,
u16
data
)
int
sp8870_writereg
(
struct
dvb_i2c_bus
*
i2c
,
u16
reg
,
u16
data
)
{
{
u8
buf
[]
=
{
reg
>>
8
,
reg
&
0xff
,
data
>>
8
,
data
&
0xff
};
u8
buf
[]
=
{
reg
>>
8
,
reg
&
0xff
,
data
>>
8
,
data
&
0xff
};
struct
i2c_msg
msg
=
{
addr
:
0x71
,
flags
:
0
,
buf
:
buf
,
len
:
4
};
struct
i2c_msg
msg
=
{
.
addr
=
0x71
,
.
flags
=
0
,
.
buf
=
buf
,
.
len
=
4
};
int
err
;
int
err
;
if
((
err
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
))
!=
1
)
{
if
((
err
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
))
!=
1
)
{
...
@@ -113,8 +107,8 @@ u16 sp8870_readreg (struct dvb_i2c_bus *i2c, u16 reg)
...
@@ -113,8 +107,8 @@ u16 sp8870_readreg (struct dvb_i2c_bus *i2c, u16 reg)
int
ret
;
int
ret
;
u8
b0
[]
=
{
reg
>>
8
,
reg
&
0xff
};
u8
b0
[]
=
{
reg
>>
8
,
reg
&
0xff
};
u8
b1
[]
=
{
0
,
0
};
u8
b1
[]
=
{
0
,
0
};
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x71
,
flags
:
0
,
buf
:
b0
,
len
:
2
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x71
,
.
flags
=
0
,
.
buf
=
b0
,
.
len
=
2
},
{
addr
:
0x71
,
flags
:
I2C_M_RD
,
buf
:
b1
,
len
:
2
}
};
{
.
addr
=
0x71
,
.
flags
=
I2C_M_RD
,
.
buf
=
b1
,
.
len
=
2
}
};
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
...
@@ -129,7 +123,7 @@ static
...
@@ -129,7 +123,7 @@ static
int
sp5659_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
int
sp5659_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
{
{
int
ret
;
int
ret
;
struct
i2c_msg
msg
=
{
addr
:
0x60
,
flags
:
0
,
buf
:
data
,
len
:
4
};
struct
i2c_msg
msg
=
{
.
addr
=
0x60
,
.
flags
=
0
,
.
buf
=
data
,
.
len
=
4
};
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
...
@@ -377,7 +371,7 @@ static
...
@@ -377,7 +371,7 @@ static
int
tdlb7_attach
(
struct
dvb_i2c_bus
*
i2c
)
int
tdlb7_attach
(
struct
dvb_i2c_bus
*
i2c
)
{
{
struct
i2c_msg
msg
=
{
addr
:
0x71
,
flags
:
0
,
buf
:
NULL
,
len
:
0
};
struct
i2c_msg
msg
=
{
.
addr
=
0x71
,
.
flags
=
0
,
.
buf
=
NULL
,
.
len
=
0
};
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
...
...
drivers/media/dvb/frontends/alps_tdmb7.c
View file @
c61843a8
...
@@ -33,21 +33,15 @@ static int debug = 0;
...
@@ -33,21 +33,15 @@ static int debug = 0;
static
static
struct
dvb_frontend_info
tdmb7_info
=
{
struct
dvb_frontend_info
tdmb7_info
=
{
name:
"Alps TDMB7"
,
.
name
=
"Alps TDMB7"
,
type:
FE_OFDM
,
.
type
=
FE_OFDM
,
frequency_min:
470000000
,
.
frequency_min
=
470000000
,
frequency_max:
860000000
,
.
frequency_max
=
860000000
,
frequency_stepsize:
166667
,
.
frequency_stepsize
=
166667
,
#if 0
.
caps
=
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
frequency_tolerance: ???,
FE_CAN_FEC_3_4
|
FE_CAN_FEC_5_6
|
symbol_rate_min: ???,
FE_CAN_FEC_7_8
|
FE_CAN_FEC_AUTO
|
symbol_rate_max: ???,
FE_CAN_QPSK
|
FE_CAN_QAM_16
|
FE_CAN_QAM_64
symbol_rate_tolerance: 500, /* ppm */
notifier_delay: 0,
#endif
caps:
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
FE_CAN_FEC_3_4
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_7_8
|
FE_CAN_FEC_AUTO
|
FE_CAN_QPSK
|
FE_CAN_QAM_16
|
FE_CAN_QAM_64
};
};
...
@@ -87,7 +81,7 @@ int cx22700_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
...
@@ -87,7 +81,7 @@ int cx22700_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
{
{
int
ret
;
int
ret
;
u8
buf
[]
=
{
reg
,
data
};
u8
buf
[]
=
{
reg
,
data
};
struct
i2c_msg
msg
=
{
addr
:
0x43
,
flags
:
0
,
buf
:
buf
,
len
:
2
};
struct
i2c_msg
msg
=
{
.
addr
=
0x43
,
.
flags
=
0
,
.
buf
=
buf
,
.
len
=
2
};
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
...
@@ -107,8 +101,8 @@ u8 cx22700_readreg (struct dvb_i2c_bus *i2c, u8 reg)
...
@@ -107,8 +101,8 @@ u8 cx22700_readreg (struct dvb_i2c_bus *i2c, u8 reg)
int
ret
;
int
ret
;
u8
b0
[]
=
{
reg
};
u8
b0
[]
=
{
reg
};
u8
b1
[]
=
{
0
};
u8
b1
[]
=
{
0
};
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x43
,
flags
:
0
,
buf
:
b0
,
len
:
1
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x43
,
.
flags
=
0
,
.
buf
=
b0
,
.
len
=
1
},
{
addr
:
0x43
,
flags
:
I2C_M_RD
,
buf
:
b1
,
len
:
1
}
};
{
.
addr
=
0x43
,
.
flags
=
I2C_M_RD
,
.
buf
=
b1
,
.
len
=
1
}
};
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
...
@@ -124,7 +118,7 @@ u8 cx22700_readreg (struct dvb_i2c_bus *i2c, u8 reg)
...
@@ -124,7 +118,7 @@ u8 cx22700_readreg (struct dvb_i2c_bus *i2c, u8 reg)
static
static
int
pll_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
int
pll_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
{
{
struct
i2c_msg
msg
=
{
addr
:
0x61
,
flags
:
0
,
buf
:
data
,
len
:
4
};
struct
i2c_msg
msg
=
{
.
addr
=
0x61
,
.
flags
=
0
,
.
buf
=
data
,
.
len
=
4
};
int
ret
;
int
ret
;
cx22700_writereg
(
i2c
,
0x0a
,
0x00
);
/* open i2c bus switch */
cx22700_writereg
(
i2c
,
0x0a
,
0x00
);
/* open i2c bus switch */
...
@@ -418,7 +412,7 @@ int tdmb7_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg)
...
@@ -418,7 +412,7 @@ int tdmb7_ioctl (struct dvb_frontend *fe, unsigned int cmd, void *arg)
static
static
int
tdmb7_attach
(
struct
dvb_i2c_bus
*
i2c
)
int
tdmb7_attach
(
struct
dvb_i2c_bus
*
i2c
)
{
{
struct
i2c_msg
msg
=
{
addr
:
0x43
,
flags
:
0
,
buf
:
NULL
,
len
:
0
};
struct
i2c_msg
msg
=
{
.
addr
=
0x43
,
.
flags
=
0
,
.
buf
=
NULL
,
.
len
=
0
};
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
dprintk
(
"%s
\n
"
,
__FUNCTION__
);
...
...
drivers/media/dvb/frontends/grundig_29504-401.c
View file @
c61843a8
...
@@ -34,18 +34,14 @@ static int debug = 0;
...
@@ -34,18 +34,14 @@ static int debug = 0;
struct
dvb_frontend_info
grundig_29504_401_info
=
{
struct
dvb_frontend_info
grundig_29504_401_info
=
{
name:
"Grundig 29504-401"
,
.
name
=
"Grundig 29504-401"
,
type:
FE_OFDM
,
.
type
=
FE_OFDM
,
/* frequency_min: ???,*/
.
frequency_stepsize
=
166666
,
/* frequency_max: ???,*/
.
caps
=
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
frequency_stepsize:
166666
,
FE_CAN_FEC_3_4
|
FE_CAN_FEC_5_6
|
/* frequency_tolerance: ???,*/
FE_CAN_FEC_7_8
|
FE_CAN_QPSK
|
/* symbol_rate_tolerance: ???,*/
FE_CAN_QAM_16
|
FE_CAN_QAM_64
|
notifier_delay:
0
,
FE_CAN_MUTE_TS
caps:
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
FE_CAN_FEC_3_4
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_7_8
|
FE_CAN_QPSK
|
FE_CAN_QAM_16
|
FE_CAN_QAM_64
|
FE_CAN_MUTE_TS
};
};
...
@@ -54,7 +50,7 @@ int l64781_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
...
@@ -54,7 +50,7 @@ int l64781_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
{
{
int
ret
;
int
ret
;
u8
buf
[]
=
{
reg
,
data
};
u8
buf
[]
=
{
reg
,
data
};
struct
i2c_msg
msg
=
{
addr
:
0x55
,
flags
:
0
,
buf
:
buf
,
len
:
2
};
struct
i2c_msg
msg
=
{
.
addr
=
0x55
,
.
flags
=
0
,
.
buf
=
buf
,
.
len
=
2
};
if
((
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
))
!=
1
)
if
((
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
))
!=
1
)
dprintk
(
"%s: write_reg error (reg == %02x) = %02x!
\n
"
,
dprintk
(
"%s: write_reg error (reg == %02x) = %02x!
\n
"
,
...
@@ -70,8 +66,8 @@ u8 l64781_readreg (struct dvb_i2c_bus *i2c, u8 reg)
...
@@ -70,8 +66,8 @@ u8 l64781_readreg (struct dvb_i2c_bus *i2c, u8 reg)
int
ret
;
int
ret
;
u8
b0
[]
=
{
reg
};
u8
b0
[]
=
{
reg
};
u8
b1
[]
=
{
0
};
u8
b1
[]
=
{
0
};
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x55
,
flags
:
0
,
buf
:
b0
,
len
:
1
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x55
,
.
flags
=
0
,
.
buf
=
b0
,
.
len
=
1
},
{
addr
:
0x55
,
flags
:
I2C_M_RD
,
buf
:
b1
,
len
:
1
}
};
{
.
addr
=
0x55
,
.
flags
=
I2C_M_RD
,
.
buf
=
b1
,
.
len
=
1
}
};
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
...
@@ -86,7 +82,7 @@ static
...
@@ -86,7 +82,7 @@ static
int
tsa5060_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
int
tsa5060_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
{
{
int
ret
;
int
ret
;
struct
i2c_msg
msg
=
{
addr
:
0x61
,
flags
:
0
,
buf
:
data
,
len
:
4
};
struct
i2c_msg
msg
=
{
.
addr
=
0x61
,
.
flags
=
0
,
.
buf
=
data
,
.
len
=
4
};
if
((
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
))
!=
1
)
if
((
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
))
!=
1
)
dprintk
(
"%s: write_reg error == %02x!
\n
"
,
__FUNCTION__
,
ret
);
dprintk
(
"%s: write_reg error == %02x!
\n
"
,
__FUNCTION__
,
ret
);
...
@@ -273,7 +269,7 @@ static
...
@@ -273,7 +269,7 @@ static
void
reset_and_configure
(
struct
dvb_i2c_bus
*
i2c
)
void
reset_and_configure
(
struct
dvb_i2c_bus
*
i2c
)
{
{
u8
buf
[]
=
{
0x06
};
u8
buf
[]
=
{
0x06
};
struct
i2c_msg
msg
=
{
addr
:
0x00
,
flags
:
0
,
buf
:
buf
,
len
:
1
};
struct
i2c_msg
msg
=
{
.
addr
=
0x00
,
.
flags
=
0
,
.
buf
=
buf
,
.
len
=
1
};
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
}
}
...
@@ -432,8 +428,8 @@ int l64781_attach (struct dvb_i2c_bus *i2c)
...
@@ -432,8 +428,8 @@ int l64781_attach (struct dvb_i2c_bus *i2c)
{
{
u8
b0
[]
=
{
0x1a
};
u8
b0
[]
=
{
0x1a
};
u8
b1
[]
=
{
0x00
};
u8
b1
[]
=
{
0x00
};
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x55
,
flags
:
0
,
buf
:
b0
,
len
:
1
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x55
,
.
flags
=
0
,
.
buf
=
b0
,
.
len
=
1
},
{
addr
:
0x55
,
flags
:
I2C_M_RD
,
buf
:
b1
,
len
:
1
}
};
{
.
addr
=
0x55
,
.
flags
=
I2C_M_RD
,
.
buf
=
b1
,
.
len
=
1
}
};
if
(
i2c
->
xfer
(
i2c
,
msg
,
2
)
==
2
)
/* probably an EEPROM... */
if
(
i2c
->
xfer
(
i2c
,
msg
,
2
)
==
2
)
/* probably an EEPROM... */
return
-
ENODEV
;
return
-
ENODEV
;
...
...
drivers/media/dvb/frontends/grundig_29504-491.c
View file @
c61843a8
...
@@ -36,22 +36,20 @@ static int debug = 0;
...
@@ -36,22 +36,20 @@ static int debug = 0;
static
static
struct
dvb_frontend_info
grundig_29504_491_info
=
{
struct
dvb_frontend_info
grundig_29504_491_info
=
{
name:
"Grundig 29504-491, (TDA8083 based)"
,
.
name
=
"Grundig 29504-491, (TDA8083 based)"
,
type:
FE_QPSK
,
.
type
=
FE_QPSK
,
frequency_min:
950000
,
/* FIXME: guessed! */
.
frequency_min
=
950000
,
/* FIXME: guessed! */
frequency_max:
1400000
,
/* FIXME: guessed! */
.
frequency_max
=
1400000
,
/* FIXME: guessed! */
frequency_stepsize:
125
,
/* kHz for QPSK frontends */
.
frequency_stepsize
=
125
,
/* kHz for QPSK frontends */
/* frequency_tolerance: ???,*/
.
symbol_rate_min
=
1000000
,
/* FIXME: guessed! */
symbol_rate_min:
1000000
,
/* FIXME: guessed! */
.
symbol_rate_max
=
45000000
,
/* FIXME: guessed! */
symbol_rate_max:
45000000
,
/* FIXME: guessed! */
.
caps
=
FE_CAN_INVERSION_AUTO
|
/* symbol_rate_tolerance: ???,*/
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
notifier_delay:
0
,
FE_CAN_FEC_3_4
|
FE_CAN_FEC_4_5
|
caps:
FE_CAN_INVERSION_AUTO
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_6_7
|
FE_CAN_FEC_1_2
|
FE_CAN_FEC_2_3
|
FE_CAN_FEC_3_4
|
FE_CAN_FEC_7_8
|
FE_CAN_FEC_8_9
|
FE_CAN_FEC_4_5
|
FE_CAN_FEC_5_6
|
FE_CAN_FEC_6_7
|
FE_CAN_FEC_AUTO
|
FE_CAN_QPSK
|
FE_CAN_FEC_7_8
|
FE_CAN_FEC_8_9
|
FE_CAN_FEC_AUTO
|
FE_CAN_MUTE_TS
FE_CAN_QPSK
|
FE_CAN_MUTE_TS
};
};
...
@@ -73,7 +71,7 @@ int tda8083_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
...
@@ -73,7 +71,7 @@ int tda8083_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
{
{
int
ret
;
int
ret
;
u8
buf
[]
=
{
reg
,
data
};
u8
buf
[]
=
{
reg
,
data
};
struct
i2c_msg
msg
=
{
addr
:
0x68
,
flags
:
0
,
buf
:
buf
,
len
:
2
};
struct
i2c_msg
msg
=
{
.
addr
=
0x68
,
.
flags
=
0
,
.
buf
=
buf
,
.
len
=
2
};
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
...
@@ -89,8 +87,8 @@ static
...
@@ -89,8 +87,8 @@ static
int
tda8083_readregs
(
struct
dvb_i2c_bus
*
i2c
,
u8
reg1
,
u8
*
b
,
u8
len
)
int
tda8083_readregs
(
struct
dvb_i2c_bus
*
i2c
,
u8
reg1
,
u8
*
b
,
u8
len
)
{
{
int
ret
;
int
ret
;
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x68
,
flags
:
0
,
buf
:
&
reg1
,
len
:
1
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x68
,
.
flags
=
0
,
.
buf
=
&
reg1
,
.
len
=
1
},
{
addr
:
0x68
,
flags
:
I2C_M_RD
,
buf
:
b
,
len
:
len
}
};
{
.
addr
=
0x68
,
.
flags
=
I2C_M_RD
,
.
buf
=
b
,
.
len
=
len
}
};
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
...
@@ -117,7 +115,7 @@ static
...
@@ -117,7 +115,7 @@ static
int
tsa5522_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
int
tsa5522_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
data
[
4
])
{
{
int
ret
;
int
ret
;
struct
i2c_msg
msg
=
{
addr
:
0x61
,
flags
:
0
,
buf
:
data
,
len
:
4
};
struct
i2c_msg
msg
=
{
.
addr
=
0x61
,
.
flags
=
0
,
.
buf
=
data
,
.
len
=
4
};
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
...
...
drivers/media/dvb/frontends/ves1820.c
View file @
c61843a8
...
@@ -59,20 +59,13 @@ static int debug = 0;
...
@@ -59,20 +59,13 @@ static int debug = 0;
static
static
struct
dvb_frontend_info
ves1820_info
=
{
struct
dvb_frontend_info
ves1820_info
=
{
name:
"VES1820/Grundig tuner as used on the Siemens DVB-C card"
,
.
name
=
"VES1820/Grundig tuner as used on the Siemens DVB-C card"
,
type:
FE_QAM
,
.
type
=
FE_QAM
,
frequency_stepsize:
62500
,
.
frequency_stepsize
=
62500
,
frequency_min:
51000000
,
.
frequency_min
=
51000000
,
frequency_max:
858000000
,
.
frequency_max
=
858000000
,
#if 0
.
caps
=
FE_CAN_QAM_16
|
FE_CAN_QAM_32
|
FE_CAN_QAM_64
|
frequency_tolerance: ???,
FE_CAN_QAM_128
|
FE_CAN_QAM_256
symbol_rate_min: ???,
symbol_rate_max: ???,
symbol_rate_tolerance: ???, /* ppm */ /* == 8% (spec p. 5) */
notifier_delay: ?,
#endif
caps:
FE_CAN_QAM_16
|
FE_CAN_QAM_32
|
FE_CAN_QAM_64
|
FE_CAN_QAM_128
|
FE_CAN_QAM_256
};
};
...
@@ -95,7 +88,7 @@ int ves1820_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
...
@@ -95,7 +88,7 @@ int ves1820_writereg (struct dvb_i2c_bus *i2c, u8 reg, u8 data)
{
{
int
ret
;
int
ret
;
u8
buf
[]
=
{
0x00
,
reg
,
data
};
u8
buf
[]
=
{
0x00
,
reg
,
data
};
struct
i2c_msg
msg
=
{
addr
:
0x09
,
flags
:
0
,
buf
:
buf
,
len
:
3
};
struct
i2c_msg
msg
=
{
.
addr
=
0x09
,
.
flags
=
0
,
.
buf
=
buf
,
.
len
=
3
};
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
...
@@ -115,8 +108,8 @@ u8 ves1820_readreg (struct dvb_i2c_bus *i2c, u8 reg)
...
@@ -115,8 +108,8 @@ u8 ves1820_readreg (struct dvb_i2c_bus *i2c, u8 reg)
int
ret
;
int
ret
;
u8
b0
[]
=
{
0x00
,
reg
};
u8
b0
[]
=
{
0x00
,
reg
};
u8
b1
[]
=
{
0
};
u8
b1
[]
=
{
0
};
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x09
,
flags
:
0
,
buf
:
b0
,
len
:
2
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x09
,
.
flags
=
0
,
.
buf
=
b0
,
.
len
=
2
},
{
addr
:
0x09
,
flags
:
I2C_M_RD
,
buf
:
b1
,
len
:
1
}
};
{
.
addr
=
0x09
,
.
flags
=
I2C_M_RD
,
.
buf
=
b1
,
.
len
=
1
}
};
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
ret
=
i2c
->
xfer
(
i2c
,
msg
,
2
);
...
@@ -132,7 +125,7 @@ static
...
@@ -132,7 +125,7 @@ static
int
tuner_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
addr
,
u8
data
[
4
])
int
tuner_write
(
struct
dvb_i2c_bus
*
i2c
,
u8
addr
,
u8
data
[
4
])
{
{
int
ret
;
int
ret
;
struct
i2c_msg
msg
=
{
addr
:
addr
,
flags
:
0
,
buf
:
data
,
len
:
4
};
struct
i2c_msg
msg
=
{
.
addr
=
addr
,
.
flags
=
0
,
.
buf
=
data
,
.
len
=
4
};
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
ret
=
i2c
->
xfer
(
i2c
,
&
msg
,
1
);
...
@@ -178,7 +171,7 @@ static
...
@@ -178,7 +171,7 @@ static
int
probe_tuner
(
struct
dvb_frontend
*
frontend
)
int
probe_tuner
(
struct
dvb_frontend
*
frontend
)
{
{
struct
dvb_i2c_bus
*
i2c
=
frontend
->
i2c
;
struct
dvb_i2c_bus
*
i2c
=
frontend
->
i2c
;
struct
i2c_msg
msg
=
{
addr
:
0x61
,
flags
:
0
,
buf
:
NULL
,
len
:
0
};
struct
i2c_msg
msg
=
{
.
addr
=
0x61
,
.
flags
=
0
,
.
buf
=
NULL
,
.
len
=
0
};
if
(
i2c
->
xfer
(
i2c
,
&
msg
,
1
)
==
1
)
{
if
(
i2c
->
xfer
(
i2c
,
&
msg
,
1
)
==
1
)
{
SET_TUNER
(
frontend
,
0
);
SET_TUNER
(
frontend
,
0
);
...
@@ -199,8 +192,8 @@ int ves1820_init (struct dvb_frontend *frontend)
...
@@ -199,8 +192,8 @@ int ves1820_init (struct dvb_frontend *frontend)
u8
b0
[]
=
{
0xff
};
u8
b0
[]
=
{
0xff
};
u8
pwm
;
u8
pwm
;
int
i
;
int
i
;
struct
i2c_msg
msg
[]
=
{
{
addr
:
0x50
,
flags
:
0
,
buf
:
b0
,
len
:
1
},
struct
i2c_msg
msg
[]
=
{
{
.
addr
=
0x50
,
.
flags
=
0
,
.
buf
=
b0
,
.
len
=
1
},
{
addr
:
0x50
,
flags
:
I2C_M_RD
,
buf
:
&
pwm
,
len
:
1
}
};
{
.
addr
=
0x50
,
.
flags
=
I2C_M_RD
,
.
buf
=
&
pwm
,
.
len
=
1
}
};
dprintk
(
"VES1820: init chip
\n
"
);
dprintk
(
"VES1820: init chip
\n
"
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment