public inbox for linux-iio@vger.kernel.org
 help / color / mirror / Atom feed
From: Jonathan Cameron <jic23@kernel.org>
To: linux-iio@vger.kernel.org
Cc: knaack.h@gmx.de, sr@denx.de, Jonathan Cameron <jic23@kernel.org>
Subject: [PATCH 5/6] staging:iio:adc:spear rename iodev -> indio_dev to fit with current convention
Date: Sat,  5 Apr 2014 17:45:14 +0100	[thread overview]
Message-ID: <1396716315-2465-6-git-send-email-jic23@kernel.org> (raw)
In-Reply-To: <1396716315-2465-1-git-send-email-jic23@kernel.org>

How we ended up with indio_dev is a mystery, but we have so in the interests
of consistency, move this driver over to that convention.

Signed-off-by: Jonathan Cameron <jic23@kernel.org>
---
 drivers/staging/iio/adc/spear_adc.c | 30 +++++++++++++++---------------
 1 file changed, 15 insertions(+), 15 deletions(-)

diff --git a/drivers/staging/iio/adc/spear_adc.c b/drivers/staging/iio/adc/spear_adc.c
index 3003e89..52c26a6 100644
--- a/drivers/staging/iio/adc/spear_adc.c
+++ b/drivers/staging/iio/adc/spear_adc.c
@@ -262,17 +262,17 @@ static int spear_adc_probe(struct platform_device *pdev)
 	struct device_node *np = pdev->dev.of_node;
 	struct device *dev = &pdev->dev;
 	struct spear_adc_state *st;
-	struct iio_dev *iodev = NULL;
+	struct iio_dev *indio_dev = NULL;
 	int ret = -ENODEV;
 	int irq;
 
-	iodev = devm_iio_device_alloc(dev, sizeof(struct spear_adc_state));
-	if (!iodev) {
+	indio_dev = devm_iio_device_alloc(dev, sizeof(struct spear_adc_state));
+	if (!indio_dev) {
 		dev_err(dev, "failed allocating iio device\n");
 		return -ENOMEM;
 	}
 
-	st = iio_priv(iodev);
+	st = iio_priv(indio_dev);
 	st->np = np;
 
 	/*
@@ -335,18 +335,18 @@ static int spear_adc_probe(struct platform_device *pdev)
 
 	spear_adc_configure(st);
 
-	platform_set_drvdata(pdev, iodev);
+	platform_set_drvdata(pdev, indio_dev);
 
 	init_completion(&st->completion);
 
-	iodev->name = SPEAR_ADC_MOD_NAME;
-	iodev->dev.parent = dev;
-	iodev->info = &spear_adc_info;
-	iodev->modes = INDIO_DIRECT_MODE;
-	iodev->channels = spear_adc_iio_channels;
-	iodev->num_channels = ARRAY_SIZE(spear_adc_iio_channels);
+	indio_dev->name = SPEAR_ADC_MOD_NAME;
+	indio_dev->dev.parent = dev;
+	indio_dev->info = &spear_adc_info;
+	indio_dev->modes = INDIO_DIRECT_MODE;
+	indio_dev->channels = spear_adc_iio_channels;
+	indio_dev->num_channels = ARRAY_SIZE(spear_adc_iio_channels);
 
-	ret = iio_device_register(iodev);
+	ret = iio_device_register(indio_dev);
 	if (ret)
 		goto errout3;
 
@@ -365,10 +365,10 @@ errout1:
 
 static int spear_adc_remove(struct platform_device *pdev)
 {
-	struct iio_dev *iodev = platform_get_drvdata(pdev);
-	struct spear_adc_state *st = iio_priv(iodev);
+	struct iio_dev *indio_dev = platform_get_drvdata(pdev);
+	struct spear_adc_state *st = iio_priv(indio_dev);
 
-	iio_device_unregister(iodev);
+	iio_device_unregister(indio_dev);
 	clk_disable_unprepare(st->clk);
 	clk_put(st->clk);
 	iounmap(st->adc_base_spear6xx);
-- 
1.9.0


  parent reply	other threads:[~2014-04-05 16:44 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-04-05 16:45 [PATCH V3 0/6] iio: Minor cleanups to spear ADC driver Jonathan Cameron
2014-04-05 16:45 ` [PATCH 1/6] staging:iio:adc:spear adc - prefix defines to avoid namespace clashes Jonathan Cameron
2014-04-06 10:10   ` Hartmut Knaack
2014-04-07 17:56     ` Jonathan Cameron
2014-04-05 16:45 ` [PATCH 2/6] staging:iio:adc:spear_adc drop initialization of unused scan_type Jonathan Cameron
2014-04-06 10:11   ` Hartmut Knaack
2014-04-07 18:06     ` Jonathan Cameron
2014-04-05 16:45 ` [PATCH 3/6] staging:iio:adc:spear_adc use info_mask_shared_by_all for samp freq Jonathan Cameron
2014-04-06 10:11   ` Hartmut Knaack
2014-04-07 18:06     ` Jonathan Cameron
2014-04-05 16:45 ` [PATCH 4/6] staging:iio:adc:spear rename device specific state structure to _state Jonathan Cameron
2014-04-06 10:11   ` Hartmut Knaack
2014-04-07 18:07     ` Jonathan Cameron
2014-04-05 16:45 ` Jonathan Cameron [this message]
2014-04-06 10:11   ` [PATCH 5/6] staging:iio:adc:spear rename iodev -> indio_dev to fit with current convention Hartmut Knaack
2014-04-05 16:45 ` [PATCH 6/6] staging:iio:adc:spear rename spear_read_raw to spear_adc_read_raw Jonathan Cameron
2014-04-06 10:11   ` Hartmut Knaack
2014-04-07 18:11     ` Jonathan Cameron

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=1396716315-2465-6-git-send-email-jic23@kernel.org \
    --to=jic23@kernel.org \
    --cc=knaack.h@gmx.de \
    --cc=linux-iio@vger.kernel.org \
    --cc=sr@denx.de \
    /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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox