[PATCH] dvb: ttpci: error handling fix
Change error handling in av7110_stop_feed() to stop as many filters as possible in case of errors. Signed-off-by: Johannes Stezenbach <js@linuxtv.org> Signed-off-by: Andrew Morton <akpm@osdl.org> Signed-off-by: Linus Torvalds <torvalds@osdl.org>
This commit is contained in:
parent
ce18a22360
commit
12ba05049f
@ -1050,8 +1050,7 @@ static int av7110_stop_feed(struct dvb_demux_feed *feed)
|
|||||||
{
|
{
|
||||||
struct dvb_demux *demux = feed->demux;
|
struct dvb_demux *demux = feed->demux;
|
||||||
struct av7110 *av7110 = demux->priv;
|
struct av7110 *av7110 = demux->priv;
|
||||||
|
int i, rc, ret = 0;
|
||||||
int ret = 0;
|
|
||||||
dprintk(4, "%p\n", av7110);
|
dprintk(4, "%p\n", av7110);
|
||||||
|
|
||||||
if (feed->type == DMX_TYPE_TS) {
|
if (feed->type == DMX_TYPE_TS) {
|
||||||
@ -1072,16 +1071,16 @@ static int av7110_stop_feed(struct dvb_demux_feed *feed)
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (!ret && feed->type == DMX_TYPE_SEC) {
|
if (!ret && feed->type == DMX_TYPE_SEC) {
|
||||||
int i;
|
for (i = 0; i<demux->filternum; i++) {
|
||||||
|
|
||||||
for (i = 0; i<demux->filternum; i++)
|
|
||||||
if (demux->filter[i].state == DMX_STATE_GO &&
|
if (demux->filter[i].state == DMX_STATE_GO &&
|
||||||
demux->filter[i].filter.parent == &feed->feed.sec) {
|
demux->filter[i].filter.parent == &feed->feed.sec) {
|
||||||
demux->filter[i].state = DMX_STATE_READY;
|
demux->filter[i].state = DMX_STATE_READY;
|
||||||
if (demux->dmx.frontend->source != DMX_MEMORY_FE) {
|
if (demux->dmx.frontend->source != DMX_MEMORY_FE) {
|
||||||
ret = StopHWFilter(&demux->filter[i]);
|
rc = StopHWFilter(&demux->filter[i]);
|
||||||
if (ret)
|
if (!ret)
|
||||||
break;
|
ret = rc;
|
||||||
|
/* keep going, stop as many filters as possible */
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user