Linux IIO development
 help / color / mirror / Atom feed
From: Matt Ranostay <mranostay@gmail.com>
To: linux-iio@vger.kernel.org
Cc: giorgio.nicole@arcor.de, Matt Ranostay <mranostay@gmail.com>,
	Daniel Baluta <daniel.baluta@intel.com>
Subject: [PATCH] iio: adc: ti-ads1015: fix incorrect referencing of ads1015_data pointer
Date: Thu, 28 Jul 2016 15:40:37 -0700	[thread overview]
Message-ID: <1469745637-998-1-git-send-email-mranostay@gmail.com> (raw)

Reported-by: Giorgio <giorgio.nicole@arcor.de>
Cc: Daniel Baluta <daniel.baluta@intel.com>
Signed-off-by: Matt Ranostay <mranostay@gmail.com>
---
 drivers/iio/adc/ti-ads1015.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/drivers/iio/adc/ti-ads1015.c b/drivers/iio/adc/ti-ads1015.c
index 73cbf0b54e54..fe96af6059d5 100644
--- a/drivers/iio/adc/ti-ads1015.c
+++ b/drivers/iio/adc/ti-ads1015.c
@@ -403,7 +403,8 @@ static const struct iio_info ads1015_info = {
 #ifdef CONFIG_OF
 static int ads1015_get_channels_config_of(struct i2c_client *client)
 {
-	struct ads1015_data *data = i2c_get_clientdata(client);
+	struct iio_dev *indio_dev = i2c_get_clientdata(client);
+	struct ads1015_data *data = iio_priv(indio_dev);
 	struct device_node *node;
 
 	if (!client->dev.of_node ||
-- 
2.7.4


             reply	other threads:[~2016-07-28 22:40 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-07-28 22:40 Matt Ranostay [this message]
2016-07-29  6:19 ` [PATCH] iio: adc: ti-ads1015: fix incorrect referencing of ads1015_data pointer Daniel Baluta
2016-07-29  7:39   ` Matt Ranostay
2016-08-16 18:43     ` [PATCH 1/1] iio:ti-ads1015: fix a wrong pointer definition Giorgio Dal Molin
2016-08-21 10:01       ` 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=1469745637-998-1-git-send-email-mranostay@gmail.com \
    --to=mranostay@gmail.com \
    --cc=daniel.baluta@intel.com \
    --cc=giorgio.nicole@arcor.de \
    --cc=linux-iio@vger.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox