From patchwork Fri Nov 16 06:50:42 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tushar Behera X-Patchwork-Id: 12893 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 E794A23E13 for ; Fri, 16 Nov 2012 06:57:32 +0000 (UTC) Received: from mail-ia0-f180.google.com (mail-ia0-f180.google.com [209.85.210.180]) by fiordland.canonical.com (Postfix) with ESMTP id 4B868A19393 for ; Fri, 16 Nov 2012 06:57:32 +0000 (UTC) Received: by mail-ia0-f180.google.com with SMTP id f6so1430377iag.11 for ; Thu, 15 Nov 2012 22:57:32 -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=He95SfkqB3N1CfQObrfEYYmbhMYWGJmBN/F5vjXlnd0=; b=Vo+FK+X9eDJhi1zdI/bZltWBjS+UDC2fXOdyk0kN+GNK/2YrEOE51W8Ml9U4Y72/it fZ0Qscy0ByeZGJHLAlZYiUKo7fuF2ewN7SPSBPWJoF6wW1BhJVu65W7tyIatJkJh26mT OatrNjnonqsEzXIqUZWtYgLPjnwjeAqdqOTyHjWw+r23q6+9rflioJrHmxc9S4ntTazK TT7axKp6g0UMh4F+3Vj7Ert4fkz6J5d6IacPTOeoKHsnU3mN3qTQa4Ib1gNOy5j1fnML kDbakBYL9wvIaPeE3Kh6CsEQNDKKLGmJWGUkkIwvX+qEYwGMZF+k/VfIOurXmBLESdCH 0L9g== Received: by 10.50.91.195 with SMTP id cg3mr2215259igb.57.1353049052072; Thu, 15 Nov 2012 22:57:32 -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 n20csp23372igt; Thu, 15 Nov 2012 22:57:31 -0800 (PST) Received: by 10.68.230.105 with SMTP id sx9mr12356442pbc.44.1353049051185; Thu, 15 Nov 2012 22:57:31 -0800 (PST) Received: from mail-pa0-f49.google.com (mail-pa0-f49.google.com [209.85.220.49]) by mx.google.com with ESMTPS id bc7si1172632pab.65.2012.11.15.22.57.31 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 15 Nov 2012 22:57:31 -0800 (PST) Received-SPF: neutral (google.com: 209.85.220.49 is neither permitted nor denied by best guess record for domain of tushar.behera@linaro.org) client-ip=209.85.220.49; Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.220.49 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-pa0-f49.google.com with SMTP id bi5so1568801pad.36 for ; Thu, 15 Nov 2012 22:57:31 -0800 (PST) Received: by 10.66.78.169 with SMTP id c9mr10321877pax.30.1353049050961; Thu, 15 Nov 2012 22:57:30 -0800 (PST) Received: from localhost.localdomain ([115.113.119.130]) by mx.google.com with ESMTPS id mz10sm753915pbc.37.2012.11.15.22.57.27 (version=TLSv1/SSLv3 cipher=OTHER); Thu, 15 Nov 2012 22:57:30 -0800 (PST) From: Tushar Behera To: linux-kernel@vger.kernel.org Cc: patches@linaro.org, Chas Williams , linux-atm-general@lists.sourceforge.net, netdev@vger.kernel.org Subject: [PATCH 10/14] atm: Removed redundant check on unsigned variable Date: Fri, 16 Nov 2012 12:20:42 +0530 Message-Id: <1353048646-10935-11-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: ALoCoQkLQyXnV6dyxS23dbvUXzJpL7l/LvobRB3gbMwIUQBOa8QiUh824NxIpQTetgGDmpNmvqC2 No need to check whether unsigned variable is less than 0. CC: Chas Williams CC: linux-atm-general@lists.sourceforge.net CC: netdev@vger.kernel.org Signed-off-by: Tushar Behera Acked-by: chas williams - CONTRACTOR --- drivers/atm/fore200e.c | 2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/drivers/atm/fore200e.c b/drivers/atm/fore200e.c index 361f5ae..fdd3fe7 100644 --- a/drivers/atm/fore200e.c +++ b/drivers/atm/fore200e.c @@ -972,7 +972,7 @@ int bsq_audit(int where, struct host_bsq* bsq, int scheme, int magn) where, scheme, magn, buffer->index, buffer->scheme); } - if ((buffer->index < 0) || (buffer->index >= fore200e_rx_buf_nbr[ scheme ][ magn ])) { + if (buffer->index >= fore200e_rx_buf_nbr[ scheme ][ magn ]) { printk(FORE200E "bsq_audit(%d): queue %d.%d, out of range buffer index = %ld !\n", where, scheme, magn, buffer->index); }