V4L/DVB (4688): Fix msp343xG handling (regression from 2.6.16)

The msp3430G and msp3435G models cannot do Automatic Standard Detection.
So these should be forced to BTSC. These chips are early production versions
for the msp34xxG series and are quite rare.
The workaround for kernel 2.6.18 is to use 'standard=32' as msp3400
module option. Due to broken handling of the 'standard' option in 2.6.17 there is
no workaround possible for that kernel.

Signed-off-by: Hans Verkuil <hverkuil@xs4all.nl>
Signed-off-by: Mauro Carvalho Chehab <mchehab@infradead.org>

authored by

Hans Verkuil and committed by
Mauro Carvalho Chehab
de98cdaf 587c03d1

+6 -2
+2
drivers/media/video/msp3400-driver.c
··· 904 904 state->has_virtual_dolby_surround = msp_revision == 'G' && msp_prod_lo == 1; 905 905 /* Has Virtual Dolby Surround & Dolby Pro Logic: only in msp34x2 */ 906 906 state->has_dolby_pro_logic = msp_revision == 'G' && msp_prod_lo == 2; 907 + /* The msp343xG supports BTSC only and cannot do Automatic Standard Detection. */ 908 + state->force_btsc = msp_family == 3 && msp_revision == 'G' && msp_prod_hi == 3; 907 909 908 910 state->opmode = opmode; 909 911 if (state->opmode == OPMODE_AUTO) {
+1
drivers/media/video/msp3400-driver.h
··· 64 64 u8 has_sound_processing; 65 65 u8 has_virtual_dolby_surround; 66 66 u8 has_dolby_pro_logic; 67 + u8 force_btsc; 67 68 68 69 int radio; 69 70 int opmode;
+3 -2
drivers/media/video/msp3400-kthreads.c
··· 960 960 961 961 /* setup the chip*/ 962 962 msp34xxg_reset(client); 963 - state->std = state->radio ? 0x40 : msp_standard; 964 - /* start autodetect */ 963 + state->std = state->radio ? 0x40 : 964 + (state->force_btsc && msp_standard == 1) ? 32 : msp_standard; 965 965 msp_write_dem(client, 0x20, state->std); 966 + /* start autodetect */ 966 967 if (state->std != 1) 967 968 goto unmute; 968 969