From patchwork Fri Sep 9 09:17:37 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 75853 Delivered-To: patch@linaro.org Received: by 10.140.106.11 with SMTP id d11csp243707qgf; Fri, 9 Sep 2016 02:18:12 -0700 (PDT) X-Received: by 10.98.138.201 with SMTP id o70mr4756510pfk.55.1473412691917; Fri, 09 Sep 2016 02:18:11 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 27si3066588pfn.124.2016.09.09.02.18.11; Fri, 09 Sep 2016 02:18:11 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20150623.gappssmtp.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753263AbcIIJSA (ORCPT + 27 others); Fri, 9 Sep 2016 05:18:00 -0400 Received: from mail-wm0-f46.google.com ([74.125.82.46]:35387 "EHLO mail-wm0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753178AbcIIJRz (ORCPT ); Fri, 9 Sep 2016 05:17:55 -0400 Received: by mail-wm0-f46.google.com with SMTP id w12so20512401wmf.0 for ; Fri, 09 Sep 2016 02:17:55 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=kSyunbAlGk6gZTT9bX9DSF6OyfRGis6C9b+qTz6+MOI=; b=zUJpKnXBf4U7rlS3I6fWtPdWTp4Q2zrn2W/hZ+Yte9ZWDyg9W+iMMJosf0DMoNxEF8 YeDJ6zepIBHJCXmgmR02afxfJDuGqEeJc4ZNGMvWBiohsx4c6kiARRU8f1Na7HnVhewm 9y67Ry2yBiZloYwAqjFCoZHsF7ynWNaBr7IES+ubGBLZUox9swCWJcL217gHVNKzEIF2 l74s+Gf1AGvKWsxyvUVdK3+SkvokXcXbM3bxwi9roBUu4tvAGhX6T6axh9KfEDDoRBCH V8NAaLyxXuF+Ys7IRelGvcriGJaMYTuVXXzggaQXItTSCGzG0AZgIMZp4owMu9Ve5m2s uyRQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=kSyunbAlGk6gZTT9bX9DSF6OyfRGis6C9b+qTz6+MOI=; b=PnYWdtKdG4rK47PHCeU0Bqv+aySLeonM1PHEfIuzGyU3tq7mmToZ5UiF4X5S0oVfDS gxnt7oGydAYC7W048z8N6eBDFOXP6te8CZSIpGSByqXp3ty4QatAh//77OvCaEaXAKLc 2sh6aDyvoJuE32DFd48yBFA6xCyWbJMXJs1zQbv+MpeRL9WGm2fNYEniBf2HQVjoUg0H vohrV7RtTT4OqPWowU094n155W0LNHaIUMgj+qchhB/SpNFsHXwrqE8wMvJ7E7T2Appv WwC8CMrrgD1Juip6p8rtTumSjBSu0jn9f/wlD4OLGEL9qJswCOX0YxIMdymSjW8HU/e2 SYxA== X-Gm-Message-State: AE9vXwNpARnxPLitCRiuamcIwjGvBJNki901rC1vyZrPntvC5ixr2ZvoQaYN/r90U425SWsu X-Received: by 10.194.83.193 with SMTP id s1mr2028910wjy.186.1473412674431; Fri, 09 Sep 2016 02:17:54 -0700 (PDT) Received: from bgdev-debian.lan (jua06-1-82-242-157-225.fbx.proxad.net. [82.242.157.225]) by smtp.gmail.com with ESMTPSA id i127sm1716246wmf.4.2016.09.09.02.17.52 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Fri, 09 Sep 2016 02:17:53 -0700 (PDT) From: Bartosz Golaszewski To: Linus Walleij , Alexandre Courbot , Andy Shevchenko , Vignesh R , Yong Li , Geert Uytterhoeven Cc: linux-gpio , LKML , Bartosz Golaszewski Subject: [PATCH v6 4/5] gpio: pca953x: remove an unused variable Date: Fri, 9 Sep 2016 11:17:37 +0200 Message-Id: <1473412658-13120-5-git-send-email-bgolaszewski@baylibre.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1473412658-13120-1-git-send-email-bgolaszewski@baylibre.com> References: <1473412658-13120-1-git-send-email-bgolaszewski@baylibre.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The chip_type variable in struct pca953x_chip is no longer required. Remove it. Signed-off-by: Bartosz Golaszewski Reviewed-by: Andy Shevchenko --- drivers/gpio/gpio-pca953x.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) -- 2.7.4 diff --git a/drivers/gpio/gpio-pca953x.c b/drivers/gpio/gpio-pca953x.c index e7bf3b3..e36a9bf 100644 --- a/drivers/gpio/gpio-pca953x.c +++ b/drivers/gpio/gpio-pca953x.c @@ -130,7 +130,6 @@ struct pca953x_chip { struct i2c_client *client; struct gpio_chip gpio_chip; const char *const *names; - int chip_type; unsigned long driver_data; struct regulator *regulator; @@ -791,8 +790,6 @@ static int pca953x_probe(struct i2c_client *client, } } - chip->chip_type = PCA_CHIP_TYPE(chip->driver_data); - mutex_init(&chip->i2c_lock); /* initialize cached registers from their original values. @@ -814,7 +811,7 @@ static int pca953x_probe(struct i2c_client *client, chip->read_regs = pca953x_read_regs_16; } - if (chip->chip_type == PCA953X_TYPE) + if (PCA_CHIP_TYPE(chip->driver_data) == PCA953X_TYPE) ret = device_pca953x_init(chip, invert); else ret = device_pca957x_init(chip, invert);