From: mchehab@infradead.org
To: linux-kernel@vger.kernel.org
Cc: linux-dvb-maintainer@linuxtv.org, video4linux-list@redhat.com,
akpm@osdl.org, Mauro Carvalho Chehab <mchehab@infradead.org>
Subject: [PATCH 05/16] Fixes tvp5150a/am1 detection.
Date: Mon, 23 Jan 2006 18:24:44 -0200 [thread overview]
Message-ID: <20060123202443.PS98910600005@infradead.org> (raw)
In-Reply-To: <20060123202404.PS66974000000@infradead.org>
From: Mauro Carvalho Chehab <mchehab@infradead.org>
- Tvp5150 type were determined by a secondary register instead of
using ROM code.
- tvp5150am1 have ROM=4.0, while tvp5150a have ROM=3.33 (decimal).
All other ROM versions are reported as unknown tvp5150.
- Except for reporting, current code doesn't enable any special feature
for tvp5150am1 or tvp5150a. Code should work for both models (but were
tested only for tvp5150am1).
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>
---
drivers/media/video/tvp5150.c | 21 ++++++++++++---------
1 files changed, 12 insertions(+), 9 deletions(-)
diff --git a/drivers/media/video/tvp5150.c b/drivers/media/video/tvp5150.c
index fad9ea0..a6330a3 100644
--- a/drivers/media/video/tvp5150.c
+++ b/drivers/media/video/tvp5150.c
@@ -746,24 +746,27 @@ static int tvp5150_set_std(struct i2c_cl
static inline void tvp5150_reset(struct i2c_client *c)
{
- u8 type, ver_656, msb_id, lsb_id, msb_rom, lsb_rom;
+ u8 msb_id, lsb_id, msb_rom, lsb_rom;
struct tvp5150 *decoder = i2c_get_clientdata(c);
- type=tvp5150_read(c,TVP5150_AUTOSW_MSK);
msb_id=tvp5150_read(c,TVP5150_MSB_DEV_ID);
lsb_id=tvp5150_read(c,TVP5150_LSB_DEV_ID);
msb_rom=tvp5150_read(c,TVP5150_ROM_MAJOR_VER);
lsb_rom=tvp5150_read(c,TVP5150_ROM_MINOR_VER);
- if (type==0xdc) {
- ver_656=tvp5150_read(c,TVP5150_REV_SELECT);
- tvp5150_info("tvp%02x%02xam1 detected 656 version is %d.\n",msb_id, lsb_id,ver_656);
- } else if (type==0xfc) {
- tvp5150_info("tvp%02x%02xa detected.\n",msb_id, lsb_id);
+ if ((msb_rom==4)&&(lsb_rom==0)) { /* Is TVP5150AM1 */
+ tvp5150_info("tvp%02x%02xam1 detected.\n",msb_id, lsb_id);
+
+ /* ITU-T BT.656.4 timing */
+ tvp5150_write(c,TVP5150_REV_SELECT,0);
} else {
- tvp5150_info("unknown tvp%02x%02x chip detected(%d).\n",msb_id,lsb_id,type);
+ if ((msb_rom==3)||(lsb_rom==0x21)) { /* Is TVP5150A */
+ tvp5150_info("tvp%02x%02xa detected.\n",msb_id, lsb_id);
+ } else {
+ tvp5150_info("*** unknown tvp%02x%02x chip detected.\n",msb_id,lsb_id);
+ tvp5150_info("*** Rom ver is %d.%d\n",msb_rom,lsb_rom);
+ }
}
- tvp5150_info("Rom ver is %d.%d\n",msb_rom,lsb_rom);
/* Initializes TVP5150 to its default values */
tvp5150_write_inittab(c, tvp5150_init_default);
next prev parent reply other threads:[~2006-01-23 20:27 UTC|newest]
Thread overview: 22+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-01-23 20:24 [PATCH 00/16] V4L/DVB updates mchehab
2006-01-23 20:24 ` [PATCH 03/16] Add probe check for the tda9840 mchehab
2006-01-23 20:24 ` [PATCH 04/16] VIDEO_CX88_ALSA must select SND_PCM mchehab
2006-01-23 20:24 ` [PATCH 01/16] Added credits for em28xx-video.c mchehab
2006-01-23 20:24 ` [PATCH 02/16] Add PCI ID for DigitalNow DVB-T Dual, rebranded DViCO FusionHDTV DVB-T Dual mchehab
2006-01-23 20:24 ` [PATCH 09/16] Recognise Hauppauge card #34519 mchehab
2006-01-23 20:24 ` [PATCH 10/16] make VP-3054 Secondary I2C Bus Support a Kconfig option mchehab
2006-01-23 22:16 ` Adrian Bunk
2006-01-23 23:06 ` Mike Krufky
2006-01-24 0:12 ` Adrian Bunk
2006-01-24 2:55 ` [PATCH|BUG-FIX] V4L/DVB: allow tristate build for cx88-vp3054-i2c Michael Krufky
2006-01-26 6:51 ` Mauro Carvalho Chehab
2006-01-23 20:24 ` [PATCH 08/16] rename dvb_pll_tbmv30111in to dvb_pll_samsung_tbmv mchehab
2006-01-23 20:24 ` mchehab [this message]
2006-01-23 20:24 ` [PATCH 07/16] Kill nxt2002 in favor of the nxt200x module mchehab
2006-01-23 20:24 ` [PATCH 14/16] fixed spelling error, exectuted --> executed mchehab
2006-01-23 20:24 ` [PATCH 15/16] Fix printk type warning mchehab
2006-01-23 20:24 ` [PATCH 13/16] Missing break statement on tuner-core mchehab
2006-01-23 20:24 ` [PATCH 12/16] drivers/media/dvb/ possible cleanups mchehab
2006-01-23 20:24 ` [PATCH 11/16] Cause tda9887 to use I2C_DRIVERID_TDA9887 mchehab
2006-01-23 20:24 ` [PATCH 16/16] changed comment in tuner-core.c mchehab
[not found] ` <200601232155.44036.peter.missel@onlinehome.de>
[not found] ` <1138135687.16005.6.camel@localhost.localdomain>
[not found] ` <200601242159.24747.peter.missel@onlinehome.de>
2006-01-25 11:15 ` [PATCH 06/16] Mark Typhoon cards as Lifeview OEM's Mauro Carvalho Chehab
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=20060123202443.PS98910600005@infradead.org \
--to=mchehab@infradead.org \
--cc=akpm@osdl.org \
--cc=linux-dvb-maintainer@linuxtv.org \
--cc=linux-kernel@vger.kernel.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
all inboxes | Powered by JetHome®