Skip to content

Commit

Permalink
[PATCH] dvb: ttpci: make av7110_fe_lock_fix() retryable
Browse files Browse the repository at this point in the history
av7110_fe_lock_fix() modified in a way that it can be retried after
-ERESTARTSYS

Signed-off-by: Oliver Endriss <[email protected]>
Signed-off-by: Johannes Stezenbach <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Oliver Endriss authored and Linus Torvalds committed Jul 8, 2005
1 parent 7a2fa90 commit 3461215
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions drivers/media/dvb/ttpci/av7110.c
Original file line number Diff line number Diff line change
Expand Up @@ -2038,15 +2038,13 @@ static int av7110_fe_lock_fix(struct av7110* av7110, fe_status_t status)
if (av7110->fe_synced == synced)
return 0;

av7110->fe_synced = synced;

if (av7110->playing)
return 0;

if (down_interruptible(&av7110->pid_mutex))
return -ERESTARTSYS;

if (av7110->fe_synced) {
if (synced) {
ret = SetPIDs(av7110, av7110->pids[DMX_PES_VIDEO],
av7110->pids[DMX_PES_AUDIO],
av7110->pids[DMX_PES_TELETEXT], 0,
Expand All @@ -2062,6 +2060,9 @@ static int av7110_fe_lock_fix(struct av7110* av7110, fe_status_t status)
}
}

if (!ret)
av7110->fe_synced = synced;

up(&av7110->pid_mutex);
return ret;
}
Expand Down

0 comments on commit 3461215

Please sign in to comment.