This reduces device IDLE power consumption 180mA.

I would like to see solution where tda18271 driver puts chips on
sleep by default and leaves it powered according to driver config
option. Michael declined it, as it could cause regression, and
asked to sleep explicitly after attach.

Cc: Michael Krufky <mkru...@linuxtv.org>
Signed-off-by: Antti Palosaari <cr...@iki.fi>
---
 drivers/media/usb/em28xx/em28xx-dvb.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/drivers/media/usb/em28xx/em28xx-dvb.c 
b/drivers/media/usb/em28xx/em28xx-dvb.c
index c97ffc6..5b7f2b3 100644
--- a/drivers/media/usb/em28xx/em28xx-dvb.c
+++ b/drivers/media/usb/em28xx/em28xx-dvb.c
@@ -1137,6 +1137,16 @@ static int em28xx_dvb_init(struct em28xx *dev)
                                result = -EINVAL;
                                goto out_free;
                        }
+
+                       /*
+                        * We should put tda18271 explicitly sleep in order to
+                        * reduce IDLE power consumption 180mA
+                        */
+                       result = dvb->fe[0]->ops.tuner_ops.sleep(dvb->fe[0]);
+                       if (result) {
+                               dvb_frontend_detach(dvb->fe[0]);
+                               goto out_free;
+                       }
                }
                break;
        case EM2884_BOARD_CINERGY_HTC_STICK:
-- 
1.7.11.4

--
To unsubscribe from this list: send the line "unsubscribe linux-media" in
the body of a message to majord...@vger.kernel.org
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to