aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMauro Carvalho Chehab <m.chehab@samsung.com>2014-03-04 18:49:07 -0500
committerMauro Carvalho Chehab <m.chehab@samsung.com>2014-03-11 05:56:45 -0400
commit88e4fcda55e07278fcf5f6eea684685ffc0633e2 (patch)
tree1762aad137f8015c31242bf1b01e730aaffb6709
parentba38acb1423aa0bc9cd2b38229452b4056911130 (diff)
[media] em28xx: only enable PCTV 80e led when streaming
Instead of keeping the led always on, use it to indicate when DVB is streaming. Signed-off-by: Mauro Carvalho Chehab <m.chehab@samsung.com>
-rw-r--r--drivers/media/usb/em28xx/em28xx-cards.c15
1 files changed, 13 insertions, 2 deletions
diff --git a/drivers/media/usb/em28xx/em28xx-cards.c b/drivers/media/usb/em28xx/em28xx-cards.c
index 66d9c8798c82..2fb300e882f0 100644
--- a/drivers/media/usb/em28xx/em28xx-cards.c
+++ b/drivers/media/usb/em28xx/em28xx-cards.c
@@ -228,8 +228,8 @@ static struct em28xx_reg_seq terratec_cinergy_USB_XS_FR_digital[] = {
228 7: LED on, active high */ 228 7: LED on, active high */
229static struct em28xx_reg_seq em2874_pctv_80e_digital[] = { 229static struct em28xx_reg_seq em2874_pctv_80e_digital[] = {
230 {EM28XX_R06_I2C_CLK, 0x45, 0xff, 10}, /*400 KHz*/ 230 {EM28XX_R06_I2C_CLK, 0x45, 0xff, 10}, /*400 KHz*/
231 {EM2874_R80_GPIO_P0_CTRL, 0x80, 0xff, 100},/*Demod reset*/ 231 {EM2874_R80_GPIO_P0_CTRL, 0x00, 0xff, 100},/*Demod reset*/
232 {EM2874_R80_GPIO_P0_CTRL, 0xc0, 0xff, 10}, 232 {EM2874_R80_GPIO_P0_CTRL, 0x40, 0xff, 10},
233 { -1, -1, -1, -1}, 233 { -1, -1, -1, -1},
234}; 234};
235 235
@@ -526,6 +526,16 @@ static struct em28xx_led kworld_ub435q_v3_leds[] = {
526 {-1, 0, 0, 0}, 526 {-1, 0, 0, 0},
527}; 527};
528 528
529static struct em28xx_led pctv_80e_leds[] = {
530 {
531 .role = EM28XX_LED_DIGITAL_CAPTURING,
532 .gpio_reg = EM2874_R80_GPIO_P0_CTRL,
533 .gpio_mask = 0x80,
534 .inverted = 0,
535 },
536 {-1, 0, 0, 0},
537};
538
529 539
530/* 540/*
531 * Board definitions 541 * Board definitions
@@ -2179,6 +2189,7 @@ struct em28xx_board em28xx_boards[] = {
2179 .dvb_gpio = em2874_pctv_80e_digital, 2189 .dvb_gpio = em2874_pctv_80e_digital,
2180 .decoder = EM28XX_NODECODER, 2190 .decoder = EM28XX_NODECODER,
2181 .ir_codes = RC_MAP_PINNACLE_PCTV_HD, 2191 .ir_codes = RC_MAP_PINNACLE_PCTV_HD,
2192 .leds = pctv_80e_leds,
2182 }, 2193 },
2183 /* 1ae7:9003/9004 SpeedLink Vicious And Devine Laplace webcam 2194 /* 1ae7:9003/9004 SpeedLink Vicious And Devine Laplace webcam
2184 * Empia EM2765 + OmniVision OV2640 */ 2195 * Empia EM2765 + OmniVision OV2640 */