linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] ARM: imx: fix imx31-dt.c time-related warning
@ 2013-01-30  3:56 Stephen Warren
  2013-01-30  6:03 ` Shawn Guo
  2013-02-01  3:55 ` Olof Johansson
  0 siblings, 2 replies; 5+ messages in thread
From: Stephen Warren @ 2013-01-30  3:56 UTC (permalink / raw)
  To: linux-arm-kernel

From: Stephen Warren <swarren@nvidia.com>

Commit 6bb27d7 "ARM: delete struct sys_timer" caused the following:

arch/arm/mach-imx/imx31-dt.c:56:2: warning: initialization from incompatible pointer type [enabled by default]
arch/arm/mach-imx/imx31-dt.c:56:2: warning: (near initialization for ?__mach_desc_IMX31_DT.init_time?) [enabled by default]

This is because mx31_clocks_init_dt() returns int, whereas the .init_time
field prototype expects a function returning void. Implement a wrapper so
that the prototypes match.

Reported-by: Fengguang Wu <fengguang.wu@intel.com>
Signed-off-by: Stephen Warren <swarren@nvidia.com>
---
This patch is based on arm-soc's timer/cleanup branch, which contains
the commit mentioned above.
---
 arch/arm/mach-imx/imx31-dt.c |    7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

diff --git a/arch/arm/mach-imx/imx31-dt.c b/arch/arm/mach-imx/imx31-dt.c
index f9a6909..b5c04ee 100644
--- a/arch/arm/mach-imx/imx31-dt.c
+++ b/arch/arm/mach-imx/imx31-dt.c
@@ -43,12 +43,17 @@ static const char *imx31_dt_board_compat[] __initdata = {
 	NULL
 };
 
+static void __init imx31_dt_timer_init(void)
+{
+	mx31_clocks_init_dt();
+}
+
 DT_MACHINE_START(IMX31_DT, "Freescale i.MX31 (Device Tree Support)")
 	.map_io		= mx31_map_io,
 	.init_early	= imx31_init_early,
 	.init_irq	= mx31_init_irq,
 	.handle_irq	= imx31_handle_irq,
-	.init_time	= mx31_clocks_init_dt,
+	.init_time	= imx31_dt_timer_init,
 	.init_machine	= imx31_dt_init,
 	.dt_compat	= imx31_dt_board_compat,
 	.restart	= mxc_restart,
-- 
1.7.10.4

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

* [PATCH] ARM: imx: fix imx31-dt.c time-related warning
  2013-01-30  3:56 [PATCH] ARM: imx: fix imx31-dt.c time-related warning Stephen Warren
@ 2013-01-30  6:03 ` Shawn Guo
  2013-01-30 16:30   ` Stephen Warren
  2013-02-01  3:55 ` Olof Johansson
  1 sibling, 1 reply; 5+ messages in thread
From: Shawn Guo @ 2013-01-30  6:03 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jan 29, 2013 at 08:56:17PM -0700, Stephen Warren wrote:
> From: Stephen Warren <swarren@nvidia.com>
> 
> Commit 6bb27d7 "ARM: delete struct sys_timer" caused the following:
> 
> arch/arm/mach-imx/imx31-dt.c:56:2: warning: initialization from incompatible pointer type [enabled by default]
> arch/arm/mach-imx/imx31-dt.c:56:2: warning: (near initialization for ?__mach_desc_IMX31_DT.init_time?) [enabled by default]
> 
> This is because mx31_clocks_init_dt() returns int, whereas the .init_time
> field prototype expects a function returning void. Implement a wrapper so
> that the prototypes match.
> 
> Reported-by: Fengguang Wu <fengguang.wu@intel.com>
> Signed-off-by: Stephen Warren <swarren@nvidia.com>

Acked-by: Shawn Guo <shawn.guo@linaro.org>

> ---
> This patch is based on arm-soc's timer/cleanup branch, which contains
> the commit mentioned above.

I suppose that it should just be applied by arm-soc folks on that
branch, right?

Shawn

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

* [PATCH] ARM: imx: fix imx31-dt.c time-related warning
  2013-01-30  6:03 ` Shawn Guo
@ 2013-01-30 16:30   ` Stephen Warren
  2013-01-31  0:24     ` Shawn Guo
  0 siblings, 1 reply; 5+ messages in thread
From: Stephen Warren @ 2013-01-30 16:30 UTC (permalink / raw)
  To: linux-arm-kernel

On 01/29/2013 11:03 PM, Shawn Guo wrote:
> On Tue, Jan 29, 2013 at 08:56:17PM -0700, Stephen Warren wrote:
>> From: Stephen Warren <swarren@nvidia.com>
>>
>> Commit 6bb27d7 "ARM: delete struct sys_timer" caused the following:
>>
>> arch/arm/mach-imx/imx31-dt.c:56:2: warning: initialization from incompatible pointer type [enabled by default]
>> arch/arm/mach-imx/imx31-dt.c:56:2: warning: (near initialization for ?__mach_desc_IMX31_DT.init_time?) [enabled by default]
>>
>> This is because mx31_clocks_init_dt() returns int, whereas the .init_time
>> field prototype expects a function returning void. Implement a wrapper so
>> that the prototypes match.
>>
>> Reported-by: Fengguang Wu <fengguang.wu@intel.com>
>> Signed-off-by: Stephen Warren <swarren@nvidia.com>
> 
> Acked-by: Shawn Guo <shawn.guo@linaro.org>
> 
>> ---
>> This patch is based on arm-soc's timer/cleanup branch, which contains
>> the commit mentioned above.
> 
> I suppose that it should just be applied by arm-soc folks on that
> branch, right?

I wasn't sure if the IMX maintainers had any branch based on the
timer/cleanup branch already. On the off-chance you did, I sent the
patch to you. If you don't, I can resend to the arm-soc maintainers.

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

* [PATCH] ARM: imx: fix imx31-dt.c time-related warning
  2013-01-30 16:30   ` Stephen Warren
@ 2013-01-31  0:24     ` Shawn Guo
  0 siblings, 0 replies; 5+ messages in thread
From: Shawn Guo @ 2013-01-31  0:24 UTC (permalink / raw)
  To: linux-arm-kernel

On Wed, Jan 30, 2013 at 09:30:28AM -0700, Stephen Warren wrote:
> I wasn't sure if the IMX maintainers had any branch based on the
> timer/cleanup branch already. On the off-chance you did, I sent the
> patch to you. If you don't, I can resend to the arm-soc maintainers.

I do not.

Shawn

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

* [PATCH] ARM: imx: fix imx31-dt.c time-related warning
  2013-01-30  3:56 [PATCH] ARM: imx: fix imx31-dt.c time-related warning Stephen Warren
  2013-01-30  6:03 ` Shawn Guo
@ 2013-02-01  3:55 ` Olof Johansson
  1 sibling, 0 replies; 5+ messages in thread
From: Olof Johansson @ 2013-02-01  3:55 UTC (permalink / raw)
  To: linux-arm-kernel

On Tue, Jan 29, 2013 at 08:56:17PM -0700, Stephen Warren wrote:
> From: Stephen Warren <swarren@nvidia.com>
> 
> Commit 6bb27d7 "ARM: delete struct sys_timer" caused the following:
> 
> arch/arm/mach-imx/imx31-dt.c:56:2: warning: initialization from incompatible pointer type [enabled by default]
> arch/arm/mach-imx/imx31-dt.c:56:2: warning: (near initialization for ?__mach_desc_IMX31_DT.init_time?) [enabled by default]
> 
> This is because mx31_clocks_init_dt() returns int, whereas the .init_time
> field prototype expects a function returning void. Implement a wrapper so
> that the prototypes match.
> 
> Reported-by: Fengguang Wu <fengguang.wu@intel.com>
> Signed-off-by: Stephen Warren <swarren@nvidia.com>
> ---
> This patch is based on arm-soc's timer/cleanup branch, which contains
> the commit mentioned above.


Applied.

-Olof

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

end of thread, other threads:[~2013-02-01  3:55 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-01-30  3:56 [PATCH] ARM: imx: fix imx31-dt.c time-related warning Stephen Warren
2013-01-30  6:03 ` Shawn Guo
2013-01-30 16:30   ` Stephen Warren
2013-01-31  0:24     ` Shawn Guo
2013-02-01  3:55 ` Olof Johansson

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).