From patchwork Fri Aug 10 09:25:03 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dan Carpenter X-Patchwork-Id: 1304661 Return-Path: X-Original-To: patchwork-linux-media@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id B25F1DF215 for ; Fri, 10 Aug 2012 09:25:50 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1758271Ab2HJJZr (ORCPT ); Fri, 10 Aug 2012 05:25:47 -0400 Received: from rcsinet15.oracle.com ([148.87.113.117]:17655 "EHLO rcsinet15.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758131Ab2HJJZq (ORCPT ); Fri, 10 Aug 2012 05:25:46 -0400 Received: from ucsinet22.oracle.com (ucsinet22.oracle.com [156.151.31.94]) by rcsinet15.oracle.com (Sentrion-MTA-4.2.2/Sentrion-MTA-4.2.2) with ESMTP id q7A9PC7U005348 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=OK); Fri, 10 Aug 2012 09:25:13 GMT Received: from acsmt357.oracle.com (acsmt357.oracle.com [141.146.40.157]) by ucsinet22.oracle.com (8.14.4+Sun/8.14.4) with ESMTP id q7A9PBns017875 (version=TLSv1/SSLv3 cipher=DHE-RSA-AES256-SHA bits=256 verify=NO); Fri, 10 Aug 2012 09:25:11 GMT Received: from abhmt111.oracle.com (abhmt111.oracle.com [141.146.116.63]) by acsmt357.oracle.com (8.12.11.20060308/8.12.11) with ESMTP id q7A9PAZN004959; Fri, 10 Aug 2012 04:25:10 -0500 Received: from elgon.mountain (/41.212.103.53) by default (Oracle Beehive Gateway v4.0) with ESMTP ; Fri, 10 Aug 2012 02:25:10 -0700 Date: Fri, 10 Aug 2012 12:25:03 +0300 From: Dan Carpenter To: Mauro Carvalho Chehab Cc: Antti Palosaari , linux-media@vger.kernel.org, kernel-janitors@vger.kernel.org Subject: [patch] [media] qt1010: signedness bug in qt1010_init_meas1() Message-ID: <20120810092502.GD26875@elgon.mountain> MIME-Version: 1.0 Content-Disposition: inline User-Agent: Mutt/1.5.21 (2010-09-15) X-Source-IP: ucsinet22.oracle.com [156.151.31.94] Sender: linux-media-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-media@vger.kernel.org qt1010_init_meas2() returns zero on success and negative error codes on failure so the return type should be int instead of u8. Signed-off-by: Dan Carpenter Acked-by: Antti Palosaari --- 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 --git a/drivers/media/common/tuners/qt1010.c b/drivers/media/common/tuners/qt1010.c index 2d79b1f..bdc39e1 100644 --- a/drivers/media/common/tuners/qt1010.c +++ b/drivers/media/common/tuners/qt1010.c @@ -288,7 +288,7 @@ static int qt1010_init_meas1(struct qt1010_priv *priv, return qt1010_writereg(priv, 0x1e, 0x00); } -static u8 qt1010_init_meas2(struct qt1010_priv *priv, +static int qt1010_init_meas2(struct qt1010_priv *priv, u8 reg_init_val, u8 *retval) { u8 i, val;