From patchwork Mon Sep 5 14:31:34 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 75425 Delivered-To: patch@linaro.org Received: by 10.140.106.11 with SMTP id d11csp102023qgf; Mon, 5 Sep 2016 07:32:04 -0700 (PDT) X-Received: by 10.98.35.207 with SMTP id q76mr10608764pfj.42.1473085924209; Mon, 05 Sep 2016 07:32:04 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id k16si10907151pfj.70.2016.09.05.07.32.04; Mon, 05 Sep 2016 07:32:04 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@baylibre-com.20150623.gappssmtp.com; spf=pass (google.com: best guess record for domain of linux-gpio-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-gpio-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755149AbcIEObu (ORCPT + 4 others); Mon, 5 Sep 2016 10:31:50 -0400 Received: from mail-wm0-f47.google.com ([74.125.82.47]:38004 "EHLO mail-wm0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1755062AbcIEObs (ORCPT ); Mon, 5 Sep 2016 10:31:48 -0400 Received: by mail-wm0-f47.google.com with SMTP id 1so142655356wmz.1 for ; Mon, 05 Sep 2016 07:31:47 -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=9i6D9uHztgnm31ZdsGmFjDs1AtFdvcnNQlQ2r72cr4E=; b=c0VAXvsD7ibx5erx4WQYSzNJtxeVNMh3y37l68SvjpPcMtvQ2zaQ9X83XcUQpMSJ14 vo8V7tnLcu3BD9soyacnTfqMJyZuiglIp6S0y71encb8dPz8nDmQndmx1obKAS/s1eYP OXUVIIB3a5JK8VFN1lXMOq0C1+Hi8VnWvcmIiH1ncJbUE/LxfXLYY8OvCiLZEbNueND8 gObWGla8fBcqB7jKTejdZmBnGE2B8YTnwGuXKN5y0FKurVS18a9G5wdNVmfRBZ2+ygTa Z3V/GU0fkgUzDlkDG72jXyhppBC0VDQ6JNAb8K6w1blKiA1RmDn7MvC2tzMrkT7rqL6k X2fQ== 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=9i6D9uHztgnm31ZdsGmFjDs1AtFdvcnNQlQ2r72cr4E=; b=BmyUx6RK8OI3sOwyIrinbsjLYj3xns7FBnV8UL7ERJzk8cLLSVvYbai8fxKOC2rHZg nHFBoDncyCQJZIW83eHbz88yVHIc1a75nji+zqPB+RIK3rIgl26NzpBnYYWBFBgzETzy MlBmxiBtawGxww2hMA2J4IXDlvyo6i0t3PZvR7M0n4w09gyp4tV/q0RdXQd4YPtebm2h HqyyZaQCpS9c8y3CSvDJuYR3PFPJBJRWQruZmhKz+fEkrxNPHiqwiwNC5w0SwoOijwKP 4A/V0IHPLGqKiI0AhT4wzn0klKLfB/P4H2a+9nku7MB+CJmc1GxGgcq+Bs1nCYMxFhRQ QcGA== X-Gm-Message-State: AE9vXwPQ1Y69ItQD66NPLreX4dtEC5an+5in0lg7wTAF39bw1W7dQlEV0h7d4x+HTgespYKk X-Received: by 10.194.143.104 with SMTP id sd8mr30376991wjb.161.1473085906743; Mon, 05 Sep 2016 07:31:46 -0700 (PDT) Received: from localhost.localdomain ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id bc10sm28017507wjc.32.2016.09.05.07.31.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Mon, 05 Sep 2016 07:31:46 -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 4/5] gpio: pca953x: remove an unused variable Date: Mon, 5 Sep 2016 16:31:34 +0200 Message-Id: <1473085895-31711-5-git-send-email-bgolaszewski@baylibre.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1473085895-31711-1-git-send-email-bgolaszewski@baylibre.com> References: <1473085895-31711-1-git-send-email-bgolaszewski@baylibre.com> Sender: linux-gpio-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-gpio@vger.kernel.org The chip_type variable in struct pca953x_chip is no longer required. Remove it. Signed-off-by: Bartosz Golaszewski --- drivers/gpio/gpio-pca953x.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) -- 2.7.4 -- To unsubscribe from this list: send the line "unsubscribe linux-gpio" 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/gpio/gpio-pca953x.c b/drivers/gpio/gpio-pca953x.c index b64a7bb..86676dd 100644 --- a/drivers/gpio/gpio-pca953x.c +++ b/drivers/gpio/gpio-pca953x.c @@ -129,7 +129,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 pca953x_offset *offset; @@ -760,8 +759,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. @@ -774,7 +771,7 @@ static int pca953x_probe(struct i2c_client *client, else if (chip->gpio_chip.ngpio >= 24) chip->write_regs = pca953x_write_regs_24; - 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);