All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] m68k: use of 64 div instruction is chip specific
@ 2011-10-21  7:08 gerg
  2011-10-21 15:00 ` Geert Uytterhoeven
  0 siblings, 1 reply; 2+ messages in thread
From: gerg @ 2011-10-21  7:08 UTC (permalink / raw)
  To: linux-m68k, uclinux-dev; +Cc: Greg Ungerer

From: Greg Ungerer <gerg@uclinux.org>

The use of the 64 div instruction should not be based on whether we
are running MMU enabled or not. It is chip specific. The original
68000 family and the ColdFire CPU family do not support it, the
other 680x0 CPU varients do. So make the conditional check based on
that, not CONFIG_MMU.

Signed-off-by: Greg Ungerer <gerg@uclinux.org>
---
 arch/m68k/include/asm/div64.h |    8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/m68k/include/asm/div64.h b/arch/m68k/include/asm/div64.h
index edb6614..7265e40 100644
--- a/arch/m68k/include/asm/div64.h
+++ b/arch/m68k/include/asm/div64.h
@@ -1,7 +1,9 @@
 #ifndef _M68K_DIV64_H
 #define _M68K_DIV64_H
 
-#ifdef CONFIG_MMU
+#if defined(CONFIG_M68000) || defined(CONFIG_COLDFIRE)
+#include <asm-generic/div64.h>
+#else
 
 #include <linux/types.h>
 
@@ -27,8 +29,6 @@
 	__rem;							\
 })
 
-#else
-#include <asm-generic/div64.h>
-#endif /* CONFIG_MMU */
+#endif /* CONFIG_M68000 || CONFIG_COLDFIRE */
 
 #endif /* _M68K_DIV64_H */
-- 
1.7.0.4

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

* Re: [PATCH] m68k: use of 64 div instruction is chip specific
  2011-10-21  7:08 [PATCH] m68k: use of 64 div instruction is chip specific gerg
@ 2011-10-21 15:00 ` Geert Uytterhoeven
  0 siblings, 0 replies; 2+ messages in thread
From: Geert Uytterhoeven @ 2011-10-21 15:00 UTC (permalink / raw)
  To: gerg; +Cc: linux-m68k, uclinux-dev, Greg Ungerer

On Fri, Oct 21, 2011 at 09:08,  <gerg@snapgear.com> wrote:
> From: Greg Ungerer <gerg@uclinux.org>
>
> The use of the 64 div instruction should not be based on whether we
> are running MMU enabled or not. It is chip specific. The original
> 68000 family and the ColdFire CPU family do not support it, the
> other 680x0 CPU varients do. So make the conditional check based on
> that, not CONFIG_MMU.
>
> Signed-off-by: Greg Ungerer <gerg@uclinux.org>

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

> ---
>  arch/m68k/include/asm/div64.h |    8 ++++----
>  1 files changed, 4 insertions(+), 4 deletions(-)
>
> diff --git a/arch/m68k/include/asm/div64.h b/arch/m68k/include/asm/div64.h
> index edb6614..7265e40 100644
> --- a/arch/m68k/include/asm/div64.h
> +++ b/arch/m68k/include/asm/div64.h
> @@ -1,7 +1,9 @@
>  #ifndef _M68K_DIV64_H
>  #define _M68K_DIV64_H
>
> -#ifdef CONFIG_MMU
> +#if defined(CONFIG_M68000) || defined(CONFIG_COLDFIRE)
> +#include <asm-generic/div64.h>
> +#else
>
>  #include <linux/types.h>
>
> @@ -27,8 +29,6 @@
>        __rem;                                                  \
>  })
>
> -#else
> -#include <asm-generic/div64.h>
> -#endif /* CONFIG_MMU */
> +#endif /* CONFIG_M68000 || CONFIG_COLDFIRE */
>
>  #endif /* _M68K_DIV64_H */

Gr{oetje,eeting}s,

                        Geert

--
Geert Uytterhoeven -- There's lots of Linux beyond ia32 -- geert@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.
                                -- Linus Torvalds

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

end of thread, other threads:[~2011-10-21 15:00 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-10-21  7:08 [PATCH] m68k: use of 64 div instruction is chip specific gerg
2011-10-21 15:00 ` Geert Uytterhoeven

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.