* [PATCH] regulator: Fix the argument of calling regulator_mode_constrain
@ 2011-04-01 10:25 Axel Lin
2011-04-02 1:03 ` Mark Brown
2011-04-05 9:07 ` Liam Girdwood
0 siblings, 2 replies; 3+ messages in thread
From: Axel Lin @ 2011-04-01 10:25 UTC (permalink / raw)
To: linux-kernel; +Cc: Liam Girdwood, Mark Brown
The second parameter of regulator_mode_constrain takes a pointer.
This patch fixes below warning:
drivers/regulator/core.c: In function 'regulator_set_mode':
drivers/regulator/core.c:2014: warning: passing argument 2 of 'regulator_mode_constrain' makes pointer from integer without a cast
drivers/regulator/core.c:200: note: expected 'int *' but argument is of type 'unsigned int'
Signed-off-by: Axel Lin <axel.lin@gmail.com>
---
drivers/regulator/core.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/drivers/regulator/core.c b/drivers/regulator/core.c
index a634946..fff95c3 100644
--- a/drivers/regulator/core.c
+++ b/drivers/regulator/core.c
@@ -2011,7 +2011,7 @@ int regulator_set_mode(struct regulator *regulator, unsigned int mode)
}
/* constraints check */
- ret = regulator_mode_constrain(rdev, mode);
+ ret = regulator_mode_constrain(rdev, &mode);
if (ret < 0)
goto out;
--
1.7.1
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] regulator: Fix the argument of calling regulator_mode_constrain
2011-04-01 10:25 [PATCH] regulator: Fix the argument of calling regulator_mode_constrain Axel Lin
@ 2011-04-02 1:03 ` Mark Brown
2011-04-05 9:07 ` Liam Girdwood
1 sibling, 0 replies; 3+ messages in thread
From: Mark Brown @ 2011-04-02 1:03 UTC (permalink / raw)
To: Axel Lin; +Cc: linux-kernel, Liam Girdwood
On Fri, Apr 01, 2011 at 06:25:25PM +0800, Axel Lin wrote:
> The second parameter of regulator_mode_constrain takes a pointer.
>
> This patch fixes below warning:
> drivers/regulator/core.c: In function 'regulator_set_mode':
> drivers/regulator/core.c:2014: warning: passing argument 2 of 'regulator_mode_constrain' makes pointer from integer without a cast
> drivers/regulator/core.c:200: note: expected 'int *' but argument is of type 'unsigned int'
Acked-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] regulator: Fix the argument of calling regulator_mode_constrain
2011-04-01 10:25 [PATCH] regulator: Fix the argument of calling regulator_mode_constrain Axel Lin
2011-04-02 1:03 ` Mark Brown
@ 2011-04-05 9:07 ` Liam Girdwood
1 sibling, 0 replies; 3+ messages in thread
From: Liam Girdwood @ 2011-04-05 9:07 UTC (permalink / raw)
To: Axel Lin; +Cc: linux-kernel, Mark Brown
On Fri, 2011-04-01 at 18:25 +0800, Axel Lin wrote:
> The second parameter of regulator_mode_constrain takes a pointer.
>
> This patch fixes below warning:
> drivers/regulator/core.c: In function 'regulator_set_mode':
> drivers/regulator/core.c:2014: warning: passing argument 2 of 'regulator_mode_constrain' makes pointer from integer without a cast
> drivers/regulator/core.c:200: note: expected 'int *' but argument is of type 'unsigned int'
>
> Signed-off-by: Axel Lin <axel.lin@gmail.com>
Applied.
Thanks
Liam
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2011-04-05 9:07 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2011-04-01 10:25 [PATCH] regulator: Fix the argument of calling regulator_mode_constrain Axel Lin
2011-04-02 1:03 ` Mark Brown
2011-04-05 9:07 ` Liam Girdwood
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox