From patchwork Wed Sep 7 09:24:56 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 75614 Delivered-To: patch@linaro.org Received: by 10.140.106.11 with SMTP id d11csp227888qgf; Wed, 7 Sep 2016 02:25:30 -0700 (PDT) X-Received: by 10.98.51.131 with SMTP id z125mr81028040pfz.109.1473240330015; Wed, 07 Sep 2016 02:25:30 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id z184si8217423pfz.207.2016.09.07.02.25.29; Wed, 07 Sep 2016 02:25:30 -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 S935319AbcIGJZN (ORCPT + 27 others); Wed, 7 Sep 2016 05:25:13 -0400 Received: from mail-wm0-f54.google.com ([74.125.82.54]:36381 "EHLO mail-wm0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932469AbcIGJZK (ORCPT ); Wed, 7 Sep 2016 05:25:10 -0400 Received: by mail-wm0-f54.google.com with SMTP id b187so105326856wme.1 for ; Wed, 07 Sep 2016 02:25:10 -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=pb1SUNpvCSvgdJKdWP3hYg/rkS0JPqi1yU9ZFNewnbM=; b=WN6OZtGKLDcaziX7ojvxkyedF2MB1uHic+092hATfC+y2/uT1pkKLQ/p50wGpiZu3N yBO1+1UZwFD9YpKCNb7mm/84U/Afj3s75783bKhEsbf0ouMc30tHARJy8yoRfXglszNw oD4q2NYqT3rtqMpN3biY0dCZll6dlhMsUslHxh+Wnb3+RW80iIzIN3uVG5qebb6u8c05 8yRfFnPrRikkCHlZaY0c+hsAEYbQHnTankd/OkXxu0hCC/fthfLRtJWJ+UoI3JTOqugJ JI7vVPszMEsPaVPrzOStGyU3oDeDDGhJyMNUq8b3gU6P7fflp6BPl1pVWYignumn2mie ibYQ== 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=pb1SUNpvCSvgdJKdWP3hYg/rkS0JPqi1yU9ZFNewnbM=; b=CM1KuN/DWWXl6U5hk0ugA8nTQM/qBN0wnXpVbMd31kiMqtYjvlLuDKrs3x2F87Kb38 GMjMrMTTVdh7Gsy2fqsX646jjOCh+oXsvp9P3FOtJOM1xaXkO94uBsyMdtM6JRLxfy+L F2aB7ScQka6mvRwQtAqwSLHmBF3lmM5Gu1sWce54actm2UzvuLEzB9oIGgQaEtcBqdSq Db3GYFbkzq8AFHsn7axNiwYrUWSm04a5LbnDjlOJHU2BuuICGJ2gTsMyvBHm5q0QBw5z JYI0YZb3UaB6qT0eVmoW7MXDMLPsJr7qsH+CoL+GxMzFICX4p5SWQaUdlVihOngDTQWz 0wJw== X-Gm-Message-State: AE9vXwPM1lyDDUPxvCAH4J1qeK08OOM42nGfmRuXEieTP9iAnoq+u0LNN85OvJAj1/H1RlZs X-Received: by 10.194.134.101 with SMTP id pj5mr18304071wjb.59.1473240309273; Wed, 07 Sep 2016 02:25:09 -0700 (PDT) Received: from localhost.localdomain ([90.63.244.31]) by smtp.gmail.com with ESMTPSA id xy4sm29697502wjc.2.2016.09.07.02.25.05 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Wed, 07 Sep 2016 02:25:08 -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 v2 4/5] gpio: pca953x: remove an unused variable Date: Wed, 7 Sep 2016 11:24:56 +0200 Message-Id: <1473240297-19881-5-git-send-email-bgolaszewski@baylibre.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1473240297-19881-1-git-send-email-bgolaszewski@baylibre.com> References: <1473240297-19881-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 --- 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 6b62898..00bb2ea 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; const 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);