Commit 3a2289a4 authored by Linus Torvalds's avatar Linus Torvalds

Merge branch 'for-linus-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu

* 'for-linus-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/gerg/m68knommu:
  m68k: use kernel processor defines for conditional optimizations
  m68knommu: create config options for CPU classes
  m68knommu: fix linker script exported name sections
parents ca543201 734c3ce3
...@@ -14,6 +14,33 @@ config GENERIC_CLOCKEVENTS ...@@ -14,6 +14,33 @@ config GENERIC_CLOCKEVENTS
bool bool
default n default n
config M68000
bool
help
The Freescale (was Motorola) 68000 CPU is the first generation of
the well known M68K family of processors. The CPU core as well as
being available as a stand alone CPU was also used in many
System-On-Chip devices (eg 68328, 68302, etc). It does not contain
a paging MMU.
config MCPU32
bool
help
The Freescale (was then Motorola) CPU32 is a CPU core that is
based on the 68020 processor. For the most part it is used in
System-On-Chip parts, and does not contain a paging MMU.
config COLDFIRE
bool
select GENERIC_GPIO
select ARCH_REQUIRE_GPIOLIB
help
The Freescale ColdFire family of processors is a modern derivitive
of the 68000 processor family. They are mainly targeted at embedded
applications, and are all System-On-Chip (SOC) devices, as opposed
to stand alone CPUs. They implement a subset of the original 68000
processor instruction set.
config COLDFIRE_SW_A7 config COLDFIRE_SW_A7
bool bool
default n default n
...@@ -36,26 +63,31 @@ choice ...@@ -36,26 +63,31 @@ choice
config M68328 config M68328
bool "MC68328" bool "MC68328"
select M68000
help help
Motorola 68328 processor support. Motorola 68328 processor support.
config M68EZ328 config M68EZ328
bool "MC68EZ328" bool "MC68EZ328"
select M68000
help help
Motorola 68EX328 processor support. Motorola 68EX328 processor support.
config M68VZ328 config M68VZ328
bool "MC68VZ328" bool "MC68VZ328"
select M68000
help help
Motorola 68VZ328 processor support. Motorola 68VZ328 processor support.
config M68360 config M68360
bool "MC68360" bool "MC68360"
select MCPU32
help help
Motorola 68360 processor support. Motorola 68360 processor support.
config M5206 config M5206
bool "MCF5206" bool "MCF5206"
select COLDFIRE
select COLDFIRE_SW_A7 select COLDFIRE_SW_A7
select HAVE_MBAR select HAVE_MBAR
help help
...@@ -63,6 +95,7 @@ config M5206 ...@@ -63,6 +95,7 @@ config M5206
config M5206e config M5206e
bool "MCF5206e" bool "MCF5206e"
select COLDFIRE
select COLDFIRE_SW_A7 select COLDFIRE_SW_A7
select HAVE_MBAR select HAVE_MBAR
help help
...@@ -70,6 +103,7 @@ config M5206e ...@@ -70,6 +103,7 @@ config M5206e
config M520x config M520x
bool "MCF520x" bool "MCF520x"
select COLDFIRE
select GENERIC_CLOCKEVENTS select GENERIC_CLOCKEVENTS
select HAVE_CACHE_SPLIT select HAVE_CACHE_SPLIT
help help
...@@ -77,6 +111,7 @@ config M520x ...@@ -77,6 +111,7 @@ config M520x
config M523x config M523x
bool "MCF523x" bool "MCF523x"
select COLDFIRE
select GENERIC_CLOCKEVENTS select GENERIC_CLOCKEVENTS
select HAVE_CACHE_SPLIT select HAVE_CACHE_SPLIT
select HAVE_IPSBAR select HAVE_IPSBAR
...@@ -85,6 +120,7 @@ config M523x ...@@ -85,6 +120,7 @@ config M523x
config M5249 config M5249
bool "MCF5249" bool "MCF5249"
select COLDFIRE
select COLDFIRE_SW_A7 select COLDFIRE_SW_A7
select HAVE_MBAR select HAVE_MBAR
help help
...@@ -92,6 +128,7 @@ config M5249 ...@@ -92,6 +128,7 @@ config M5249
config M5271 config M5271
bool "MCF5271" bool "MCF5271"
select COLDFIRE
select HAVE_CACHE_SPLIT select HAVE_CACHE_SPLIT
select HAVE_IPSBAR select HAVE_IPSBAR
help help
...@@ -99,6 +136,7 @@ config M5271 ...@@ -99,6 +136,7 @@ config M5271
config M5272 config M5272
bool "MCF5272" bool "MCF5272"
select COLDFIRE
select COLDFIRE_SW_A7 select COLDFIRE_SW_A7
select HAVE_MBAR select HAVE_MBAR
help help
...@@ -106,6 +144,7 @@ config M5272 ...@@ -106,6 +144,7 @@ config M5272
config M5275 config M5275
bool "MCF5275" bool "MCF5275"
select COLDFIRE
select HAVE_CACHE_SPLIT select HAVE_CACHE_SPLIT
select HAVE_IPSBAR select HAVE_IPSBAR
help help
...@@ -113,6 +152,7 @@ config M5275 ...@@ -113,6 +152,7 @@ config M5275
config M528x config M528x
bool "MCF528x" bool "MCF528x"
select COLDFIRE
select GENERIC_CLOCKEVENTS select GENERIC_CLOCKEVENTS
select HAVE_CACHE_SPLIT select HAVE_CACHE_SPLIT
select HAVE_IPSBAR select HAVE_IPSBAR
...@@ -121,6 +161,7 @@ config M528x ...@@ -121,6 +161,7 @@ config M528x
config M5307 config M5307
bool "MCF5307" bool "MCF5307"
select COLDFIRE
select COLDFIRE_SW_A7 select COLDFIRE_SW_A7
select HAVE_CACHE_CB select HAVE_CACHE_CB
select HAVE_MBAR select HAVE_MBAR
...@@ -129,12 +170,14 @@ config M5307 ...@@ -129,12 +170,14 @@ config M5307
config M532x config M532x
bool "MCF532x" bool "MCF532x"
select COLDFIRE
select HAVE_CACHE_CB select HAVE_CACHE_CB
help help
Freescale (Motorola) ColdFire 532x processor support. Freescale (Motorola) ColdFire 532x processor support.
config M5407 config M5407
bool "MCF5407" bool "MCF5407"
select COLDFIRE
select COLDFIRE_SW_A7 select COLDFIRE_SW_A7
select HAVE_CACHE_CB select HAVE_CACHE_CB
select HAVE_MBAR select HAVE_MBAR
...@@ -143,6 +186,7 @@ config M5407 ...@@ -143,6 +186,7 @@ config M5407
config M547x config M547x
bool "MCF547x" bool "MCF547x"
select COLDFIRE
select HAVE_CACHE_CB select HAVE_CACHE_CB
select HAVE_MBAR select HAVE_MBAR
help help
...@@ -150,6 +194,7 @@ config M547x ...@@ -150,6 +194,7 @@ config M547x
config M548x config M548x
bool "MCF548x" bool "MCF548x"
select COLDFIRE
select HAVE_CACHE_CB select HAVE_CACHE_CB
select HAVE_MBAR select HAVE_MBAR
help help
...@@ -168,13 +213,6 @@ config M54xx ...@@ -168,13 +213,6 @@ config M54xx
depends on (M548x || M547x) depends on (M548x || M547x)
default y default y
config COLDFIRE
bool
depends on (M5206 || M5206e || M520x || M523x || M5249 || M527x || M5272 || M528x || M5307 || M532x || M5407 || M54xx)
select GENERIC_GPIO
select ARCH_REQUIRE_GPIOLIB
default y
config CLOCK_SET config CLOCK_SET
bool "Enable setting the CPU clock frequency" bool "Enable setting the CPU clock frequency"
default n default n
......
...@@ -14,8 +14,7 @@ EXPORT_SYMBOL(__ashrdi3); ...@@ -14,8 +14,7 @@ EXPORT_SYMBOL(__ashrdi3);
EXPORT_SYMBOL(__lshrdi3); EXPORT_SYMBOL(__lshrdi3);
EXPORT_SYMBOL(__muldi3); EXPORT_SYMBOL(__muldi3);
#if !defined(__mc68020__) && !defined(__mc68030__) && \ #if defined(CONFIG_M68000) || defined(CONFIG_COLDFIRE)
!defined(__mc68040__) && !defined(__mc68060__) && !defined(__mcpu32__)
/* /*
* Simpler 68k and ColdFire parts also need a few other gcc functions. * Simpler 68k and ColdFire parts also need a few other gcc functions.
*/ */
......
...@@ -84,52 +84,52 @@ SECTIONS { ...@@ -84,52 +84,52 @@ SECTIONS {
/* Kernel symbol table: Normal symbols */ /* Kernel symbol table: Normal symbols */
. = ALIGN(4); . = ALIGN(4);
__start___ksymtab = .; __start___ksymtab = .;
*(__ksymtab) *(SORT(___ksymtab+*))
__stop___ksymtab = .; __stop___ksymtab = .;
/* Kernel symbol table: GPL-only symbols */ /* Kernel symbol table: GPL-only symbols */
__start___ksymtab_gpl = .; __start___ksymtab_gpl = .;
*(__ksymtab_gpl) *(SORT(___ksymtab_gpl+*))
__stop___ksymtab_gpl = .; __stop___ksymtab_gpl = .;
/* Kernel symbol table: Normal unused symbols */ /* Kernel symbol table: Normal unused symbols */
__start___ksymtab_unused = .; __start___ksymtab_unused = .;
*(__ksymtab_unused) *(SORT(___ksymtab_unused+*))
__stop___ksymtab_unused = .; __stop___ksymtab_unused = .;
/* Kernel symbol table: GPL-only unused symbols */ /* Kernel symbol table: GPL-only unused symbols */
__start___ksymtab_unused_gpl = .; __start___ksymtab_unused_gpl = .;
*(__ksymtab_unused_gpl) *(SORT(___ksymtab_unused_gpl+*))
__stop___ksymtab_unused_gpl = .; __stop___ksymtab_unused_gpl = .;
/* Kernel symbol table: GPL-future symbols */ /* Kernel symbol table: GPL-future symbols */
__start___ksymtab_gpl_future = .; __start___ksymtab_gpl_future = .;
*(__ksymtab_gpl_future) *(SORT(___ksymtab_gpl_future+*))
__stop___ksymtab_gpl_future = .; __stop___ksymtab_gpl_future = .;
/* Kernel symbol table: Normal symbols */ /* Kernel symbol table: Normal symbols */
__start___kcrctab = .; __start___kcrctab = .;
*(__kcrctab) *(SORT(___kcrctab+*))
__stop___kcrctab = .; __stop___kcrctab = .;
/* Kernel symbol table: GPL-only symbols */ /* Kernel symbol table: GPL-only symbols */
__start___kcrctab_gpl = .; __start___kcrctab_gpl = .;
*(__kcrctab_gpl) *(SORT(___kcrctab_gpl+*))
__stop___kcrctab_gpl = .; __stop___kcrctab_gpl = .;
/* Kernel symbol table: Normal unused symbols */ /* Kernel symbol table: Normal unused symbols */
__start___kcrctab_unused = .; __start___kcrctab_unused = .;
*(__kcrctab_unused) *(SORT(___kcrctab_unused+*))
__stop___kcrctab_unused = .; __stop___kcrctab_unused = .;
/* Kernel symbol table: GPL-only unused symbols */ /* Kernel symbol table: GPL-only unused symbols */
__start___kcrctab_unused_gpl = .; __start___kcrctab_unused_gpl = .;
*(__kcrctab_unused_gpl) *(SORT(___kcrctab_unused_gpl+*))
__stop___kcrctab_unused_gpl = .; __stop___kcrctab_unused_gpl = .;
/* Kernel symbol table: GPL-future symbols */ /* Kernel symbol table: GPL-future symbols */
__start___kcrctab_gpl_future = .; __start___kcrctab_gpl_future = .;
*(__kcrctab_gpl_future) *(SORT(___kcrctab_gpl_future+*))
__stop___kcrctab_gpl_future = .; __stop___kcrctab_gpl_future = .;
/* Kernel symbol table: strings */ /* Kernel symbol table: strings */
......
...@@ -34,8 +34,10 @@ void *memcpy(void *to, const void *from, size_t n) ...@@ -34,8 +34,10 @@ void *memcpy(void *to, const void *from, size_t n)
if (temp) { if (temp) {
long *lto = to; long *lto = to;
const long *lfrom = from; const long *lfrom = from;
#if defined(__mc68020__) || defined(__mc68030__) || \ #if defined(CONFIG_M68000) || defined(CONFIG_COLDFIRE)
defined(__mc68040__) || defined(__mc68060__) || defined(__mcpu32__) for (; temp; temp--)
*lto++ = *lfrom++;
#else
asm volatile ( asm volatile (
" movel %2,%3\n" " movel %2,%3\n"
" andw #7,%3\n" " andw #7,%3\n"
...@@ -56,9 +58,6 @@ void *memcpy(void *to, const void *from, size_t n) ...@@ -56,9 +58,6 @@ void *memcpy(void *to, const void *from, size_t n)
" jpl 4b" " jpl 4b"
: "=a" (lfrom), "=a" (lto), "=d" (temp), "=&d" (temp1) : "=a" (lfrom), "=a" (lto), "=d" (temp), "=&d" (temp1)
: "0" (lfrom), "1" (lto), "2" (temp)); : "0" (lfrom), "1" (lto), "2" (temp));
#else
for (; temp; temp--)
*lto++ = *lfrom++;
#endif #endif
to = lto; to = lto;
from = lfrom; from = lfrom;
......
...@@ -32,8 +32,10 @@ void *memset(void *s, int c, size_t count) ...@@ -32,8 +32,10 @@ void *memset(void *s, int c, size_t count)
temp = count >> 2; temp = count >> 2;
if (temp) { if (temp) {
long *ls = s; long *ls = s;
#if defined(__mc68020__) || defined(__mc68030__) || \ #if defined(CONFIG_M68000) || defined(CONFIG_COLDFIRE)
defined(__mc68040__) || defined(__mc68060__) || defined(__mcpu32__) for (; temp; temp--)
*ls++ = c;
#else
size_t temp1; size_t temp1;
asm volatile ( asm volatile (
" movel %1,%2\n" " movel %1,%2\n"
...@@ -55,9 +57,6 @@ void *memset(void *s, int c, size_t count) ...@@ -55,9 +57,6 @@ void *memset(void *s, int c, size_t count)
" jpl 1b" " jpl 1b"
: "=a" (ls), "=d" (temp), "=&d" (temp1) : "=a" (ls), "=d" (temp), "=&d" (temp1)
: "d" (c), "0" (ls), "1" (temp)); : "d" (c), "0" (ls), "1" (temp));
#else
for (; temp; temp--)
*ls++ = c;
#endif #endif
s = ls; s = ls;
} }
......
...@@ -19,17 +19,7 @@ along with GNU CC; see the file COPYING. If not, write to ...@@ -19,17 +19,7 @@ along with GNU CC; see the file COPYING. If not, write to
the Free Software Foundation, 59 Temple Place - Suite 330, the Free Software Foundation, 59 Temple Place - Suite 330,
Boston, MA 02111-1307, USA. */ Boston, MA 02111-1307, USA. */
#if defined(__mc68020__) || defined(__mc68030__) || \ #if defined(CONFIG_M68000) || defined(CONFIG_COLDFIRE)
defined(__mc68040__) || defined(__mc68060__) || defined(__mcpu32__)
#define umul_ppmm(w1, w0, u, v) \
__asm__ ("mulu%.l %3,%1:%0" \
: "=d" ((USItype)(w0)), \
"=d" ((USItype)(w1)) \
: "%0" ((USItype)(u)), \
"dmi" ((USItype)(v)))
#else
#define SI_TYPE_SIZE 32 #define SI_TYPE_SIZE 32
#define __BITS4 (SI_TYPE_SIZE / 4) #define __BITS4 (SI_TYPE_SIZE / 4)
...@@ -61,6 +51,15 @@ Boston, MA 02111-1307, USA. */ ...@@ -61,6 +51,15 @@ Boston, MA 02111-1307, USA. */
(w0) = __ll_lowpart (__x1) * __ll_B + __ll_lowpart (__x0); \ (w0) = __ll_lowpart (__x1) * __ll_B + __ll_lowpart (__x0); \
} while (0) } while (0)
#else
#define umul_ppmm(w1, w0, u, v) \
__asm__ ("mulu%.l %3,%1:%0" \
: "=d" ((USItype)(w0)), \
"=d" ((USItype)(w1)) \
: "%0" ((USItype)(u)), \
"dmi" ((USItype)(v)))
#endif #endif
#define __umulsidi3(u, v) \ #define __umulsidi3(u, v) \
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment