From patchwork Sun Jan 31 13:45:09 2010 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Igor M. Liplianin" X-Patchwork-Id: 75972 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter.kernel.org (8.14.3/8.14.3) with ESMTP id o0VDkJlI029004 for ; Sun, 31 Jan 2010 13:46:19 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753824Ab0AaNqR (ORCPT ); Sun, 31 Jan 2010 08:46:17 -0500 Received: (majordomo@vger.kernel.org) by vger.kernel.org id S1753795Ab0AaNqR (ORCPT ); Sun, 31 Jan 2010 08:46:17 -0500 Received: from mail-bw0-f227.google.com ([209.85.218.227]:52031 "EHLO mail-bw0-f227.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753786Ab0AaNqP (ORCPT ); Sun, 31 Jan 2010 08:46:15 -0500 Received: by bwz27 with SMTP id 27so2430176bwz.21 for ; Sun, 31 Jan 2010 05:46:14 -0800 (PST) Received: by 10.204.35.72 with SMTP id o8mr1117133bkd.68.1264945574151; Sun, 31 Jan 2010 05:46:14 -0800 (PST) Received: from useri.localnet ([212.98.173.132]) by mx.google.com with ESMTPS id 16sm1684168bwz.7.2010.01.31.05.46.11 (version=SSLv3 cipher=RC4-MD5); Sun, 31 Jan 2010 05:46:12 -0800 (PST) From: "Igor M. Liplianin" To: paul10@planar.id.au, "linux-media" , Christian =?iso-8859-1?q?H=FCppe?= Subject: Re: DM1105: could not attach frontend 195d:1105 Date: Sun, 31 Jan 2010 15:45:09 +0200 User-Agent: KMail/1.11.4 (Linux/2.6.33-rc4; KDE/4.2.4; i686; ; ) References: <3bf14d196e3bc8717d910d09a623f98e@mail.velocitynet.com.au> <8f772b00c9ad2033899eeb1913ee42e0@mail.velocitynet.com.au> <52aaba8d0f6ba9e6928ea68d96565bf4@mail.velocitynet.com.au> In-Reply-To: <52aaba8d0f6ba9e6928ea68d96565bf4@mail.velocitynet.com.au> MIME-Version: 1.0 Content-Disposition: inline Message-Id: <201001311545.09620.liplianin@me.by> 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 (demeter.kernel.org [140.211.167.41]); Sun, 31 Jan 2010 13:46:19 +0000 (UTC) diff -r d6520e486ee6 linux/drivers/media/dvb/dm1105/dm1105.c --- a/linux/drivers/media/dvb/dm1105/dm1105.c Sat Jan 30 01:27:34 2010 -0200 +++ b/linux/drivers/media/dvb/dm1105/dm1105.c Sun Jan 31 15:35:30 2010 +0200 @@ -52,6 +52,7 @@ #define DM1105_BOARD_DVBWORLD_2002 1 #define DM1105_BOARD_DVBWORLD_2004 2 #define DM1105_BOARD_AXESS_DM05 3 +#define DM1105_BOARD_UNBRANDED_GPIO15 4 /* ----------------------------------------------- */ /* @@ -207,6 +208,9 @@ [DM1105_BOARD_AXESS_DM05] = { .name = "Axess/EasyTv DM05", }, + [DM1105_BOARD_UNBRANDED_GPIO15] = { + .name = "Unbranded Board GPIO15", + }, }; static const struct dm1105_subid dm1105_subids[] = { @@ -327,6 +331,8 @@ #define dm_setl(reg, bit) dm_andorl((reg), (bit), (bit)) #define dm_clearl(reg, bit) dm_andorl((reg), (bit), 0) +#define DM1105_GPIO(x) (1 << x) + static int dm1105_i2c_xfer(struct i2c_adapter *i2c_adap, struct i2c_msg *msgs, int num) { @@ -441,6 +447,12 @@ u32 lnb_mask, lnb_13v, lnb_18v, lnb_off; switch (dev->boardnr) { + case DM1105_BOARD_UNBRANDED_GPIO15: + lnb_mask = DM05_LNB_MASK; + lnb_off = DM05_LNB_OFF | DM1105_GPIO(15);/* keep GPIO15 high */ + lnb_13v = DM05_LNB_13V | DM1105_GPIO(15); + lnb_18v = DM05_LNB_18V | DM1105_GPIO(15); + break; case DM1105_BOARD_AXESS_DM05: lnb_mask = DM05_LNB_MASK; lnb_off = DM05_LNB_OFF; @@ -758,6 +770,14 @@ dev->fe->ops.set_voltage = dm1105_set_voltage; break; + case DM1105_BOARD_UNBRANDED_GPIO15: + /* reset frontend */ + dm_clearl(DM1105_GPIOCTR, DM1105_GPIO(15)); + dm_clearl(DM1105_GPIOVAL, DM1105_GPIO(15)); + msleep(10); + dm_setl(DM1105_GPIOVAL, DM1105_GPIO(15)); + msleep(100); + /* break omitted intentionally */ case DM1105_BOARD_DVBWORLD_2002: case DM1105_BOARD_AXESS_DM05: default: