From patchwork Wed Apr 17 00:42:41 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mauro Carvalho Chehab X-Patchwork-Id: 2451911 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id 4C9EE3FD8C for ; Wed, 17 Apr 2013 00:43:39 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755568Ab3DQAne (ORCPT ); Tue, 16 Apr 2013 20:43:34 -0400 Received: from mx1.redhat.com ([209.132.183.28]:37856 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755484Ab3DQAmy (ORCPT ); Tue, 16 Apr 2013 20:42:54 -0400 Received: from int-mx09.intmail.prod.int.phx2.redhat.com (int-mx09.intmail.prod.int.phx2.redhat.com [10.5.11.22]) by mx1.redhat.com (8.14.4/8.14.4) with ESMTP id r3H0gsXt031256 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK) for ; Tue, 16 Apr 2013 20:42:54 -0400 Received: from pedra (vpn1-7-94.gru2.redhat.com [10.97.7.94]) by int-mx09.intmail.prod.int.phx2.redhat.com (8.14.4/8.14.4) with ESMTP id r3H0gmfv012752 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Tue, 16 Apr 2013 20:42:50 -0400 Received: from v4l by pedra with local (Exim 4.80.1) (envelope-from ) id 1USGSV-0001JF-AV; Tue, 16 Apr 2013 21:42:47 -0300 From: Mauro Carvalho Chehab Cc: Mauro Carvalho Chehab , Linux Media Mailing List Subject: [PATCH v2 30/31] [media] r820t: disable auto gain/VGA setting Date: Tue, 16 Apr 2013 21:42:41 -0300 Message-Id: <1366159362-3773-31-git-send-email-mchehab@redhat.com> In-Reply-To: <1366159362-3773-1-git-send-email-mchehab@redhat.com> References: <1366159362-3773-1-git-send-email-mchehab@redhat.com> X-Scanned-By: MIMEDefang 2.68 on 10.5.11.22 To: unlisted-recipients:; (no To-header on input) Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org On field tests, the auto gain routine is not working, nor it is used by the original driver. Let's comment it for now. Signed-off-by: Mauro Carvalho Chehab --- drivers/media/tuners/r820t.c | 8 +++----- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/media/tuners/r820t.c b/drivers/media/tuners/r820t.c index e63ee94..8d99779 100644 --- a/drivers/media/tuners/r820t.c +++ b/drivers/media/tuners/r820t.c @@ -1163,6 +1163,8 @@ static int r820t_read_gain(struct r820t_priv *priv) return ((data[3] & 0x0f) << 1) + ((data[3] & 0xf0) >> 4); } +#if 0 +/* FIXME: This routine requires more testing */ static int r820t_set_gain_mode(struct r820t_priv *priv, bool set_manual_gain, int gain) @@ -1233,7 +1235,7 @@ static int r820t_set_gain_mode(struct r820t_priv *priv, return 0; } - +#endif static int generic_set_freq(struct dvb_frontend *fe, u32 freq /* in HZ */, @@ -1261,10 +1263,6 @@ static int generic_set_freq(struct dvb_frontend *fe, if (rc < 0) goto err; - rc = r820t_set_gain_mode(priv, false, 0); - if (rc < 0) - goto err; - rc = r820t_set_pll(priv, type, lo_freq); if (rc < 0 || !priv->has_lock) goto err;