Calling NULL callback crash kernel. Check its existence before
call it.
Signed-off-by: Antti Palosaari <[email protected]>
---
drivers/media/dvb-frontends/cxd2843.c | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/drivers/media/dvb-frontends/cxd2843.c
b/drivers/media/dvb-frontends/cxd2843.c
index 10fc240..433d913 100644
--- a/drivers/media/dvb-frontends/cxd2843.c
+++ b/drivers/media/dvb-frontends/cxd2843.c
@@ -1154,7 +1154,8 @@ static int set_parameters(struct dvb_frontend *fe)
state->plp = fe->dtv_property_cache.stream_id & 0xff;
}
/* printk("PLP = %08x, bw = %u\n", state->plp, state->bw); */
- fe->ops.tuner_ops.get_if_frequency(fe, &IF);
+ if (fe->ops.tuner_ops.get_if_frequency)
+ fe->ops.tuner_ops.get_if_frequency(fe, &IF);
stat = Start(state, IF);
return stat;
}
--
http://palosaari.fi/
--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html