From patchwork Sun Aug 12 21:42:34 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Henrik Rydberg X-Patchwork-Id: 1310371 X-Patchwork-Delegate: jikos@jikos.cz Return-Path: X-Original-To: patchwork-linux-input@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 9C061E0000 for ; Sun, 12 Aug 2012 21:43:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752969Ab2HLVkm (ORCPT ); Sun, 12 Aug 2012 17:40:42 -0400 Received: from smtprelay-b21.telenor.se ([195.54.99.212]:57862 "EHLO smtprelay-b21.telenor.se" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752687Ab2HLVkG (ORCPT ); Sun, 12 Aug 2012 17:40:06 -0400 Received: from ipb2.telenor.se (ipb2.telenor.se [195.54.127.165]) by smtprelay-b21.telenor.se (Postfix) with ESMTP id 08859EBF0D; Sun, 12 Aug 2012 23:40:05 +0200 (CEST) X-SENDER-IP: [85.230.170.20] X-LISTENER: [smtp.bredband.net] X-IronPort-Anti-Spam-Filtered: true X-IronPort-Anti-Spam-Result: Ap1OADciKFBV5qoUPGdsb2JhbABEhRiFI68/GQEBAQE3NIIhAQUnLxMBDxAISTkKFAYBEogRtjoUkS8DmzaNBg X-IronPort-AV: E=Sophos;i="4.77,756,1336341600"; d="scan'208";a="389105767" Received: from c-14aae655.710-13-64736c12.cust.bredbandsbolaget.se (HELO polaris) ([85.230.170.20]) by ipb2.telenor.se with SMTP; 12 Aug 2012 23:40:03 +0200 Received: by polaris (sSMTP sendmail emulation); Sun, 12 Aug 2012 23:43:47 +0200 From: "Henrik Rydberg" To: Dmitry Torokhov , Jiri Kosina Cc: linux-input@vger.kernel.org, linux-kernel@vger.kernel.org, Henrik Rydberg Subject: [PATCH 16/19] HID: hid-multitouch: Remove misleading null test Date: Sun, 12 Aug 2012 23:42:34 +0200 Message-Id: <1344807757-2217-17-git-send-email-rydberg@euromail.se> X-Mailer: git-send-email 1.7.11.4 In-Reply-To: <1344807757-2217-1-git-send-email-rydberg@euromail.se> References: <1344807757-2217-1-git-send-email-rydberg@euromail.se> Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org A null test was left behind during the autoloading work; the test was introduced by 8d179a9e, but was never completely reverted. Reported-by: Dan Carpenter Signed-off-by: Henrik Rydberg Acked-by: Benjamin Tissoires --- drivers/hid/hid-multitouch.c | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/hid/hid-multitouch.c b/drivers/hid/hid-multitouch.c index c400d90..b15133c 100644 --- a/drivers/hid/hid-multitouch.c +++ b/drivers/hid/hid-multitouch.c @@ -691,12 +691,10 @@ static int mt_probe(struct hid_device *hdev, const struct hid_device_id *id) struct mt_device *td; struct mt_class *mtclass = mt_classes; /* MT_CLS_DEFAULT */ - if (id) { - for (i = 0; mt_classes[i].name ; i++) { - if (id->driver_data == mt_classes[i].name) { - mtclass = &(mt_classes[i]); - break; - } + for (i = 0; mt_classes[i].name ; i++) { + if (id->driver_data == mt_classes[i].name) { + mtclass = &(mt_classes[i]); + break; } }