gerg | 8 Jun 2012 07:25

[PATCH] m68k: fix inclusion of arch_gettimeoffset for non-MMU 68k classic CPU types

From: Greg Ungerer <gerg <at> uclinux.org>

When building for non-MMU based classic 68k CPU types (like the 68328 for
example) you get a compilation error:

  CC      arch/m68k/kernel/time.o
arch/m68k/kernel/time.c:91:5: error: redefinition of ‘arch_gettimeoffset’
include/linux/time.h:145:19: note: previous definition of ‘arch_gettimeoffset’ was here

The arch_gettimeoffset() code is included when building for these CPU types,
but it shouldn't be. Those machine types do not have
CONFIG_ARCH_USES_GETTIMEOFFSET set.

The fix is simply to conditionally include the arch_gettimeoffset() code on
that same config setting that specifies its use or not.

Signed-off-by: Greg Ungerer <gerg <at> uclinux.org>
---
 arch/m68k/kernel/time.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/m68k/kernel/time.c b/arch/m68k/kernel/time.c
index d7deb7f..707f057 100644
--- a/arch/m68k/kernel/time.c
+++ b/arch/m68k/kernel/time.c
 <at>  <at>  -85,7 +85,7  <at>  <at>  void __init time_init(void)
 	mach_sched_init(timer_interrupt);
 }

-#ifdef CONFIG_M68KCLASSIC
(Continue reading)

Geert Uytterhoeven | 8 Jun 2012 09:12

Re: [uClinux-dev] [PATCH] m68k: fix inclusion of arch_gettimeoffset for non-MMU 68k classic CPU types

On Fri, Jun 8, 2012 at 7:25 AM,  <gerg <at> snapgear.com> wrote:
> From: Greg Ungerer <gerg <at> uclinux.org>
>
> When building for non-MMU based classic 68k CPU types (like the 68328 for
> example) you get a compilation error:
>
>  CC      arch/m68k/kernel/time.o
> arch/m68k/kernel/time.c:91:5: error: redefinition of ‘arch_gettimeoffset’
> include/linux/time.h:145:19: note: previous definition of ‘arch_gettimeoffset’ was here
>
> The arch_gettimeoffset() code is included when building for these CPU types,
> but it shouldn't be. Those machine types do not have
> CONFIG_ARCH_USES_GETTIMEOFFSET set.
>
> The fix is simply to conditionally include the arch_gettimeoffset() code on
> that same config setting that specifies its use or not.
>
> Signed-off-by: Greg Ungerer <gerg <at> uclinux.org>

Acked-by: Geert Uytterhoeven <geert <at> linux-m68k.org>

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert <at> linux-m68k.org

In personal conversations with technical people, I call myself a hacker. But
when I'm talking to journalists I just say "programmer" or something like that.
(Continue reading)


Gmane