All of lore.kernel.org
 help / color / mirror / Atom feed
From: Andrey Smirnov <andrew.smirnov@gmail.com>
To: linux-gpio@vger.kernel.org
Cc: Linus Walleij <linus.walleij@linaro.org>,
	Alexandre Courbot <gnurou@gmail.com>,
	Rob Herring <robh+dt@kernel.org>,
	Mark Rutland <mark.rutland@arm.com>,
	devicetree@vger.kernel.org, linux-kernel@vger.kernel.org,
	cphealy@gmail.com, Andrey Smirnov <andrew.smirnov@gmail.com>
Subject: [PATCH v2 08/10] gpio-sx150x: Remove struct sx150x_platform_data
Date: Wed, 19 Oct 2016 07:04:04 -0700	[thread overview]
Message-ID: <1476885846-16469-9-git-send-email-andrew.smirnov@gmail.com> (raw)
In-Reply-To: <1476885846-16469-1-git-send-email-andrew.smirnov@gmail.com>

Remove last vestiges of struct sx150x_platform_data

Signed-off-by: Andrey Smirnov <andrew.smirnov@gmail.com>
---
 drivers/gpio/gpio-sx150x.c | 25 ++++---------------------
 1 file changed, 4 insertions(+), 21 deletions(-)

diff --git a/drivers/gpio/gpio-sx150x.c b/drivers/gpio/gpio-sx150x.c
index 044ff3d..bfb1ec3 100644
--- a/drivers/gpio/gpio-sx150x.c
+++ b/drivers/gpio/gpio-sx150x.c
@@ -84,16 +84,6 @@ struct sx150x_device_data {
 	} pri;
 };
 
-/**
- * struct sx150x_platform_data - config data for SX150x driver
- * @oscio_is_gpo: If set to true, the driver will configure OSCIO as a GPO
- *                instead of as an oscillator, increasing the size of the
- *                GP(I)O pool created by this expander by one.  The
- *                output-only GPO pin will be added at the end of the block.
- */
-struct sx150x_platform_data {
-};
-
 struct sx150x_chip {
 	struct gpio_chip                 gpio_chip;
 	struct i2c_client               *client;
@@ -531,8 +521,7 @@ out:
 
 static void sx150x_init_chip(struct sx150x_chip *chip,
 			struct i2c_client *client,
-			kernel_ulong_t driver_data,
-			struct sx150x_platform_data *pdata)
+			kernel_ulong_t driver_data)
 {
 	mutex_init(&chip->lock);
 
@@ -592,8 +581,7 @@ static int sx150x_reset(struct sx150x_chip *chip)
 	return err;
 }
 
-static int sx150x_init_hw(struct sx150x_chip *chip,
-			struct sx150x_platform_data *pdata)
+static int sx150x_init_hw(struct sx150x_chip *chip)
 {
 	u32 io_pulldown = 0;
 	u32 io_pullup   = 0;
@@ -696,15 +684,10 @@ static int sx150x_probe(struct i2c_client *client,
 {
 	static const u32 i2c_funcs = I2C_FUNC_SMBUS_BYTE_DATA |
 				     I2C_FUNC_SMBUS_WRITE_WORD_DATA;
-	struct sx150x_platform_data *pdata;
 	struct sx150x_chip *chip;
 	int rc;
 	bool oscio_is_gpo;
 
-	pdata = dev_get_platdata(&client->dev);
-	if (!pdata)
-		return -EINVAL;
-
 	if (!i2c_check_functionality(client->adapter, i2c_funcs))
 		return -ENOSYS;
 
@@ -716,12 +699,12 @@ static int sx150x_probe(struct i2c_client *client,
 	oscio_is_gpo = of_property_read_bool(client->dev.of_node,
 					     "semtech,oscio-is-gpo");
 
-	sx150x_init_chip(chip, client, id->driver_data, pdata);
+	sx150x_init_chip(chip, client, id->driver_data);
 
 	if (oscio_is_gpo)
 		chip->gpio_chip.ngpio++;
 
-	rc = sx150x_init_hw(chip, pdata);
+	rc = sx150x_init_hw(chip);
 	if (rc < 0)
 		return rc;
 
-- 
2.5.5

  parent reply	other threads:[~2016-10-19 14:04 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-10-19 14:03 [PATCH v2 00/10] Revamp Semtech SX150x driver Andrey Smirnov
2016-10-19 14:03 ` [PATCH v2 01/10] gpio-sx150x: Remove 'gpio_base' from pdata Andrey Smirnov
2016-10-19 14:03 ` [PATCH v2 02/10] gpio-sx150x: Remove 'irq_summary' parameter Andrey Smirnov
2016-10-19 14:03 ` [PATCH v2 03/10] gpio-sx150x: Remove 'irq_base' parameter Andrey Smirnov
2016-10-19 14:04 ` [PATCH v2 04/10] gpio-sx150x: Replace 'io_polarity' with DT binding Andrey Smirnov
2016-10-19 14:04 ` [PATCH v2 05/10] gpio-sx150x: Replace "io_pull*_ena" with DT bindings Andrey Smirnov
2016-10-19 14:04 ` [PATCH v2 06/10] gpio-sx150x: Replace 'reset_during_probe" with DT binding Andrey Smirnov
2016-10-19 14:04 ` [PATCH v2 07/10] gpio-sx150x: Replace 'oscio_is_gpio' " Andrey Smirnov
2016-10-19 14:04 ` Andrey Smirnov [this message]
2016-10-19 14:04 ` [PATCH v2 09/10] gpio-sx150x: Pass device type in DT match table Andrey Smirnov
2016-10-19 14:04 ` [PATCH v2 10/10] bindings: gpio-sx150x: Document new bindings Andrey Smirnov
     [not found] ` <1476885846-16469-1-git-send-email-andrew.smirnov-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2016-10-20 19:08   ` [PATCH v2 00/10] Revamp Semtech SX150x driver Linus Walleij
2016-10-20 19:08     ` Linus Walleij
2016-10-20 19:34     ` Andrey Smirnov
2016-10-21  9:17       ` Neil Armstrong

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1476885846-16469-9-git-send-email-andrew.smirnov@gmail.com \
    --to=andrew.smirnov@gmail.com \
    --cc=cphealy@gmail.com \
    --cc=devicetree@vger.kernel.org \
    --cc=gnurou@gmail.com \
    --cc=linus.walleij@linaro.org \
    --cc=linux-gpio@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mark.rutland@arm.com \
    --cc=robh+dt@kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.