From patchwork Mon Dec 6 20:09:53 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Alexey Chernov <4ernov@gmail.com> X-Patchwork-Id: 379742 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter1.kernel.org (8.14.4/8.14.3) with ESMTP id oB6KA1CD024984 for ; Mon, 6 Dec 2010 20:10:02 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1754548Ab0LFUKA (ORCPT ); Mon, 6 Dec 2010 15:10:00 -0500 Received: from mail-ew0-f45.google.com ([209.85.215.45]:37409 "EHLO mail-ew0-f45.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754277Ab0LFUKA (ORCPT ); Mon, 6 Dec 2010 15:10:00 -0500 Received: by ewy10 with SMTP id 10so7414852ewy.4 for ; Mon, 06 Dec 2010 12:09:58 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:received:from:to:subject:date :user-agent:cc:references:in-reply-to:mime-version:content-type :content-transfer-encoding:message-id; bh=sWd96FXftlxGSMH9KDXFF0vn66tYmediocaWe/VhzSo=; b=S5Pi8MdJaQ8js37zQZbfEyAVaUh/8D70Q8j1nlqyjrxBGKyfy6mmJj4PYE/FdbvfyS sFo6BM1aHroxfb/oldCuG8aQ976aoGnCxfQaLPAyV1ITLmluffTHHY2jbbB0Mqpg8n/+ Jgz3blMUrvSm3GYpGeezvyreSVvME2lC65Nbg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=from:to:subject:date:user-agent:cc:references:in-reply-to :mime-version:content-type:content-transfer-encoding:message-id; b=hLZb09OqscWMrPeNCU8bGd55MeV9Yhg5ArGZAa1HN1l4LkHt4IQraLvKUjLaj1G+AR hVqF4QxUzAe4yc+YXSdbys32kiKru61ZGKTMkfytvq0dT4VKtWWzbQT8zlByGH7U4TLK oEpYfMhUq6SBE1WUrwzZET0Yi8Gtp8x0Mm1a8= Received: by 10.14.37.79 with SMTP id x55mr5102562eea.16.1291666198461; Mon, 06 Dec 2010 12:09:58 -0800 (PST) Received: from aclex.localnet ([95.72.234.60]) by mx.google.com with ESMTPS id q58sm5030417eeh.3.2010.12.06.12.09.56 (version=TLSv1/SSLv3 cipher=RC4-MD5); Mon, 06 Dec 2010 12:09:57 -0800 (PST) From: Alexey Chernov <4ernov@gmail.com> To: hermann pitton Subject: Re: [PATCH] support of GoTView PCI-E X5 3D Hybrid in cx23885 Date: Mon, 6 Dec 2010 23:09:53 +0300 User-Agent: KMail/1.13.5 (Linux/2.6.36.1; KDE/4.5.4; x86_64; ; ) Cc: Devin Heitmueller , Steven Toth , linux-media@vger.kernel.org, "Igor M. Liplianin" References: <201011210251.36592.4ernov@gmail.com> <1291641147.6091.45.camel@pc07.localdom.local> In-Reply-To: <1291641147.6091.45.camel@pc07.localdom.local> MIME-Version: 1.0 Message-Id: <201012062309.53870.4ernov@gmail.com> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.3 (demeter1.kernel.org [140.211.167.41]); Mon, 06 Dec 2010 20:10:02 +0000 (UTC) diff -upr v4l-dvb.orig/drivers/media/video/cx23885/cx23885-cards.c v4l-dvb/drivers/media/video/cx23885/cx23885-cards.c --- v4l-dvb.orig/drivers/media/video/cx23885/cx23885-cards.c 2010-12-03 00:16:09.000000000 +0300 +++ v4l-dvb/drivers/media/video/cx23885/cx23885-cards.c 2010-12-06 22:25:56.000000000 +0300 @@ -309,6 +309,26 @@ struct cx23885_board cx23885_boards[] = CX25840_COMPONENT_ON, } }, }, + [CX23885_BOARD_GOTVIEW_X5_3D_HYBRID] = { + .name = "GoTView X5 3D Hybrid", + .tuner_type = TUNER_XC5000, + .tuner_addr = 0x64, + .porta = CX23885_ANALOG_VIDEO, + .portb = CX23885_MPEG_DVB, + .input = {{ + .type = CX23885_VMUX_TELEVISION, + .vmux = CX25840_VIN2_CH1 | + CX25840_VIN5_CH2, + .gpio0 = 0x02, + }, { + .type = CX23885_VMUX_COMPOSITE1, + .vmux = CX23885_VMUX_COMPOSITE1, + }, { + .type = CX23885_VMUX_SVIDEO, + .vmux = CX25840_SVIDEO_LUMA3 | + CX25840_SVIDEO_CHROMA4, + } }, + }, }; const unsigned int cx23885_bcount = ARRAY_SIZE(cx23885_boards); @@ -496,6 +516,10 @@ struct cx23885_subid cx23885_subids[] = .subvendor = 0x107d, .subdevice = 0x6f22, .card = CX23885_BOARD_LEADTEK_WINFAST_PXTV1200, + }, { + .subvendor = 0x5654, + .subdevice = 0x2390, + .card = CX23885_BOARD_GOTVIEW_X5_3D_HYBRID, }, }; const unsigned int cx23885_idcount = ARRAY_SIZE(cx23885_subids); @@ -712,6 +736,10 @@ int cx23885_tuner_callback(void *priv, i else if (port->nr == 2) bitmask = 0x04; break; + case CX23885_BOARD_GOTVIEW_X5_3D_HYBRID: + /* Tuner Reset Command */ + bitmask = 0x02; + break; } if (bitmask) { @@ -967,6 +995,9 @@ void cx23885_gpio_setup(struct cx23885_d /* CX24228 GPIO */ /* Connected to IF / Mux */ break; + case CX23885_BOARD_GOTVIEW_X5_3D_HYBRID: + cx_set(GP0_IO, 0x00010001); /* Bring the part out of reset */ + break; } } @@ -1218,6 +1249,7 @@ void cx23885_card_setup(struct cx23885_d case CX23885_BOARD_HAUPPAUGE_HVR1850: case CX23885_BOARD_COMPRO_VIDEOMATE_E800: case CX23885_BOARD_HAUPPAUGE_HVR1290: + case CX23885_BOARD_GOTVIEW_X5_3D_HYBRID: default: ts2->gen_ctrl_val = 0xc; /* Serial bus + punctured clock */ ts2->ts_clk_en_val = 0x1; /* Enable TS_CLK */ @@ -1245,6 +1277,7 @@ void cx23885_card_setup(struct cx23885_d case CX23885_BOARD_MAGICPRO_PROHDTVE2: case CX23885_BOARD_HAUPPAUGE_HVR1290: case CX23885_BOARD_LEADTEK_WINFAST_PXTV1200: + case CX23885_BOARD_GOTVIEW_X5_3D_HYBRID: dev->sd_cx25840 = v4l2_i2c_new_subdev(&dev->v4l2_dev, &dev->i2c_bus[2].i2c_adap, NULL, "cx25840", 0x88 >> 1, NULL); diff -upr v4l-dvb.orig/drivers/media/video/cx23885/cx23885.h v4l-dvb/drivers/media/video/cx23885/cx23885.h --- v4l-dvb.orig/drivers/media/video/cx23885/cx23885.h 2010-12-03 00:16:09.000000000 +0300 +++ v4l-dvb/drivers/media/video/cx23885/cx23885.h 2010-12-06 22:27:41.000000000 +0300 @@ -84,6 +84,7 @@ #define CX23885_BOARD_HAUPPAUGE_HVR1290 26 #define CX23885_BOARD_MYGICA_X8558PRO 27 #define CX23885_BOARD_LEADTEK_WINFAST_PXTV1200 28 +#define CX23885_BOARD_GOTVIEW_X5_3D_HYBRID 29 #define GPIO_0 0x00000001 #define GPIO_1 0x00000002