From patchwork Tue Apr 14 18:47:17 2009 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?b?T2xkw4XihKJpY2ggSmVkbGnDhMKNa2E=?= X-Patchwork-Id: 18205 Received: from vger.kernel.org (vger.kernel.org [209.132.176.167]) by demeter.kernel.org (8.14.2/8.14.2) with ESMTP id n3EIluHv027765 for ; Tue, 14 Apr 2009 18:47:56 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753963AbZDNSrY (ORCPT ); Tue, 14 Apr 2009 14:47:24 -0400 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1755827AbZDNSrX (ORCPT ); Tue, 14 Apr 2009 14:47:23 -0400 Received: from smtp.seznam.cz ([77.75.72.43]:35437 "EHLO smtp.seznam.cz" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755006AbZDNSrV convert rfc822-to-8bit (ORCPT ); Tue, 14 Apr 2009 14:47:21 -0400 DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=beta; d=seznam.cz; h=Received:To:Subject:Content-Disposition:From:Date:MIME-Version:Content-Type:Content-Transfer-Encoding:Message-Id:X-Smtpd:X-Seznam-User:X-QM-Mark; b=gy66HRdR29uAUtw3xzkAiuNvwwsb9x9r273JR4W3rXTKT8fDOdKIBql3JOZm/U6+H d89zjHsgDLKCzakJGZqa58PVjyx1M+AN0bPTC8XYjqYIsUBvXM0Guc4mTOnWhgIsuXK xEHqpw4WkzYRqtaIO5bvaZN7FXotUZs1HQvV2Po= Received: from oldium (ip-89-102-129-2.karneval.cz [89.102.129.2]) by email-relay2.go.seznam.cz (Seznam SMTPD 1.1.7@13984) with ESMTP; Tue, 14 Apr 2009 20:47:19 +0200 (CEST) To: LMML Subject: [PATCH][RESEND] Added support for AVerMedia Cardbus Plus Content-Disposition: inline From: Oldrich Jedlicka Date: Tue, 14 Apr 2009 20:47:17 +0200 MIME-Version: 1.0 Message-Id: <200904142047.17371.oldium.pro@seznam.cz> X-Smtpd: 1.1.7@13984 X-Seznam-User: oldium.pro@seznam.cz X-QM-Mark: email-qm3<188169366> Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org Here comes the full support for AVerMedia Cardbus Plus (E501R) - including remote control. TV, Composite and FM radio tested, I don't have S-Video to test. I've figured out that the radio works only with xtal frequency 13MHz. Now without word-wrapping. Signed-off-by: Oldřich Jedlička --- -- To unsubscribe from this list: send the line "unsubscribe linux-media" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff -r dba0b6fae413 linux/drivers/media/video/saa7134/saa7134.h --- a/linux/drivers/media/video/saa7134/saa7134.h Thu Apr 09 08:21:42 2009 -0300 +++ b/linux/drivers/media/video/saa7134/saa7134.h Mon Apr 13 23:21:53 2009 +0200 @@ -282,6 +282,7 @@ #define SAA7134_BOARD_HAUPPAUGE_HVR1120 155 #define SAA7134_BOARD_HAUPPAUGE_HVR1110R3 156 #define SAA7134_BOARD_AVERMEDIA_STUDIO_507UA 157 +#define SAA7134_BOARD_AVERMEDIA_CARDBUS_501 158 #define SAA7134_MAXBOARDS 32 #define SAA7134_INPUT_MAX 8 diff -r dba0b6fae413 linux/drivers/media/video/saa7134/saa7134-cards.c --- a/linux/drivers/media/video/saa7134/saa7134-cards.c Thu Apr 09 08:21:42 2009 -0300 +++ b/linux/drivers/media/video/saa7134/saa7134-cards.c Mon Apr 13 23:21:53 2009 +0200 @@ -1669,6 +1669,39 @@ .amux = LINE1, }, }, + [SAA7134_BOARD_AVERMEDIA_CARDBUS_501] = { + /* Oldrich Jedlicka */ + .name = "AVerMedia Cardbus TV/Radio (E501R)", + .audio_clock = 0x187de7, + .tuner_type = TUNER_ALPS_TSBE5_PAL, + .radio_type = TUNER_TEA5767, + .tuner_addr = 0x61, + .radio_addr = 0x60, + .tda9887_conf = TDA9887_PRESENT, + .gpiomask = 0x08000000, + .inputs = {{ + .name = name_tv, + .vmux = 1, + .amux = TV, + .tv = 1, + .gpio = 0x08000000, + },{ + .name = name_comp1, + .vmux = 3, + .amux = LINE1, + .gpio = 0x08000000, + },{ + .name = name_svideo, + .vmux = 8, + .amux = LINE1, + .gpio = 0x08000000, + }}, + .radio = { + .name = name_radio, + .amux = LINE2, + .gpio = 0x00000000, + }, + }, [SAA7134_BOARD_CINERGY400_CARDBUS] = { .name = "Terratec Cinergy 400 mobile", .audio_clock = 0x187de7, @@ -5104,6 +5137,13 @@ .subdevice = 0xd6ee, .driver_data = SAA7134_BOARD_AVERMEDIA_CARDBUS, },{ + /* AVerMedia CardBus */ + .vendor = PCI_VENDOR_ID_PHILIPS, + .device = PCI_DEVICE_ID_PHILIPS_SAA7134, + .subvendor = 0x1461, /* Avermedia Technologies Inc */ + .subdevice = 0xb7e9, + .driver_data = SAA7134_BOARD_AVERMEDIA_CARDBUS_501, + },{ /* TransGear 3000TV */ .vendor = PCI_VENDOR_ID_PHILIPS, .device = PCI_DEVICE_ID_PHILIPS_SAA7130, @@ -6341,6 +6381,16 @@ saa_andorl(SAA7134_GPIO_GPSTATUS0 >> 2, 0xffffffff, 0xffffffff); msleep(10); break; + case SAA7134_BOARD_AVERMEDIA_CARDBUS_501: + /* power-down tuner chip */ + saa_andorl(SAA7134_GPIO_GPMODE0 >> 2, 0x08400000, 0x08400000); + saa_andorl(SAA7134_GPIO_GPSTATUS0 >> 2, 0x08400000, 0); + msleep(10); + saa_andorl(SAA7134_GPIO_GPMODE0 >> 2, 0x08400000, 0x08400000); + saa_andorl(SAA7134_GPIO_GPSTATUS0 >> 2, 0x08400000, 0x08400000); + msleep(10); + dev->has_remote = SAA7134_REMOTE_I2C; + break; case SAA7134_BOARD_AVERMEDIA_CARDBUS_506: saa7134_set_gpio(dev, 23, 0); msleep(10); @@ -6782,6 +6832,7 @@ switch (dev->board) { case SAA7134_BOARD_BEHOLD_COLUMBUS_TVFM: + case SAA7134_BOARD_AVERMEDIA_CARDBUS_501: { struct v4l2_priv_tun_config tea5767_cfg; struct tea5767_ctrl ctl;