summaryrefslogtreecommitdiffstats
path: root/arch/m68k
diff options
context:
space:
mode:
authorRalf Baechle <ralf@linux-mips.org>2001-01-11 04:02:40 +0000
committerRalf Baechle <ralf@linux-mips.org>2001-01-11 04:02:40 +0000
commite47f00743fc4776491344f2c618cc8dc2c23bcbc (patch)
tree13e03a113a82a184c51c19c209867cfd3a59b3b9 /arch/m68k
parentb2ad5f821b1381492d792ca10b1eb7a107b48f14 (diff)
Merge with Linux 2.4.0.
Diffstat (limited to 'arch/m68k')
-rw-r--r--arch/m68k/Makefile4
-rw-r--r--arch/m68k/amiga/amisound.c11
-rw-r--r--arch/m68k/amiga/config.c36
-rw-r--r--arch/m68k/atari/debug.c4
-rw-r--r--arch/m68k/config.in64
-rw-r--r--arch/m68k/kernel/m68k_defs.h63
-rw-r--r--arch/m68k/kernel/m68k_ksyms.c13
-rw-r--r--arch/m68k/kernel/setup.c6
-rw-r--r--arch/m68k/kernel/time.c4
-rw-r--r--arch/m68k/kernel/traps.c7
-rw-r--r--arch/m68k/lib/Makefile4
-rw-r--r--arch/m68k/lib/ashldi3.c62
-rw-r--r--arch/m68k/mm/fault.c2
13 files changed, 159 insertions, 121 deletions
diff --git a/arch/m68k/Makefile b/arch/m68k/Makefile
index bffafa918..6821efbc1 100644
--- a/arch/m68k/Makefile
+++ b/arch/m68k/Makefile
@@ -19,6 +19,10 @@ COMPILE_ARCH = $(shell uname -m)
# override top level makefile
AS += -m68020
LD += -m m68kelf
+ifneq ($(COMPILE_ARCH),$(ARCH))
+ # prefix for cross-compiling binaries
+ CROSS_COMPILE = m68k-linux-
+endif
ifndef CONFIG_SUN3
LINKFLAGS = -T $(TOPDIR)/arch/m68k/vmlinux.lds
diff --git a/arch/m68k/amiga/amisound.c b/arch/m68k/amiga/amisound.c
index 4c94f7862..aaec835f3 100644
--- a/arch/m68k/amiga/amisound.c
+++ b/arch/m68k/amiga/amisound.c
@@ -97,13 +97,10 @@ void amiga_mksound( unsigned int hz, unsigned int ticks )
/* turn on DMA for audio channel 2 */
custom.dmacon = DMAF_SETCLR | DMAF_AUD2;
- restore_flags(flags);
- return;
- } else {
+ } else
nosound( 0 );
- restore_flags(flags);
- return;
- }
+
+ restore_flags(flags);
}
@@ -113,4 +110,4 @@ static void nosound( unsigned long ignored )
custom.dmacon = DMAF_AUD2;
/* restore period to previous value after beeping */
custom.aud[2].audper = amiga_audio_period;
-}
+}
diff --git a/arch/m68k/amiga/config.c b/arch/m68k/amiga/config.c
index 618d9a618..6136c40c3 100644
--- a/arch/m68k/amiga/config.c
+++ b/arch/m68k/amiga/config.c
@@ -136,11 +136,13 @@ extern void (*kd_mksound)(unsigned int, unsigned int);
* Motherboard Resources present in all Amiga models
*/
-static struct resource mb_resource[] = {
- { "CIA B", 0x00bfd000, 0x00bfdfff },
- { "CIA A", 0x00bfe000, 0x00bfefff },
- { "Custom I/O", 0x00dff000, 0x00dfffff },
- { "Kickstart ROM", 0x00f80000, 0x00ffffff }
+static struct {
+ struct resource _ciab, _ciaa, _custom, _kickstart;
+} mb_resources = {
+ _ciab: { "CIA B", 0x00bfd000, 0x00bfdfff },
+ _ciaa: { "CIA A", 0x00bfe000, 0x00bfefff },
+ _custom: { "Custom I/O", 0x00dff000, 0x00dfffff },
+ _kickstart: { "Kickstart ROM", 0x00f80000, 0x00ffffff }
};
static struct resource rtc_resource = {
@@ -196,7 +198,7 @@ int amiga_parse_bootinfo(const struct bi_record *record)
dev->resource.end = dev->resource.start+cd->cd_BoardSize-1;
} else
printk("amiga_parse_bootinfo: too many AutoConfig devices\n");
-#endif
+#endif /* CONFIG_ZORRO */
break;
case BI_AMIGA_SERPER:
@@ -385,8 +387,8 @@ void __init config_amiga(void)
/* Yuk, we don't have PCI memory */
iomem_resource.name = "Memory";
- for (i = 0; i < sizeof(mb_resource)/sizeof(mb_resource[0]); i++)
- request_resource(&iomem_resource, &mb_resource[i]);
+ for (i = 0; i < 4; i++)
+ request_resource(&iomem_resource, &((struct resource *)&mb_resources)[i]);
mach_sched_init = amiga_sched_init;
mach_keyb_init = amiga_keyb_init;
@@ -430,7 +432,9 @@ void __init config_amiga(void)
mach_floppy_setup = amiga_floppy_setup;
#endif
mach_reset = amiga_reset;
+#ifdef CONFIG_DUMMY_CONSOLE
conswitchp = &dummy_con;
+#endif
kd_mksound = amiga_mksound;
#ifdef CONFIG_MAGIC_SYSRQ
mach_sysrq_key = 0x5f; /* HELP */
@@ -515,10 +519,12 @@ static unsigned short jiffy_ticks;
static void __init amiga_sched_init(void (*timer_routine)(int, void *,
struct pt_regs *))
{
- static struct resource sched_res = { "timer" };
+ static struct resource sched_res = {
+ "timer", 0x00bfd400, 0x00bfd5ff,
+ };
jiffy_ticks = (amiga_eclock+HZ/2)/HZ;
- if (!request_mem_region(CIAB_PHYSADDR+0x400, 0x200, "timer"))
+ if (request_resource(&mb_resources._ciab, &sched_res))
printk("Cannot allocate ciab.ta{lo,hi}\n");
ciab.cra &= 0xC0; /* turn off timer A, continuous mode, from Eclk */
ciab.talo = jiffy_ticks % 256;
@@ -624,6 +630,8 @@ static int amiga_hwclk(int op, struct hwclk_time *t)
t->wday = tod->weekday;
t->mon = tod->month1 * 10 + tod->month2 - 1;
t->year = tod->year1 * 10 + tod->year2;
+ if (t->year <= 69)
+ t->year += 100;
} else {
tod->second1 = t->sec / 10;
tod->second2 = t->sec % 10;
@@ -637,6 +645,8 @@ static int amiga_hwclk(int op, struct hwclk_time *t)
tod->weekday = t->wday;
tod->month1 = (t->mon + 1) / 10;
tod->month2 = (t->mon + 1) % 10;
+ if (t->year >= 100)
+ t->year -= 100;
tod->year1 = t->year / 10;
tod->year2 = t->year % 10;
}
@@ -658,6 +668,8 @@ static int amiga_hwclk(int op, struct hwclk_time *t)
t->wday = tod->weekday;
t->mon = tod->month1 * 10 + tod->month2 - 1;
t->year = tod->year1 * 10 + tod->year2;
+ if (t->year <= 69)
+ t->year += 100;
if (!(tod->cntrl3 & TOD2000_CNTRL3_24HMODE)){
if (!(tod->hour1 & TOD2000_HOUR1_PM) && t->hour == 12)
@@ -684,6 +696,8 @@ static int amiga_hwclk(int op, struct hwclk_time *t)
tod->weekday = t->wday;
tod->month1 = (t->mon + 1) / 10;
tod->month2 = (t->mon + 1) % 10;
+ if (t->year >= 100)
+ t->year -= 100;
tod->year1 = t->year / 10;
tod->year2 = t->year % 10;
}
@@ -1047,7 +1061,7 @@ static int amiga_get_hardware_list(char *buffer)
"Device%s\n",
AMIGAHW_PRESENT(ZORRO3) ? "I" : "",
zorro_num_autocon, zorro_num_autocon == 1 ? "" : "s");
-#endif
+#endif /* CONFIG_ZORRO */
#undef AMIGAHW_ANNOUNCE
diff --git a/arch/m68k/atari/debug.c b/arch/m68k/atari/debug.c
index 2900f7758..75c9c4471 100644
--- a/arch/m68k/atari/debug.c
+++ b/arch/m68k/atari/debug.c
@@ -94,7 +94,7 @@ static int ata_par_out (char c)
{
unsigned char tmp;
/* This a some-seconds timeout in case no printer is connected */
- unsigned long i = loops_per_sec > 1 ? loops_per_sec : 10000000;
+ unsigned long i = loops_per_jiffy > 1 ? loops_per_jiffy : 10000000/HZ;
while( (mfp.par_dt_reg & 1) && --i ) /* wait for BUSY == L */
;
@@ -196,7 +196,7 @@ void atari_init_mfp_port( int cflag )
MFPDELAY(); \
} while(0)
-/* loops_per_sec isn't initialized yet, so we can't use udelay(). This does a
+/* loops_per_jiffy isn't initialized yet, so we can't use udelay(). This does a
* delay of ~ 60us. */
#define LONG_DELAY() \
do { \
diff --git a/arch/m68k/config.in b/arch/m68k/config.in
index b287daca8..9e32116f5 100644
--- a/arch/m68k/config.in
+++ b/arch/m68k/config.in
@@ -53,9 +53,9 @@ bool 'HP9000/300 support' CONFIG_HP300
if [ "$CONFIG_HP300" = "y" ]; then
bool ' DIO bus support' CONFIG_DIO
fi
+bool 'Sun3 support' CONFIG_SUN3
bool 'Sun3x support' CONFIG_SUN3X
-define_bool CONFIG_SUN3 n
bool 'Q40/Q60 support' CONFIG_Q40
comment 'Processor type'
@@ -73,7 +73,11 @@ fi
bool 'Advanced configuration options' CONFIG_ADVANCED
if [ "$CONFIG_ADVANCED" = "y" ]; then
bool 'Use read-modify-write instructions' CONFIG_RMW_INSNS
- bool 'Use one physical chunk of memory only' CONFIG_SINGLE_MEMORY_CHUNK
+ if [ "$CONFIG_SUN3" = "y" ]; then
+ define_bool CONFIG_SINGLE_MEMORY_CHUNK n
+ else
+ bool 'Use one physical chunk of memory only' CONFIG_SINGLE_MEMORY_CHUNK
+ fi
if [ "$CONFIG_M68060" = "y" ]; then
bool 'Use write-through caching for 68060 supervisor accesses' CONFIG_060_WRITETHROUGH
fi
@@ -120,13 +124,12 @@ if [ "$CONFIG_EXPERIMENTAL" = "y" ]; then
tristate 'Parallel port support (EXPERIMENTAL)' CONFIG_PARPORT
if [ "$CONFIG_PARPORT" != "n" ]; then
if [ "$CONFIG_AMIGA" != "n" ]; then
- dep_tristate ' Amiga builtin port' CONFIG_PARPORT_AMIGA $CONFIG_PARPORT
+ dep_tristate ' Amiga builtin port' CONFIG_PARPORT_AMIGA $CONFIG_PARPORT
if [ "$CONFIG_ZORRO" != "n" ]; then
- dep_tristate ' Multiface III parallel port' CONFIG_PARPORT_MFC3 $CONFIG_PARPORT
+ dep_tristate ' Multiface III parallel port' CONFIG_PARPORT_MFC3 $CONFIG_PARPORT
fi
fi
if [ "$CONFIG_Q40" != "n" ]; then
- tristate ' Q40 Parallel port' CONFIG_PARPORT
if [ "$CONFIG_PARPORT" != "n" ]; then
define_bool CONFIG_PARPORT_PC y
fi
@@ -156,6 +159,10 @@ if [ "$CONFIG_NET" = "y" ]; then
source net/Config.in
fi
+if [ "$CONFIG_MAC" = "y" ]; then
+ source drivers/input/Config.in
+fi
+
mainmenu_option next_comment
comment 'ATA/IDE/MFM/RLL support'
@@ -254,6 +261,10 @@ if [ "$CONFIG_SCSI" != "n" ]; then
bool 'NCR53C710 SCSI driver for BVME6000' CONFIG_BVME6000_SCSI
fi
+ if [ "$CONFIG_SUN3" = "y" ]; then
+ dep_tristate 'Sun3 NCR5380 SCSI' CONFIG_SUN3_SCSI $CONFIG_SCSI
+ fi
+
if [ "$CONFIG_SUN3X" = "y" ]; then
bool 'ESP SCSI driver' CONFIG_SUN3X_ESP
fi
@@ -322,16 +333,17 @@ if [ "$CONFIG_NET" = "y" ]; then
tristate ' PAMsNet support' CONFIG_ATARI_PAMSNET
fi
fi
- if [ "$CONFIG_SUN3X" = "y" ]; then
- bool ' Sun3x Lance support' CONFIG_SUNLANCE
+ if [ "$CONFIG_SUN3" = "y" -o "$CONFIG_SUN3X" = "y" ]; then
+ tristate ' Sun3/Sun3x on-board LANCE support' CONFIG_SUN3LANCE
fi
if [ "$CONFIG_HP300" = "y" ]; then
bool ' HP on-board LANCE support' CONFIG_HPLANCE
fi
if [ "$CONFIG_Q40" = "y" ]; then
- if [ ! "$CONFIG_PARPORT" = "n" ]; then
+ if [ "$CONFIG_PARPORT" != "n" ]; then
dep_tristate ' PLIP (parallel port) support' CONFIG_PLIP $CONFIG_PARPORT
fi
+ tristate 'NE2000/NE1000 support' CONFIG_NE2000
fi
fi
endmenu
@@ -404,29 +416,39 @@ if [ "$CONFIG_PARPORT" = "n" ]; then
dep_tristate ' GVP IO-Extender parallel printer support' CONFIG_GVPIOEXT_LP $CONFIG_GVPIOEXT
dep_tristate ' GVP IO-Extender PLIP support' CONFIG_GVPIOEXT_PLIP $CONFIG_GVPIOEXT
tristate 'Multiface Card III serial support' CONFIG_MULTIFACE_III_TTY
+ if [ "$CONFIG_EXPERIMENTAL" = "y" ]; then
+ tristate 'Commodore A2232 serial support (EXPERIMENTAL)' CONFIG_A2232
+ fi
fi
fi
if [ "$CONFIG_MAC" = "y" ]; then
tristate 'Macintosh serial support' CONFIG_MAC_SCC
bool 'Apple Desktop Bus (ADB) support' CONFIG_ADB
if [ "$CONFIG_ADB" = "y" ]; then
- bool ' Support for ADB keyboard' CONFIG_ADB_KEYBOARD
- bool ' Support for ADB mouse' CONFIG_ADBMOUSE
bool ' Include Mac II ADB driver' CONFIG_ADB_MACII
bool ' Include Mac IIsi ADB driver' CONFIG_ADB_MACIISI
bool ' Include CUDA ADB driver' CONFIG_ADB_CUDA
bool ' Include IOP (IIfx/Quadra 9x0) ADB driver' CONFIG_ADB_IOP
bool ' Include PMU (Powerbook) ADB driver' CONFIG_ADB_PMU68K
fi
- if [ "$CONFIG_ADBMOUSE" = "y" ]; then
- define_bool CONFIG_BUSMOUSE y
+ dep_bool ' Use input layer for ADB devices' CONFIG_INPUT_ADBHID $CONFIG_INPUT
+ if [ "$CONFIG_INPUT_ADBHID" = "y" ]; then
+ define_bool CONFIG_MAC_HID y
+ bool ' Support for ADB raw keycodes' CONFIG_MAC_ADBKEYCODES
+ bool ' Support for mouse button 2+3 emulation' CONFIG_MAC_EMUMOUSEBTN
+ else
+ bool ' Support for ADB keyboard (old driver)' CONFIG_ADB_KEYBOARD
fi
fi
if [ "$CONFIG_HP300" = "y" -a "$CONFIG_DIO" = "y" ]; then
tristate 'HP DCA serial support' CONFIG_HPDCA
fi
-dep_bool 'Sun3x builtin serial support' CONFIG_SUN3X_ZS $CONFIG_SUN3X
+if [ "$CONFIG_SUN3" = "y" -o "$CONFIG_SUN3X" = "y" ]; then
+ bool 'Sun3/3x builtin serial support' CONFIG_SUN3X_ZS
+else
+ define_bool CONFIG_SUN3X_ZS n
+fi
dep_bool ' Sun keyboard support' CONFIG_SUN_KEYBOARD $CONFIG_SUN3X_ZS
dep_bool ' Sun mouse support' CONFIG_SUN_MOUSE $CONFIG_SUN3X_ZS
if [ "$CONFIG_SUN_MOUSE" = "y" ]; then
@@ -442,7 +464,7 @@ fi
if [ "$CONFIG_AMIGA" = "y" -o "$CONFIG_ATARI" = "y" -o \
"$CONFIG_MAC" = "y" -o "$CONFIG_HP300" = "y" -o \
- "$CONFIG_SUN3X" = "y" ]; then
+ "$CONFIG_SUN3" = "y" -o "$CONFIG_SUN3X" = "y" ]; then
if [ "$CONFIG_ATARI_MFPSER" = "y" -o "$CONFIG_ATARI_SCC" = "y" -o \
"$CONFIG_ATARI_MIDI" = "y" -o "$CONFIG_MAC_SCC" = "y" -o \
"$CONFIG_AMIGA_BUILTIN_SERIAL" = "y" -o \
@@ -476,6 +498,15 @@ if [ "$CONFIG_WATCHDOG" != "n" ]; then
fi
if [ "$CONFIG_ATARI" = "y" ]; then
bool 'Enhanced Real Time Clock Support' CONFIG_RTC
+else
+ if [ "$CONFIG_SUN3" = "y" ]; then
+ define_bool CONFIG_GEN_RTC y
+ else
+ bool 'Generic /dev/rtc emulation' CONFIG_GEN_RTC
+ fi
+fi
+if [ "$CONFIG_Q40" = "y" ]; then
+ bool 'Q40 Real Time Clock Support' CONFIG_Q40RTC
fi
bool 'Unix98 PTY support' CONFIG_UNIX98_PTYS
if [ "$CONFIG_UNIX98_PTYS" = "y" ]; then
@@ -498,11 +529,6 @@ source fs/Config.in
if [ "$CONFIG_VME" = "n" ]; then
mainmenu_option next_comment
comment 'Console drivers'
- if [ "$CONFIG_HP300" = "y" ]; then
- bool 'Frame buffer support' CONFIG_FB
- else
- define_bool CONFIG_FB y
- fi
source drivers/video/Config.in
endmenu
fi
diff --git a/arch/m68k/kernel/m68k_defs.h b/arch/m68k/kernel/m68k_defs.h
deleted file mode 100644
index 374e56e27..000000000
--- a/arch/m68k/kernel/m68k_defs.h
+++ /dev/null
@@ -1,63 +0,0 @@
-/*
- * WARNING! This file is automatically generated - DO NOT EDIT!
- */
-
-#define TS_MAGICKEY 0x5a5a5a5a
-#define TASK_STATE 0
-#define TASK_FLAGS 4
-#define TASK_SIGPENDING 8
-#define TASK_NEEDRESCHED 20
-#define TASK_THREAD 482
-#define TASK_MM 634
-#define TASK_ACTIVE_MM 638
-#define THREAD_KSP 0
-#define THREAD_USP 4
-#define THREAD_SR 8
-#define THREAD_FS 10
-#define THREAD_CRP 12
-#define THREAD_ESP0 20
-#define THREAD_FPREG 24
-#define THREAD_FPCNTL 120
-#define THREAD_FPSTATE 132
-#define PT_D0 32
-#define PT_ORIG_D0 36
-#define PT_D1 0
-#define PT_D2 4
-#define PT_D3 8
-#define PT_D4 12
-#define PT_D5 16
-#define PT_A0 20
-#define PT_A1 24
-#define PT_A2 28
-#define PT_PC 46
-#define PT_SR 44
-#define PT_VECTOR 50
-#define IRQ_HANDLER 0
-#define IRQ_DEVID 8
-#define IRQ_NEXT 16
-#define STAT_IRQ 120
-#define BIR_TAG 0
-#define BIR_SIZE 2
-#define BIR_DATA 4
-#define FBCON_FONT_DESC_IDX 0
-#define FBCON_FONT_DESC_NAME 4
-#define FBCON_FONT_DESC_WIDTH 8
-#define FBCON_FONT_DESC_HEIGHT 12
-#define FBCON_FONT_DESC_DATA 16
-#define FBCON_FONT_DESC_PREF 20
-#define SIGSEGV 11
-#define SEGV_MAPERR 1
-#define SIGTRAP 5
-#define TRAP_TRACE 2
-#define CUSTOMBASE -2132807680
-#define C_INTENAR 28
-#define C_INTREQR 30
-#define C_INTENA 154
-#define C_INTREQ 156
-#define C_SERDATR 24
-#define C_SERDAT 48
-#define C_SERPER 50
-#define CIAABASE -2134908927
-#define CIABBASE -2134913024
-#define C_PRA 0
-#define ZTWOBASE -2147483648
diff --git a/arch/m68k/kernel/m68k_ksyms.c b/arch/m68k/kernel/m68k_ksyms.c
index 35d194623..4e980deb2 100644
--- a/arch/m68k/kernel/m68k_ksyms.c
+++ b/arch/m68k/kernel/m68k_ksyms.c
@@ -19,6 +19,7 @@
#include <asm/hardirq.h>
#include <asm/softirq.h>
+asmlinkage long long __ashldi3 (long long, int);
asmlinkage long long __ashrdi3 (long long, int);
asmlinkage long long __lshrdi3 (long long, int);
asmlinkage long long __muldi3 (long long, long long);
@@ -32,27 +33,28 @@ extern int dump_fpu(elf_fpregset_t *);
EXPORT_SYMBOL(m68k_machtype);
EXPORT_SYMBOL(m68k_cputype);
EXPORT_SYMBOL(m68k_is040or060);
+EXPORT_SYMBOL(m68k_realnum_memory);
+EXPORT_SYMBOL(m68k_memory);
+#ifndef CONFIG_SUN3
EXPORT_SYMBOL(cache_push);
EXPORT_SYMBOL(cache_clear);
#ifndef CONFIG_SINGLE_MEMORY_CHUNK
EXPORT_SYMBOL(mm_vtop);
EXPORT_SYMBOL(mm_ptov);
EXPORT_SYMBOL(mm_end_of_chunk);
-#endif
-EXPORT_SYMBOL(m68k_realnum_memory);
-EXPORT_SYMBOL(m68k_memory);
-#ifndef CONFIG_SUN3
+#endif /* !CONFIG_SINGLE_MEMORY_CHUNK */
EXPORT_SYMBOL(mm_vtop_fallback);
EXPORT_SYMBOL(__ioremap);
EXPORT_SYMBOL(iounmap);
EXPORT_SYMBOL(kernel_set_cachemode);
-#endif
+#endif /* !CONFIG_SUN3 */
EXPORT_SYMBOL(m68k_debug_device);
EXPORT_SYMBOL(dump_fpu);
EXPORT_SYMBOL(dump_thread);
EXPORT_SYMBOL(strnlen);
EXPORT_SYMBOL(strrchr);
EXPORT_SYMBOL(strstr);
+EXPORT_SYMBOL(strtok);
EXPORT_SYMBOL(enable_irq);
EXPORT_SYMBOL(disable_irq);
EXPORT_SYMBOL(kernel_thread);
@@ -67,6 +69,7 @@ EXPORT_SYMBOL(csum_partial_copy);
explicitly (the C compiler generates them). Fortunately,
their interface isn't gonna change any time soon now, so
it's OK to leave it out of version control. */
+EXPORT_SYMBOL_NOVERS(__ashldi3);
EXPORT_SYMBOL_NOVERS(__ashrdi3);
EXPORT_SYMBOL_NOVERS(__lshrdi3);
EXPORT_SYMBOL_NOVERS(memcpy);
diff --git a/arch/m68k/kernel/setup.c b/arch/m68k/kernel/setup.c
index 461628123..4e54e49a3 100644
--- a/arch/m68k/kernel/setup.c
+++ b/arch/m68k/kernel/setup.c
@@ -432,7 +432,7 @@ int get_cpuinfo(char * buffer)
else
mmu = "unknown";
- clockfreq = loops_per_sec*clockfactor;
+ clockfreq = loops_per_jiffy*HZ*clockfactor;
return(sprintf(buffer, "CPU:\t\t%s\n"
"MMU:\t\t%s\n"
@@ -442,8 +442,8 @@ int get_cpuinfo(char * buffer)
"Calibration:\t%lu loops\n",
cpu, mmu, fpu,
clockfreq/1000000,(clockfreq/100000)%10,
- loops_per_sec/500000,(loops_per_sec/5000)%100,
- loops_per_sec));
+ loops_per_jiffy/(500000/HZ),(loops_per_jiffy/(5000/HZ))%100,
+ loops_per_jiffy));
}
diff --git a/arch/m68k/kernel/time.c b/arch/m68k/kernel/time.c
index c58f4eeeb..af22bee5a 100644
--- a/arch/m68k/kernel/time.c
+++ b/arch/m68k/kernel/time.c
@@ -126,13 +126,13 @@ extern rwlock_t xtime_lock;
*/
void do_gettimeofday(struct timeval *tv)
{
- extern volatile unsigned long lost_ticks;
+ extern unsigned long wall_jiffies;
unsigned long flags;
unsigned long usec, sec, lost;
read_lock_irqsave(&xtime_lock, flags);
usec = mach_gettimeoffset();
- lost = lost_ticks;
+ lost = jiffies - wall_jiffies;
if (lost)
usec += lost * (1000000/HZ);
sec = xtime.tv_sec;
diff --git a/arch/m68k/kernel/traps.c b/arch/m68k/kernel/traps.c
index d5d6753cb..3b8f9fe13 100644
--- a/arch/m68k/kernel/traps.c
+++ b/arch/m68k/kernel/traps.c
@@ -152,13 +152,6 @@ void __init trap_init (void)
}
-static inline void console_verbose(void)
-{
- extern int console_loglevel;
- console_loglevel = 15;
-}
-
-
static char *vec_names[] = {
"RESET SP", "RESET PC", "BUS ERROR", "ADDRESS ERROR",
"ILLEGAL INSTRUCTION", "ZERO DIVIDE", "CHK", "TRAPcc",
diff --git a/arch/m68k/lib/Makefile b/arch/m68k/lib/Makefile
index 7d2dc0243..fa3c3d0b5 100644
--- a/arch/m68k/lib/Makefile
+++ b/arch/m68k/lib/Makefile
@@ -7,7 +7,7 @@
L_TARGET = lib.a
-obj-y := ashrdi3.o lshrdi3.o checksum.o memcpy.o memcmp.o memset.o \
- semaphore.o muldi3.o
+obj-y := ashldi3.o ashrdi3.o lshrdi3.o muldi3.o \
+ checksum.o memcmp.o memcpy.o memset.o semaphore.o
include $(TOPDIR)/Rules.make
diff --git a/arch/m68k/lib/ashldi3.c b/arch/m68k/lib/ashldi3.c
new file mode 100644
index 000000000..008403eb8
--- /dev/null
+++ b/arch/m68k/lib/ashldi3.c
@@ -0,0 +1,62 @@
+/* ashrdi3.c extracted from gcc-2.95.2/libgcc2.c which is: */
+/* Copyright (C) 1989, 92-98, 1999 Free Software Foundation, Inc.
+
+This file is part of GNU CC.
+
+GNU CC is free software; you can redistribute it and/or modify
+it under the terms of the GNU General Public License as published by
+the Free Software Foundation; either version 2, or (at your option)
+any later version.
+
+GNU CC is distributed in the hope that it will be useful,
+but WITHOUT ANY WARRANTY; without even the implied warranty of
+MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+GNU General Public License for more details.
+
+You should have received a copy of the GNU General Public License
+along with GNU CC; see the file COPYING. If not, write to
+the Free Software Foundation, 59 Temple Place - Suite 330,
+Boston, MA 02111-1307, USA. */
+
+#define BITS_PER_UNIT 8
+
+typedef int SItype __attribute__ ((mode (SI)));
+typedef unsigned int USItype __attribute__ ((mode (SI)));
+typedef int DItype __attribute__ ((mode (DI)));
+typedef int word_type __attribute__ ((mode (__word__)));
+
+struct DIstruct {SItype high, low;};
+
+typedef union
+{
+ struct DIstruct s;
+ DItype ll;
+} DIunion;
+
+DItype
+__ashldi3 (DItype u, word_type b)
+{
+ DIunion w;
+ word_type bm;
+ DIunion uu;
+
+ if (b == 0)
+ return u;
+
+ uu.ll = u;
+
+ bm = (sizeof (SItype) * BITS_PER_UNIT) - b;
+ if (bm <= 0)
+ {
+ w.s.low = 0;
+ w.s.high = (USItype)uu.s.low << -bm;
+ }
+ else
+ {
+ USItype carries = (USItype)uu.s.low >> bm;
+ w.s.low = (USItype)uu.s.low << b;
+ w.s.high = ((USItype)uu.s.high << b) | carries;
+ }
+
+ return w.ll;
+}
diff --git a/arch/m68k/mm/fault.c b/arch/m68k/mm/fault.c
index 8dc87ebc1..bc27a1722 100644
--- a/arch/m68k/mm/fault.c
+++ b/arch/m68k/mm/fault.c
@@ -26,7 +26,9 @@ int send_fault_sig(struct pt_regs *regs)
siginfo.si_signo = current->thread.signo;
siginfo.si_code = current->thread.code;
siginfo.si_addr = (void *)current->thread.faddr;
+#ifdef DEBUG
printk("send_fault_sig: %p,%d,%d\n", siginfo.si_addr, siginfo.si_signo, siginfo.si_code);
+#endif
if (user_mode(regs)) {
force_sig_info(siginfo.si_signo,