From patchwork Fri Dec 14 16:19:32 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lee Jones X-Patchwork-Id: 13600 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 3B36B23FB4 for ; Fri, 14 Dec 2012 16:20:11 +0000 (UTC) Received: from mail-ie0-f180.google.com (mail-ie0-f180.google.com [209.85.223.180]) by fiordland.canonical.com (Postfix) with ESMTP id EA25BA195F6 for ; Fri, 14 Dec 2012 16:20:10 +0000 (UTC) Received: by mail-ie0-f180.google.com with SMTP id c10so6158021ieb.11 for ; Fri, 14 Dec 2012 08:20:10 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-forwarded-to:x-forwarded-for:delivered-to:received-spf:from:to:cc :subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=pOVJm6LArcsIzn9eaxy8Cn5d9LEmrOHsr2kbIIqslKc=; b=edFRXIZy2EefOATQxXWiLgn+qRAJfWqAGmf5zMNQcv5k7sMP5RGDZuP/lxe/8vKkt8 iIkj++3ny3naIREdmgJOzdfTL635mMPslyEJ/JvcyTzXQBJeo8I2GJ3uXL9YzKokx8y5 AqRfzRDGQm1L4IcnHlTk7t/K5QEDsEdP8Eq+PGEuM9mwtbvCljEO/ndmT2grgXEVqcQP DLmKE+nN4v9jFdfsh6UUhSI8Lnd8e5T8g9GfEUwCBU/LRiCfcwWeTPadqWI+D+IdNiay H/3cZ/cZ2Tx/vgQ4AzTmkK0wR20TW2RMKnCOXMXvn5cx1WaVY8bnJBxoBu4dO1XL1En7 AjYw== Received: by 10.50.152.137 with SMTP id uy9mr2005216igb.62.1355502010289; Fri, 14 Dec 2012 08:20:10 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.50.67.148 with SMTP id n20csp81603igt; Fri, 14 Dec 2012 08:20:09 -0800 (PST) Received: by 10.194.177.199 with SMTP id cs7mr4451395wjc.41.1355502009205; Fri, 14 Dec 2012 08:20:09 -0800 (PST) Received: from mail-we0-f182.google.com (mail-we0-f182.google.com [74.125.82.182]) by mx.google.com with ESMTPS id p6si15054784wiw.0.2012.12.14.08.20.08 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 14 Dec 2012 08:20:09 -0800 (PST) Received-SPF: neutral (google.com: 74.125.82.182 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) client-ip=74.125.82.182; Authentication-Results: mx.google.com; spf=neutral (google.com: 74.125.82.182 is neither permitted nor denied by best guess record for domain of lee.jones@linaro.org) smtp.mail=lee.jones@linaro.org Received: by mail-we0-f182.google.com with SMTP id u54so1624173wey.27 for ; Fri, 14 Dec 2012 08:20:08 -0800 (PST) Received: by 10.194.88.98 with SMTP id bf2mr4442074wjb.49.1355502008734; Fri, 14 Dec 2012 08:20:08 -0800 (PST) Received: from localhost.localdomain (cpc1-aztw13-0-0-cust473.18-1.cable.virginmedia.com. [77.102.241.218]) by mx.google.com with ESMTPS id u6sm8325248wif.2.2012.12.14.08.20.07 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 14 Dec 2012 08:20:08 -0800 (PST) From: Lee Jones To: linux-kernel@vger.kernel.org Cc: linus.walleij@linaro.org, Lee Jones Subject: [PATCH 14/21] gpio: ab8500: Remove ENUMs from linux/mfd/abx500/ab8500-gpio.h Date: Fri, 14 Dec 2012 16:19:32 +0000 Message-Id: <1355501979-1157-15-git-send-email-lee.jones@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1355501979-1157-1-git-send-email-lee.jones@linaro.org> References: <1355501979-1157-1-git-send-email-lee.jones@linaro.org> X-Gm-Message-State: ALoCoQnHF9yP71CZjVo22zVwv7TCGpUQ9TX4xdE/03AXyYzTXIHUg4JyixWIRKiOS8x2wI2o+wja These are no longer used and will be replaced by a simple macro. Signed-off-by: Lee Jones --- drivers/gpio/gpio-ab8500.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/drivers/gpio/gpio-ab8500.c b/drivers/gpio/gpio-ab8500.c index 200c605..ab6ceac 100644 --- a/drivers/gpio/gpio-ab8500.c +++ b/drivers/gpio/gpio-ab8500.c @@ -585,9 +585,9 @@ static int __devexit ab8500_gpio_remove(struct platform_device *pdev) } int ab8500_config_pulldown(struct device *dev, - enum ab8500_pin gpio, bool enable) + int gpio, bool enable) { - u8 offset = gpio - AB8500_PIN_GPIO1; + u8 offset = gpio - AB8500_PIN_GPIO(1); u8 pos = offset % 8; u8 val = enable ? 0 : 1; u8 reg = AB8500_GPIO_PUD1_REG + (offset / 8); @@ -610,9 +610,9 @@ EXPORT_SYMBOL(ab8500_config_pulldown); * @gpio_select: true if the pin should be used as GPIO */ int ab8500_gpio_config_select(struct device *dev, - enum ab8500_pin gpio, bool gpio_select) + int gpio, bool gpio_select) { - u8 offset = gpio - AB8500_PIN_GPIO1; + u8 offset = gpio - AB8500_PIN_GPIO(1); u8 reg = AB8500_GPIO_SEL1_REG + (offset / 8); u8 pos = offset % 8; u8 val = gpio_select ? 1 : 0; @@ -638,9 +638,9 @@ int ab8500_gpio_config_select(struct device *dev, * @gpio_select: pointer to pin selection status */ int ab8500_gpio_config_get_select(struct device *dev, - enum ab8500_pin gpio, bool *gpio_select) + int gpio, bool *gpio_select) { - u8 offset = gpio - AB8500_PIN_GPIO1; + u8 offset = gpio - AB8500_PIN_GPIO(1); u8 reg = AB8500_GPIO_SEL1_REG + (offset / 8); u8 pos = offset % 8; u8 val;