From patchwork Thu Sep 8 10:48:22 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Bartosz Golaszewski X-Patchwork-Id: 75762 Delivered-To: patch@linaro.org Received: by 10.140.106.11 with SMTP id d11csp774733qgf; Thu, 8 Sep 2016 03:48:59 -0700 (PDT) X-Received: by 10.98.95.129 with SMTP id t123mr90669055pfb.148.1473331735790; Thu, 08 Sep 2016 03:48:55 -0700 (PDT) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id cc15si46541434pac.249.2016.09.08.03.48.55; Thu, 08 Sep 2016 03:48:55 -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 S941334AbcIHKsw (ORCPT + 27 others); Thu, 8 Sep 2016 06:48:52 -0400 Received: from mail-wm0-f50.google.com ([74.125.82.50]:37687 "EHLO mail-wm0-f50.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1758947AbcIHKsg (ORCPT ); Thu, 8 Sep 2016 06:48:36 -0400 Received: by mail-wm0-f50.google.com with SMTP id w12so81260203wmf.0 for ; Thu, 08 Sep 2016 03:48:35 -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=J2yof6Xi/k7QkLoGqjTI7bfjlTtFpai3nFhv3xKJdx0=; b=Ce1Nv95rfk/rYeUOAJ+hcnV0Xj48d1AYV0RRDkgf9vsULo/xMg0Xv1RPtu++3LRQa4 IDw0WJ+tD8sfdQXU967PQuuxdNIpjktqW3isKTfaQdrMECsWY8+mHQr/a3UB4uBzhy8i 27UwNL3R5HpEkzJnCIYTldH3ean9hhDTjJnpR7fAFO3AAjf7P2zbgSU7dm0JF+J7Mvs6 ouJOO8/ojrZ4qw3b3oNgiwZNRxvKH12QJU0h0dxbJlJtBGk7K/STC69mcGHfDZ6taGL5 sBY98z9ZL9XWpiRAqJgjeiazKc1f8YBE91BWwpCmnrBGE9gLOJmhsy0xgxl0/TFCCfNH TZ3g== 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=J2yof6Xi/k7QkLoGqjTI7bfjlTtFpai3nFhv3xKJdx0=; b=RhhT8hS7ukY3BcpuL6pCsfzkgX4QIENBM4jSNCEEKcn0N9GjvCUqWijs9v7mjabn64 RgIyHdeMv0VNmITdFbYA2eSfWQ8OF1pgwpteeXsk5UxKJp09YYfZx8ukq+VD7YD9p/05 0VwQ2dJSSOOKFI/ITqZ9EIjr4fG3Lo3w11Ot41Gc+b7HiWKydxUrPf3g6PwOSxO2GkP5 QtlX9p2rCgEcIXcWb0xW2rgcJwt0VSXEPWgdPIdisvRMOJIoAWpuMV70HyiqS2ku0ugW 43cobUtpj7+8bzM8fV/P9JkshrVWLTHOeYi+II/OF1ML+WeAVeMY8uNtc7OKfQewVfOL KTNA== X-Gm-Message-State: AE9vXwNe1aB2sgLripAM2+oPTRP27A1nKmeVBARmVN0GNK4NxaiafL7j6SOYS8dII2UfhAW3 X-Received: by 10.28.126.215 with SMTP id z206mr8058107wmc.7.1473331714825; Thu, 08 Sep 2016 03:48:34 -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 t5sm7151832wjm.12.2016.09.08.03.48.33 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 08 Sep 2016 03:48:34 -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 v5 6/6] gpio: pca953x: make the define names consistent Date: Thu, 8 Sep 2016 12:48:22 +0200 Message-Id: <1473331702-26711-7-git-send-email-bgolaszewski@baylibre.com> X-Mailer: git-send-email 2.1.4 In-Reply-To: <1473331702-26711-1-git-send-email-bgolaszewski@baylibre.com> References: <1473331702-26711-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 register offset defines for the pca953x and pca957x expander families should have the same names to better reflect their similar purposes. Signed-off-by: Bartosz Golaszewski --- drivers/gpio/gpio-pca953x.c | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) -- 2.7.4 diff --git a/drivers/gpio/gpio-pca953x.c b/drivers/gpio/gpio-pca953x.c index 71e1344..78ab25e 100644 --- a/drivers/gpio/gpio-pca953x.c +++ b/drivers/gpio/gpio-pca953x.c @@ -29,12 +29,12 @@ #define REG_ADDR_AI 0x80 -#define PCA957X_IN 0 +#define PCA957X_INPUT 0 #define PCA957X_INVRT 1 #define PCA957X_BKEN 2 #define PCA957X_PUPD 3 -#define PCA957X_CFG 4 -#define PCA957X_OUT 5 +#define PCA957X_DIRECTION 4 +#define PCA957X_OUTPUT 5 #define PCA957X_MSK 6 #define PCA957X_INTS 7 @@ -107,9 +107,9 @@ static const struct pca953x_reg_config pca953x_regs = { }; static const struct pca953x_reg_config pca957x_regs = { - .direction = PCA957X_CFG, - .output = PCA957X_OUT, - .input = PCA957X_IN, + .direction = PCA957X_DIRECTION, + .output = PCA957X_OUTPUT, + .input = PCA957X_INPUT, }; struct pca953x_chip { @@ -699,10 +699,10 @@ static int device_pca957x_init(struct pca953x_chip *chip, u32 invert) chip->regs = &pca957x_regs; - ret = pca953x_read_regs(chip, PCA957X_OUT, chip->reg_output); + ret = pca953x_read_regs(chip, PCA957X_OUTPUT, chip->reg_output); if (ret) goto out; - ret = pca953x_read_regs(chip, PCA957X_CFG, chip->reg_direction); + ret = pca953x_read_regs(chip, PCA957X_DIRECTION, chip->reg_direction); if (ret) goto out;