From: Vitaly Wool <vital@embeddedalley.com>
To: Mauro Carvalho Chehab <mchehab@infradead.org>
Cc: video4linux-list@redhat.com, em28xx@mcentral.de
Subject: Re: em28xx: Compro VideoMate For You sound problems
Date: Wed, 25 Feb 2009 20:11:48 +0300 [thread overview]
Message-ID: <49A57BD4.6040209@embeddedalley.com> (raw)
In-Reply-To: <20090225101812.212fabbe@caramujo.chehab.org>
Mauro Carvalho Chehab wrote:
>
> IMO, it would be better if you could do a patch with the remaining changes.
after doing the mods you'd suggested I found out that the noise started coming out after the em28xx module loading
stops when em28xx_set_audio_source() is executed. Don't I need to add some tweaks there as well?
The patch is now looking the following way:
diff --git a/drivers/media/video/em28xx/em28xx-cards.c b/drivers/media/video/em28xx/em28xx-cards.c
index 100f90a..f300e74 100644
--- a/drivers/media/video/em28xx/em28xx-cards.c
+++ b/drivers/media/video/em28xx/em28xx-cards.c
@@ -1245,14 +1245,17 @@ struct em28xx_board em28xx_boards[] = {
.tda9887_conf = TDA9887_PRESENT,
.decoder = EM28XX_TVP5150,
.adecoder = EM28XX_TVAUDIO,
+ .tuner_gpio = default_tuner_gpio,
.input = { {
.type = EM28XX_VMUX_TELEVISION,
.vmux = TVP5150_COMPOSITE0,
- .amux = EM28XX_AMUX_LINE_IN,
+ .amux = EM28XX_AMUX_VIDEO,
+ .gpio = default_analog,
}, {
.type = EM28XX_VMUX_SVIDEO,
.vmux = TVP5150_SVIDEO,
.amux = EM28XX_AMUX_LINE_IN,
+ .gpio = default_analog,
} },
},
[EM2860_BOARD_KAIOMY_TVNPC_U2] = {
diff --git a/drivers/media/video/em28xx/em28xx-core.c b/drivers/media/video/em28xx/em28xx-core.c
index eee8d01..b5b2396 100644
--- a/drivers/media/video/em28xx/em28xx-core.c
+++ b/drivers/media/video/em28xx/em28xx-core.c
@@ -354,6 +354,7 @@ static int em28xx_set_audio_source(struct em28xx *dev)
int ret;
u8 input;
+ printk("%s: entered\n", __func__);
if (dev->board.is_em2800) {
if (dev->ctl_ainput == EM28XX_AMUX_VIDEO)
input = EM2800_AUDIO_SRC_TUNER;
diff --git a/drivers/media/video/em28xx/em28xx-i2c.c b/drivers/media/video/em28xx/em28xx-i2c.c
index 2dab43d..02c12fe 100644
--- a/drivers/media/video/em28xx/em28xx-i2c.c
+++ b/drivers/media/video/em28xx/em28xx-i2c.c
@@ -510,12 +510,17 @@ static int attach_inform(struct i2c_client *client)
dprintk1(1, "attach_inform: tvp5150 detected.\n");
break;
+ case 0xb0:
+ dprintk1(1, "attach_inform: tda9874 detected\n");
+ break;
+
default:
if (!dev->tuner_addr)
dev->tuner_addr = client->addr;
dprintk1(1, "attach inform: detected I2C address %x\n",
client->addr << 1);
+ dprintk1(1, "driver id %d\n", client->driver->id);
}
@@ -554,6 +559,7 @@ static char *i2c_devs[128] = {
[0x80 >> 1] = "msp34xx",
[0x88 >> 1] = "msp34xx",
[0xa0 >> 1] = "eeprom",
+ [0xb0 >> 1] = "tda9874",
[0xb8 >> 1] = "tvp5150a",
[0xba >> 1] = "tvp5150a",
[0xc0 >> 1] = "tuner (analog)",
diff --git a/drivers/media/video/em28xx/em28xx-video.c b/drivers/media/video/em28xx/em28xx-video.c
index efd6415..3ce8e95 100644
--- a/drivers/media/video/em28xx/em28xx-video.c
+++ b/drivers/media/video/em28xx/em28xx-video.c
@@ -540,6 +540,13 @@ static void video_mux(struct em28xx *dev, int index)
&route);
}
+ if (dev->board.adecoder != EM28XX_NOADECODER) {
+ route.input = dev->ctl_ainput;
+ route.output = 0;
+ em28xx_i2c_call_clients(dev, VIDIOC_INT_S_AUDIO_ROUTING,
+ &route);
+ }
+
em28xx_audio_analog_set(dev);
}
diff --git a/drivers/media/video/em28xx/em28xx.h b/drivers/media/video/em28xx/em28xx.h
Thanks,
Vitaly
--
video4linux-list mailing list
Unsubscribe mailto:video4linux-list-request@redhat.com?subject=unsubscribe
https://www.redhat.com/mailman/listinfo/video4linux-list
next prev parent reply other threads:[~2009-02-25 17:16 UTC|newest]
Thread overview: 15+ messages / expand[flat|nested] mbox.gz Atom feed top
2009-02-24 7:47 em28xx: Compro VideoMate For You sound problems Vitaly Wool
2009-02-25 2:42 ` Mauro Carvalho Chehab
2009-02-25 12:42 ` Vitaly Wool
2009-02-25 12:07 ` Mauro Carvalho Chehab
2009-02-25 15:46 ` Vitaly Wool
2009-02-25 13:18 ` Mauro Carvalho Chehab
2009-02-25 16:58 ` Vitaly Wool
2009-02-25 17:11 ` Vitaly Wool [this message]
2009-02-25 18:33 ` Mauro Carvalho Chehab
2009-02-25 19:25 ` Vitaly Wool
2009-02-25 23:40 ` Mauro Carvalho Chehab
2009-02-27 15:12 ` Vitaly Wool
2009-02-27 15:43 ` Vitaly Wool
2009-02-28 0:40 ` Mauro Carvalho Chehab
2009-02-28 4:49 ` Vitaly Wool
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=49A57BD4.6040209@embeddedalley.com \
--to=vital@embeddedalley.com \
--cc=em28xx@mcentral.de \
--cc=mchehab@infradead.org \
--cc=video4linux-list@redhat.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox