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
nexedi
linux
Commits
6cb393c8
Commit
6cb393c8
authored
Jan 05, 2012
by
Mauro Carvalho Chehab
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
[media] drxk_hard: fix locking issues when changing the delsys
Signed-off-by:
Mauro Carvalho Chehab
<
mchehab@redhat.com
>
parent
fa4b2a17
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
22 deletions
+24
-22
drivers/media/dvb/frontends/drxk_hard.c
drivers/media/dvb/frontends/drxk_hard.c
+24
-21
drivers/media/dvb/frontends/drxk_hard.h
drivers/media/dvb/frontends/drxk_hard.h
+0
-1
No files found.
drivers/media/dvb/frontends/drxk_hard.c
View file @
6cb393c8
...
@@ -6188,7 +6188,6 @@ static int drxk_sleep(struct dvb_frontend *fe)
...
@@ -6188,7 +6188,6 @@ static int drxk_sleep(struct dvb_frontend *fe)
dprintk
(
1
,
"
\n
"
);
dprintk
(
1
,
"
\n
"
);
ShutDown
(
state
);
ShutDown
(
state
);
mutex_unlock
(
&
state
->
ctlock
);
return
0
;
return
0
;
}
}
...
@@ -6203,7 +6202,7 @@ static int drxk_gate_ctrl(struct dvb_frontend *fe, int enable)
...
@@ -6203,7 +6202,7 @@ static int drxk_gate_ctrl(struct dvb_frontend *fe, int enable)
static
int
drxk_set_parameters
(
struct
dvb_frontend
*
fe
)
static
int
drxk_set_parameters
(
struct
dvb_frontend
*
fe
)
{
{
struct
dtv_frontend_properties
*
p
=
&
fe
->
dtv_property_cache
;
struct
dtv_frontend_properties
*
p
=
&
fe
->
dtv_property_cache
;
u32
delsys
=
p
->
delivery_system
;
u32
delsys
=
p
->
delivery_system
,
old_delsys
;
struct
drxk_state
*
state
=
fe
->
demodulator_priv
;
struct
drxk_state
*
state
=
fe
->
demodulator_priv
;
u32
IF
;
u32
IF
;
...
@@ -6221,8 +6220,12 @@ static int drxk_set_parameters(struct dvb_frontend *fe)
...
@@ -6221,8 +6220,12 @@ static int drxk_set_parameters(struct dvb_frontend *fe)
fe
->
ops
.
tuner_ops
.
set_params
(
fe
);
fe
->
ops
.
tuner_ops
.
set_params
(
fe
);
if
(
fe
->
ops
.
i2c_gate_ctrl
)
if
(
fe
->
ops
.
i2c_gate_ctrl
)
fe
->
ops
.
i2c_gate_ctrl
(
fe
,
0
);
fe
->
ops
.
i2c_gate_ctrl
(
fe
,
0
);
old_delsys
=
state
->
props
.
delivery_system
;
state
->
props
=
*
p
;
state
->
props
=
*
p
;
if
(
old_delsys
!=
delsys
)
{
ShutDown
(
state
);
switch
(
delsys
)
{
switch
(
delsys
)
{
case
SYS_DVBC_ANNEX_A
:
case
SYS_DVBC_ANNEX_A
:
case
SYS_DVBC_ANNEX_C
:
case
SYS_DVBC_ANNEX_C
:
...
@@ -6244,6 +6247,7 @@ static int drxk_set_parameters(struct dvb_frontend *fe)
...
@@ -6244,6 +6247,7 @@ static int drxk_set_parameters(struct dvb_frontend *fe)
default:
default:
return
-
EINVAL
;
return
-
EINVAL
;
}
}
}
fe
->
ops
.
tuner_ops
.
get_if_frequency
(
fe
,
&
IF
);
fe
->
ops
.
tuner_ops
.
get_if_frequency
(
fe
,
&
IF
);
Start
(
state
,
0
,
IF
);
Start
(
state
,
0
,
IF
);
...
@@ -6405,7 +6409,6 @@ struct dvb_frontend *drxk_attach(const struct drxk_config *config,
...
@@ -6405,7 +6409,6 @@ struct dvb_frontend *drxk_attach(const struct drxk_config *config,
state
->
m_GPIO
&=
~
state
->
antenna_gpio
;
state
->
m_GPIO
&=
~
state
->
antenna_gpio
;
mutex_init
(
&
state
->
mutex
);
mutex_init
(
&
state
->
mutex
);
mutex_init
(
&
state
->
ctlock
);
memcpy
(
&
state
->
frontend
.
ops
,
&
drxk_ops
,
sizeof
(
drxk_ops
));
memcpy
(
&
state
->
frontend
.
ops
,
&
drxk_ops
,
sizeof
(
drxk_ops
));
state
->
frontend
.
demodulator_priv
=
state
;
state
->
frontend
.
demodulator_priv
=
state
;
...
...
drivers/media/dvb/frontends/drxk_hard.h
View file @
6cb393c8
...
@@ -204,7 +204,6 @@ struct drxk_state {
...
@@ -204,7 +204,6 @@ struct drxk_state {
void
*
priv
;
void
*
priv
;
struct
mutex
mutex
;
struct
mutex
mutex
;
struct
mutex
ctlock
;
u32
m_Instance
;
/**< Channel 1,2,3 or 4 */
u32
m_Instance
;
/**< Channel 1,2,3 or 4 */
...
...
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