linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] mmp: move declaration of mmp_dt_init_timer to common.h
@ 2019-10-17 10:37 Ben Dooks (Codethink)
  2019-10-17 15:51 ` Lubomir Rintel
  0 siblings, 1 reply; 2+ messages in thread
From: Ben Dooks (Codethink) @ 2019-10-17 10:37 UTC (permalink / raw)
  To: linux-kernel; +Cc: Lubomir Rintel, Ben Dooks (Codethink), linux-arm-kernel

The mmp_dt_init_timer() is shared by several files in the
mmp directory, so move the declaration to common.h to
remove the following sparse warning:

arch/arm/mach-mmp/time.c:204:13: warning: symbol 'mmp_dt_init_timer' was not declared. Should it be static?

Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
---
Cc: Lubomir Rintel <lkundrak@v3.sk>
Cc: linux-arm-kernel@lists.infradead.org
---
 arch/arm/mach-mmp/common.h  | 1 +
 arch/arm/mach-mmp/mmp-dt.c  | 2 --
 arch/arm/mach-mmp/mmp2-dt.c | 2 --
 3 files changed, 1 insertion(+), 4 deletions(-)

diff --git a/arch/arm/mach-mmp/common.h b/arch/arm/mach-mmp/common.h
index 483b8b6d3005..5bb6dcf0a8c1 100644
--- a/arch/arm/mach-mmp/common.h
+++ b/arch/arm/mach-mmp/common.h
@@ -3,6 +3,7 @@
 #define ARRAY_AND_SIZE(x)	(x), ARRAY_SIZE(x)
 
 extern void mmp_timer_init(int irq, unsigned long rate);
+extern void __init mmp_dt_init_timer(void);
 
 extern void __init mmp_map_io(void);
 extern void mmp_restart(enum reboot_mode, const char *);
diff --git a/arch/arm/mach-mmp/mmp-dt.c b/arch/arm/mach-mmp/mmp-dt.c
index 35559792d5cc..e205cdaf19bf 100644
--- a/arch/arm/mach-mmp/mmp-dt.c
+++ b/arch/arm/mach-mmp/mmp-dt.c
@@ -15,8 +15,6 @@
 
 #include "common.h"
 
-extern void __init mmp_dt_init_timer(void);
-
 static const char *const pxa168_dt_board_compat[] __initconst = {
 	"mrvl,pxa168-aspenite",
 	NULL,
diff --git a/arch/arm/mach-mmp/mmp2-dt.c b/arch/arm/mach-mmp/mmp2-dt.c
index 305a9daba6d6..ea63203b8810 100644
--- a/arch/arm/mach-mmp/mmp2-dt.c
+++ b/arch/arm/mach-mmp/mmp2-dt.c
@@ -16,8 +16,6 @@
 
 #include "common.h"
 
-extern void __init mmp_dt_init_timer(void);
-
 static void __init mmp_init_time(void)
 {
 #ifdef CONFIG_CACHE_TAUROS2
-- 
2.23.0


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

* Re: [PATCH] mmp: move declaration of mmp_dt_init_timer to common.h
  2019-10-17 10:37 [PATCH] mmp: move declaration of mmp_dt_init_timer to common.h Ben Dooks (Codethink)
@ 2019-10-17 15:51 ` Lubomir Rintel
  0 siblings, 0 replies; 2+ messages in thread
From: Lubomir Rintel @ 2019-10-17 15:51 UTC (permalink / raw)
  To: Ben Dooks (Codethink), linux-kernel; +Cc: linux-arm-kernel

On Thu, 2019-10-17 at 11:37 +0100, Ben Dooks (Codethink) wrote:
> The mmp_dt_init_timer() is shared by several files in the
> mmp directory, so move the declaration to common.h to
> remove the following sparse warning:
> 
> arch/arm/mach-mmp/time.c:204:13: warning: symbol 'mmp_dt_init_timer' was not declared. Should it be static?

Thanks for the patch.

However, I have a patch in the queue that gets rid of that symbol
altogether instead:

https://git.kernel.org/pub/scm/linux/kernel/git/lkundrak/linux-mmp.git/commit/?h=mmp-soc-for-v5.5-2&id=1732050f48a384fbe101b8586ed42caf874816eb

Lubo

> 
> Signed-off-by: Ben Dooks <ben.dooks@codethink.co.uk>
> ---
> Cc: Lubomir Rintel <lkundrak@v3.sk>
> Cc: linux-arm-kernel@lists.infradead.org
> ---
>  arch/arm/mach-mmp/common.h  | 1 +
>  arch/arm/mach-mmp/mmp-dt.c  | 2 --
>  arch/arm/mach-mmp/mmp2-dt.c | 2 --
>  3 files changed, 1 insertion(+), 4 deletions(-)
> 
> diff --git a/arch/arm/mach-mmp/common.h b/arch/arm/mach-mmp/common.h
> index 483b8b6d3005..5bb6dcf0a8c1 100644
> --- a/arch/arm/mach-mmp/common.h
> +++ b/arch/arm/mach-mmp/common.h
> @@ -3,6 +3,7 @@
>  #define ARRAY_AND_SIZE(x)	(x), ARRAY_SIZE(x)
>  
>  extern void mmp_timer_init(int irq, unsigned long rate);
> +extern void __init mmp_dt_init_timer(void);
>  
>  extern void __init mmp_map_io(void);
>  extern void mmp_restart(enum reboot_mode, const char *);
> diff --git a/arch/arm/mach-mmp/mmp-dt.c b/arch/arm/mach-mmp/mmp-dt.c
> index 35559792d5cc..e205cdaf19bf 100644
> --- a/arch/arm/mach-mmp/mmp-dt.c
> +++ b/arch/arm/mach-mmp/mmp-dt.c
> @@ -15,8 +15,6 @@
>  
>  #include "common.h"
>  
> -extern void __init mmp_dt_init_timer(void);
> -
>  static const char *const pxa168_dt_board_compat[] __initconst = {
>  	"mrvl,pxa168-aspenite",
>  	NULL,
> diff --git a/arch/arm/mach-mmp/mmp2-dt.c b/arch/arm/mach-mmp/mmp2-dt.c
> index 305a9daba6d6..ea63203b8810 100644
> --- a/arch/arm/mach-mmp/mmp2-dt.c
> +++ b/arch/arm/mach-mmp/mmp2-dt.c
> @@ -16,8 +16,6 @@
>  
>  #include "common.h"
>  
> -extern void __init mmp_dt_init_timer(void);
> -
>  static void __init mmp_init_time(void)
>  {
>  #ifdef CONFIG_CACHE_TAUROS2


_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

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

end of thread, other threads:[~2019-10-17 15:51 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-10-17 10:37 [PATCH] mmp: move declaration of mmp_dt_init_timer to common.h Ben Dooks (Codethink)
2019-10-17 15:51 ` Lubomir Rintel

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