From: Ahmad Fatoum <ahmad@a3f.at>
To: barebox@lists.infradead.org
Cc: Roland Hieber <rhi@pengutronix.de>
Subject: [PATCH v2] regulator: provide regulator_get_name() stub for !CONFIG_REGULATOR
Date: Tue, 15 Sep 2020 11:44:17 +0200 [thread overview]
Message-ID: <20200915094417.957978-1-ahmad@a3f.at> (raw)
Otherwise users of this function run into a link error when regulator
support is compiled out.
Reported-by: Roland Hieber <rhi@pengutronix.de>
Signed-off-by: Ahmad Fatoum <ahmad@a3f.at>
---
Forgot to commit a deleted semicolon..
---
include/regulator.h | 5 +++++
1 file changed, 5 insertions(+)
diff --git a/include/regulator.h b/include/regulator.h
index 12d8e816cdb1..a9cb6dedca5e 100644
--- a/include/regulator.h
+++ b/include/regulator.h
@@ -175,6 +175,11 @@ static inline struct regulator *regulator_get(struct device_d *dev, const char *
return NULL;
}
+static inline struct regulator *regulator_get_name(const char *name)
+{
+ return NULL;
+}
+
static inline int regulator_enable(struct regulator *r)
{
return 0;
--
2.28.0
_______________________________________________
barebox mailing list
barebox@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/barebox
next reply other threads:[~2020-09-15 9:44 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2020-09-15 9:44 Ahmad Fatoum [this message]
2020-09-15 10:22 ` Roland Hieber
2020-09-15 12:35 ` Sascha Hauer
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=20200915094417.957978-1-ahmad@a3f.at \
--to=ahmad@a3f.at \
--cc=barebox@lists.infradead.org \
--cc=rhi@pengutronix.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