summaryrefslogtreecommitdiffstats
path: root/drivers/media/usb/dvb-usb-v2/anysee.c
diff options
context:
space:
mode:
authorAntti Palosaari <crope@iki.fi>2012-09-22 13:46:24 -0300
committerMauro Carvalho Chehab <mchehab@redhat.com>2012-09-27 15:18:24 -0300
commitf6068764573d2f29529c8835126dabe3f2096c1f (patch)
tree8c3ae9a5706f96ddf7e3b218eaef3a4cdf19a57f /drivers/media/usb/dvb-usb-v2/anysee.c
parent36f647bad3d35546892c3639328479355da8690d (diff)
downloadblackbird-obmc-linux-f6068764573d2f29529c8835126dabe3f2096c1f.tar.gz
blackbird-obmc-linux-f6068764573d2f29529c8835126dabe3f2096c1f.zip
[media] anysee: do not remove CI when it is not attached
Signed-off-by: Antti Palosaari <crope@iki.fi> Signed-off-by: Mauro Carvalho Chehab <mchehab@redhat.com>
Diffstat (limited to 'drivers/media/usb/dvb-usb-v2/anysee.c')
-rw-r--r--drivers/media/usb/dvb-usb-v2/anysee.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/media/usb/dvb-usb-v2/anysee.c b/drivers/media/usb/dvb-usb-v2/anysee.c
index 6705d81f0cb2..ec540140c810 100644
--- a/drivers/media/usb/dvb-usb-v2/anysee.c
+++ b/drivers/media/usb/dvb-usb-v2/anysee.c
@@ -1217,6 +1217,8 @@ static int anysee_ci_init(struct dvb_usb_device *d)
if (ret)
return ret;
+ state->ci_attached = true;
+
return 0;
}
@@ -1225,7 +1227,7 @@ static void anysee_ci_release(struct dvb_usb_device *d)
struct anysee_state *state = d_to_priv(d);
/* detach CI */
- if (state->has_ci)
+ if (state->ci_attached)
dvb_ca_en50221_release(&state->ci);
return;
@@ -1257,10 +1259,8 @@ static int anysee_init(struct dvb_usb_device *d)
/* attach CI */
if (state->has_ci) {
ret = anysee_ci_init(d);
- if (ret) {
- state->has_ci = false;
+ if (ret)
return ret;
- }
}
return 0;
OpenPOWER on IntegriCloud