From patchwork Fri Nov 16 06:50:34 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tushar Behera X-Patchwork-Id: 12885 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 6D38423E13 for ; Fri, 16 Nov 2012 06:57:05 +0000 (UTC) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by fiordland.canonical.com (Postfix) with ESMTP id 1E0E7A19CCF for ; Fri, 16 Nov 2012 06:57:05 +0000 (UTC) Received: by mail-ie0-f180.google.com with SMTP id e10so3064408iej.11 for ; Thu, 15 Nov 2012 22:57:04 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=ILgmHfOPT2y1l5wUDgkqiNYf7XhHtIAhLuVXprxP4/g=; b=SxcbzxW24ZKWSOK1ywPGxer1CSyBLJVSR/ufIEq3WY3DeH0MQpDpkCLzFJo8sHtxcA SwsfTSdegrqqLO8PUvu83C5spIQBa3cMDtBkur7j/ulN+2/6PnIZsSMsFyDR/2/6/6mu Kc5Hjsns7S4rBwnKw6JCMEZoGV9toImTDiHhR5RjX2wynmoOppDNW85QQOp6PqzxCk2O RFjFanbhjZEpcxVKKPuoRmqT5UJ2P1rpjSJgpemLIQnLxsynt3Y/jZFNw72sx4+PPZN1 RgSIesS56iGK+NnR/30YXnN4LMM9vj4+HGKwB9NQrY41O7YmojPUqZFX4kyuNbVzW1Hg 99eA== Received: by 10.50.173.34 with SMTP id bh2mr2182603igc.70.1353049024892; Thu, 15 Nov 2012 22:57:04 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.50.67.148 with SMTP id n20csp23326igt; Thu, 15 Nov 2012 22:57:04 -0800 (PST) Received: by 10.68.129.227 with SMTP id nz3mr6377494pbb.111.1353049024427; Thu, 15 Nov 2012 22:57:04 -0800 (PST) Received: from mail-pb0-f54.google.com (mail-pb0-f54.google.com [209.85.160.54]) by mx.google.com with ESMTPS id s9si1172590pav.59.2012.11.15.22.57.04 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 15 Nov 2012 22:57:04 -0800 (PST) Received-SPF: neutral (google.com: 209.85.160.54 is neither permitted nor denied by best guess record for domain of tushar.behera@linaro.org) client-ip=209.85.160.54; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.160.54 is neither permitted nor denied by best guess record for domain of tushar.behera@linaro.org) smtp.mail=tushar.behera@linaro.org Received: by mail-pb0-f54.google.com with SMTP id wz12so1854504pbc.13 for ; Thu, 15 Nov 2012 22:57:04 -0800 (PST) Received: by 10.68.135.101 with SMTP id pr5mr12032711pbb.140.1353049024204; Thu, 15 Nov 2012 22:57:04 -0800 (PST) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id mz10sm753915pbc.37.2012.11.15.22.57.01 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 15 Nov 2012 22:57:03 -0800 (PST) From: Tushar Behera To: linux-kernel@vger.kernel.org Cc: patches@linaro.org, Mauro Carvalho Chehab , linux-media@vger.kernel.org Subject: [PATCH 02/14] [media] meye: Remove redundant check on unsigned variable Date: Fri, 16 Nov 2012 12:20:34 +0530 Message-Id: <1353048646-10935-3-git-send-email-tushar.behera@linaro.org> X-Mailer: git-send-email 1.7.4.1 In-Reply-To: <1353048646-10935-1-git-send-email-tushar.behera@linaro.org> References: <1353048646-10935-1-git-send-email-tushar.behera@linaro.org> X-Gm-Message-State: ALoCoQmlL2UuH2LTL/9cMHKhk9JfdVBHq/SHAEeEmuYRCm0DpsjxOf/EqcaJ8vB780NPNWOUyCmm No need to check whether unsigned variable is less than 0. CC: Mauro Carvalho Chehab CC: linux-media@vger.kernel.org Signed-off-by: Tushar Behera --- drivers/media/pci/meye/meye.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/media/pci/meye/meye.c b/drivers/media/pci/meye/meye.c index e5a76da..ae7d320 100644 --- a/drivers/media/pci/meye/meye.c +++ b/drivers/media/pci/meye/meye.c @@ -1945,7 +1945,7 @@ static struct pci_driver meye_driver = { static int __init meye_init(void) { gbuffers = max(2, min((int)gbuffers, MEYE_MAX_BUFNBRS)); - if (gbufsize < 0 || gbufsize > MEYE_MAX_BUFSIZE) + if (gbufsize > MEYE_MAX_BUFSIZE) gbufsize = MEYE_MAX_BUFSIZE; gbufsize = PAGE_ALIGN(gbufsize); printk(KERN_INFO "meye: using %d buffers with %dk (%dk total) "