public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* [PATCH] regulator: core: Add back the const qualifier for ops of struct regulator_desc
@ 2014-08-21  2:11 Axel Lin
  2014-08-21 14:49 ` Mark Brown
  0 siblings, 1 reply; 2+ messages in thread
From: Axel Lin @ 2014-08-21  2:11 UTC (permalink / raw)
  To: Mark Brown, Liam Girdwood; +Cc: linux-kernel@vger.kernel.org

Fix below build warning:
CC [M]  drivers/regulator/hi6421-regulator.o
drivers/regulator/hi6421-regulator.c:356:2: warning: initialization discards 'const' qualifier from pointer target type [enabled by default]

This is a revert of commit 716845ebeb50 ("regulator: core: Fix build error due
to const qualifier for ops"). The build error was fixed by commit 39f5460d7f9c
("regulator: core: add const to regulator_ops and fix build error in mc13892").

Signed-off-by: Axel Lin <axel.lin@ingics.com>
---
 include/linux/regulator/driver.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/include/linux/regulator/driver.h b/include/linux/regulator/driver.h
index 3abda75..efe058f 100644
--- a/include/linux/regulator/driver.h
+++ b/include/linux/regulator/driver.h
@@ -246,7 +246,7 @@ struct regulator_desc {
 	int id;
 	bool continuous_voltage_range;
 	unsigned n_voltages;
-	struct regulator_ops *ops;
+	const struct regulator_ops *ops;
 	int irq;
 	enum regulator_type type;
 	struct module *owner;
-- 
1.9.1




^ permalink raw reply related	[flat|nested] 2+ messages in thread

* Re: [PATCH] regulator: core: Add back the const qualifier for ops of struct regulator_desc
  2014-08-21  2:11 [PATCH] regulator: core: Add back the const qualifier for ops of struct regulator_desc Axel Lin
@ 2014-08-21 14:49 ` Mark Brown
  0 siblings, 0 replies; 2+ messages in thread
From: Mark Brown @ 2014-08-21 14:49 UTC (permalink / raw)
  To: Axel Lin; +Cc: Liam Girdwood, linux-kernel@vger.kernel.org

[-- Attachment #1: Type: text/plain, Size: 293 bytes --]

On Thu, Aug 21, 2014 at 10:11:34AM +0800, Axel Lin wrote:
> Fix below build warning:
> CC [M]  drivers/regulator/hi6421-regulator.o
> drivers/regulator/hi6421-regulator.c:356:2: warning: initialization discards 'const' qualifier from pointer target type [enabled by default]

Applied, thanks.

[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2014-08-21 14:49 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-08-21  2:11 [PATCH] regulator: core: Add back the const qualifier for ops of struct regulator_desc Axel Lin
2014-08-21 14:49 ` Mark Brown

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox