From: "Paweł Chmiel" <pawel.mikolaj.chmiel@gmail.com>
To: lgirdwood@gmail.com, broonie@kernel.org, sre@kernel.org,
lee.jones@linaro.org, robh+dt@kernel.org, mark.rutland@arm.com
Cc: linux-kernel@vger.kernel.org, linux-pm@vger.kernel.org,
devicetree@vger.kernel.org,
"Paweł Chmiel" <pawel.mikolaj.chmiel@gmail.com>
Subject: [PATCH 1/4] regulator: max8998: Fix platform data retrieval.
Date: Fri, 27 Apr 2018 18:02:59 +0200 [thread overview]
Message-ID: <1524844982-4714-2-git-send-email-pawel.mikolaj.chmiel@gmail.com> (raw)
In-Reply-To: <1524844982-4714-1-git-send-email-pawel.mikolaj.chmiel@gmail.com>
Since the max8998 MFD driver supports instantiation by DT, platform data
retrieval is handled in MFD probe and cell drivers should get use
the pdata field of max8998_dev struct to obtain them.
Fixes: ee999fb3f17f ("mfd: max8998: Add support for Device Tree")
Signed-off-by: Paweł Chmiel <pawel.mikolaj.chmiel@gmail.com>
---
drivers/regulator/max8998.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/regulator/max8998.c b/drivers/regulator/max8998.c
index 3027e7ce100b..6a2b61c012b5 100644
--- a/drivers/regulator/max8998.c
+++ b/drivers/regulator/max8998.c
@@ -309,8 +309,7 @@ static int max8998_set_voltage_buck_sel(struct regulator_dev *rdev,
unsigned selector)
{
struct max8998_data *max8998 = rdev_get_drvdata(rdev);
- struct max8998_platform_data *pdata =
- dev_get_platdata(max8998->iodev->dev);
+ struct max8998_platform_data *pdata = max8998->iodev->pdata;
struct i2c_client *i2c = max8998->iodev->i2c;
int buck = rdev_get_id(rdev);
int reg, shift = 0, mask, ret, j;
--
2.7.4
next prev parent reply other threads:[~2018-04-27 16:07 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-04-27 16:02 [PATCH 0/4] mfd: max8998: Device Tree support fixes Paweł Chmiel
2018-04-27 16:02 ` Paweł Chmiel [this message]
2018-04-27 16:03 ` [PATCH 2/4] power: supply: max8998-charger: Fix platform data retrieval Paweł Chmiel
2018-04-27 16:03 ` [PATCH 3/4] power: supply: max8998-charger: Parse device tree for required data Paweł Chmiel
2018-04-27 16:03 ` [PATCH 4/4] dt-bindings: mfd: max8998: Add charger subnode binding Paweł Chmiel
2018-04-30 12:30 ` Lee Jones
2018-04-30 14:59 ` Paweł Chmiel
2018-05-01 12:45 ` Sebastian Reichel
2018-05-01 14:43 ` Paweł Chmiel
2019-01-10 17:47 ` Sylwester Nawrocki
2019-01-10 20:11 ` Paweł Chmiel
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=1524844982-4714-2-git-send-email-pawel.mikolaj.chmiel@gmail.com \
--to=pawel.mikolaj.chmiel@gmail.com \
--cc=broonie@kernel.org \
--cc=devicetree@vger.kernel.org \
--cc=lee.jones@linaro.org \
--cc=lgirdwood@gmail.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-pm@vger.kernel.org \
--cc=mark.rutland@arm.com \
--cc=robh+dt@kernel.org \
--cc=sre@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;
as well as URLs for NNTP newsgroup(s).