From: Doug Anderson <dianders@chromium.org>
To: Mark Brown <broonie@kernel.org>
Cc: Sonny Rao <sonnyrao@chromium.org>,
Heiko Stuebner <heiko@sntech.de>,
Addy Ke <addy.ke@rock-chips.com>,
Chris Zhong <zyw@rock-chips.com>,
Kever Yang <kever.yang@rock-chips.com>,
linux-arm-kernel@lists.infradead.org,
Doug Anderson <dianders@chromium.org>,
lgirdwood@gmail.com, linux-kernel@vger.kernel.org
Subject: [PATCH] regulator: RK808: Fix uninitialized value
Date: Thu, 21 Aug 2014 17:54:55 -0700 [thread overview]
Message-ID: <1408668895-1108-1-git-send-email-dianders@chromium.org> (raw)
The RK808 regulator driver was putting its config on the stack but not
initting it. That means that you got a semi-random config. Fix this.
Signed-off-by: Doug Anderson <dianders@chromium.org>
---
drivers/regulator/rk808-regulator.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/regulator/rk808-regulator.c b/drivers/regulator/rk808-regulator.c
index 94753fd..4d5041c 100644
--- a/drivers/regulator/rk808-regulator.c
+++ b/drivers/regulator/rk808-regulator.c
@@ -334,7 +334,7 @@ static int rk808_regulator_probe(struct platform_device *pdev)
{
struct rk808 *rk808 = dev_get_drvdata(pdev->dev.parent);
struct rk808_board *pdata;
- struct regulator_config config;
+ struct regulator_config config = {};
struct regulator_dev *rk808_rdev;
struct regulator_init_data *reg_data;
int i = 0;
--
2.1.0.rc2.206.gedb03e5
next reply other threads:[~2014-08-22 0:55 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-08-22 0:54 Doug Anderson [this message]
2014-08-22 2:19 ` Mark Brown
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=1408668895-1108-1-git-send-email-dianders@chromium.org \
--to=dianders@chromium.org \
--cc=addy.ke@rock-chips.com \
--cc=broonie@kernel.org \
--cc=heiko@sntech.de \
--cc=kever.yang@rock-chips.com \
--cc=lgirdwood@gmail.com \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=sonnyrao@chromium.org \
--cc=zyw@rock-chips.com \
/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
all inboxes | Powered by JetHome®