From 0912ad0b0fdee374f1f49d75fee341980f0868b6 Mon Sep 17 00:00:00 2001 From: Andrew de Quincey Date: Tue, 8 Aug 2006 09:10:09 -0300 Subject: V4L/DVB (4392): Fix dst_ca attach Move the call to dst_attach into the dst_attach function to eliminate problems caused with dvb_attach. Signed-off-by: Andrew de Quincey Acked-by: Manu Abraham Signed-off-by: Mauro Carvalho Chehab --- drivers/media/dvb/bt8xx/dst.c | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) (limited to 'drivers/media/dvb/bt8xx/dst.c') diff --git a/drivers/media/dvb/bt8xx/dst.c b/drivers/media/dvb/bt8xx/dst.c index a853c14c61d3..52b6fb2455f9 100644 --- a/drivers/media/dvb/bt8xx/dst.c +++ b/drivers/media/dvb/bt8xx/dst.c @@ -1715,12 +1715,6 @@ static int dst_get_frontend(struct dvb_frontend *fe, struct dvb_frontend_paramet static void dst_release(struct dvb_frontend *fe) { struct dst_state *state = fe->demodulator_priv; - -#ifdef CONFIG_DVB_CORE_ATTACH - if (state->dst_hw_cap & DST_TYPE_HAS_CA) - symbol_put(dst_ca_attach); -#endif - kfree(state); } @@ -1758,6 +1752,11 @@ struct dst_state *dst_attach(struct dst_state *state, struct dvb_adapter *dvb_ad } state->frontend.demodulator_priv = state; + /* Attach other DST peripherals if any */ + /* Conditional Access device */ + if (state->dst_hw_cap & DST_TYPE_HAS_CA) + dst_ca_attach(state, dvb_adapter); + return state; /* Manu (DST is a card not a frontend) */ } -- cgit v1.2.1