diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1997-06-01 03:16:17 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1997-06-01 03:16:17 +0000 |
commit | d8d9b8f76f22b7a16a83e261e64f89ee611f49df (patch) | |
tree | 3067bc130b80d52808e6390c9fc7fc087ec1e33c /arch/m68k/atari | |
parent | 19c9bba94152148523ba0f7ef7cffe3d45656b11 (diff) |
Initial revision
Diffstat (limited to 'arch/m68k/atari')
-rw-r--r-- | arch/m68k/atari/atafb.c | 5 | ||||
-rw-r--r-- | arch/m68k/atari/ataints.c | 21 | ||||
-rw-r--r-- | arch/m68k/atari/atakeyb.c | 3 | ||||
-rw-r--r-- | arch/m68k/atari/config.c | 21 | ||||
-rw-r--r-- | arch/m68k/atari/joystick.c | 3 | ||||
-rw-r--r-- | arch/m68k/atari/stdma.c | 4 | ||||
-rw-r--r-- | arch/m68k/atari/stram.c | 3 |
7 files changed, 37 insertions, 23 deletions
diff --git a/arch/m68k/atari/atafb.c b/arch/m68k/atari/atafb.c index 64c9a62d3..efa6fc8b8 100644 --- a/arch/m68k/atari/atafb.c +++ b/arch/m68k/atari/atafb.c @@ -46,6 +46,7 @@ #include <linux/tty.h> #include <linux/malloc.h> #include <linux/delay.h> +#include <linux/init.h> #include <asm/setup.h> #include <asm/uaccess.h> @@ -2911,8 +2912,8 @@ atafb_setcmap(struct fb_cmap *cmap, int con) return(atari_fb_set_cmap(cmap, 1, con)); } -struct fb_info * -atari_fb_init(long *mem_start) +__initfunc(struct fb_info * +atari_fb_init(long *mem_start)) { int err; int pad; diff --git a/arch/m68k/atari/ataints.c b/arch/m68k/atari/ataints.c index b65beefb1..b2887f7da 100644 --- a/arch/m68k/atari/ataints.c +++ b/arch/m68k/atari/ataints.c @@ -39,6 +39,7 @@ #include <linux/kernel.h> #include <linux/ptrace.h> #include <linux/kernel_stat.h> +#include <linux/init.h> #include <asm/system.h> #include <asm/traps.h> @@ -162,15 +163,19 @@ static int free_vme_vec_bitmap = 0; #define MFP_MK_BASE "0xfa13" -/* This must agree with head.S. */ -#define ORIG_DO "0x20" -#define FORMATVEC "0x2E" -#define SR "0x28" +/* This must agree with entry.S. */ +#define ORIG_DO "0x24" +#define FORMATVEC "0x32" +#define SR "0x2C" #define SAVE_ALL \ "clrl %%sp@-;" /* stk_adj */ \ "pea -1:w;" /* orig d0 = -1 */ \ "movel %%d0,%%sp@-;" /* d0 */ \ - "moveml %%d1-%%d5/%%a0-%%a1,%%sp@-" + "moveml %%d1-%%d5/%%a0-%%a2,%%sp@-" +#define GET_CURRENT(tmp) \ + "movel %%sp,"#tmp";" \ + "andw #-8192,"#tmp";" \ + "movel "#tmp",%%a2" #define BUILD_SLOW_IRQ(n) \ asmlinkage void IRQ_NAME(n); \ @@ -180,6 +185,7 @@ __asm__ (ALIGN_STR "\n" \ SYMBOL_NAME_STR(atari_slow_irq_) #n "_handler:\t" \ " addql #1,"SYMBOL_NAME_STR(local_irq_count)"\n" \ SAVE_ALL "\n" \ + GET_CURRENT(%%d0) "\n" \ " andb #~(1<<(" #n "&7))," /* mask this interrupt */ \ "("MFP_MK_BASE"+(((" #n "&8)^8)>>2)+((" #n "&16)<<3)):w\n" \ " bfextu %%sp@("SR"){#5,#3},%%d0\n" /* get old IPL from stack frame */ \ @@ -282,7 +288,8 @@ SYMBOL_NAME_STR(atari_fast_irq_handler) ": orw #0x700,%%sr /* disable all interrupts */ "SYMBOL_NAME_STR(atari_prio_irq_handler) ":\t addql #1,"SYMBOL_NAME_STR(local_irq_count)"\n" - SAVE_ALL " + SAVE_ALL "\n" + GET_CURRENT(%%d0) " /* get vector number from stack frame and convert to source */ bfextu %%sp@(" FORMATVEC "){#4,#10},%%d0 subw #(0x40-8),%%d0 @@ -331,7 +338,7 @@ extern void atari_microwire_cmd( int cmd ); * the atari IRQ handling routines. */ -void atari_init_IRQ(void) +__initfunc(void atari_init_IRQ(void)) { int i; diff --git a/arch/m68k/atari/atakeyb.c b/arch/m68k/atari/atakeyb.c index 4f57cb928..beccf9a84 100644 --- a/arch/m68k/atari/atakeyb.c +++ b/arch/m68k/atari/atakeyb.c @@ -22,6 +22,7 @@ #include <linux/timer.h> #include <linux/kd.h> #include <linux/random.h> +#include <linux/init.h> #include <asm/atariints.h> #include <asm/atarihw.h> @@ -804,7 +805,7 @@ void atari_kbd_leds (unsigned int leds) * Martin Rogge, 20 Aug 1995 */ -int atari_keyb_init(void) +__initfunc(int atari_keyb_init(void)) { /* setup key map */ key_maps[0] = ataplain_map; diff --git a/arch/m68k/atari/config.c b/arch/m68k/atari/config.c index 0d0607da0..3cc2a840a 100644 --- a/arch/m68k/atari/config.c +++ b/arch/m68k/atari/config.c @@ -32,6 +32,7 @@ #include <linux/tty.h> #include <linux/console.h> #include <linux/interrupt.h> +#include <linux/init.h> #include <asm/bootinfo.h> #include <asm/setup.h> @@ -106,7 +107,7 @@ extern void (*kd_mksound)(unsigned int, unsigned int); * a temporary VBR and a vector table for the duration of the test. */ -static int hwreg_present( volatile void *regp ) +__initfunc(static int hwreg_present( volatile void *regp )) { int ret = 0; long save_sp, save_vbr; @@ -132,9 +133,8 @@ static int hwreg_present( volatile void *regp ) } #if 0 -static int hwreg_present_bywrite( volatile void *regp, - unsigned char val ) - +__initfunc(static int +hwreg_present_bywrite(volatile void *regp, unsigned char val)) { int ret; long save_sp, save_vbr; @@ -166,7 +166,7 @@ static int hwreg_present_bywrite( volatile void *regp, /* Basically the same, but writes a value into a word register, protected * by a bus error handler */ -static int hwreg_write( volatile void *regp, unsigned short val ) +__initfunc(static int hwreg_write( volatile void *regp, unsigned short val )) { int ret; long save_sp, save_vbr; @@ -201,7 +201,7 @@ static int hwreg_write( volatile void *regp, unsigned short val ) * should be readable without trouble (from channel A!). */ -static int scc_test( volatile char *ctla ) +__initfunc(static int scc_test( volatile char *ctla )) { if (!hwreg_present( ctla )) return( 0 ); @@ -228,7 +228,7 @@ static int scc_test( volatile char *ctla ) * Parse an Atari-specific record in the bootinfo */ -int atari_parse_bootinfo(const struct bi_record *record) +__initfunc(int atari_parse_bootinfo(const struct bi_record *record)) { int unknown = 0; const u_long *data = record->data; @@ -247,7 +247,7 @@ int atari_parse_bootinfo(const struct bi_record *record) * Setup the Atari configuration info */ -void config_atari(void) +__initfunc(void config_atari(void)) { memset(&atari_hw_present, 0, sizeof(atari_hw_present)); @@ -493,7 +493,8 @@ void config_atari(void) } } -static void atari_sched_init(void (*timer_routine)(int, void *, struct pt_regs *)) +__initfunc(static void +atari_sched_init(void (*timer_routine)(int, void *, struct pt_regs *))) { /* set Timer C data Register */ mfp.tim_dt_c = INT_TICKS; @@ -976,7 +977,7 @@ static void atari_par_console_write (const char *str, unsigned int count) } -static void atari_debug_init(void) +__initfunc(static void atari_debug_init(void)) { #ifdef CONFIG_KGDB /* if the m68k_debug_device is used by the GDB stub, do nothing here */ diff --git a/arch/m68k/atari/joystick.c b/arch/m68k/atari/joystick.c index de6014171..2e33b151f 100644 --- a/arch/m68k/atari/joystick.c +++ b/arch/m68k/atari/joystick.c @@ -11,6 +11,7 @@ #include <linux/errno.h> #include <linux/major.h> #include <linux/poll.h> +#include <linux/init.h> #include <asm/atarikb.h> #include <asm/atari_joystick.h> @@ -128,7 +129,7 @@ struct file_operations atari_joystick_fops = { release_joystick }; -int atari_joystick_init(void) +__initfunc(int atari_joystick_init(void)) { joystick[0].active = joystick[1].active = 0; joystick[0].ready = joystick[1].ready = 0; diff --git a/arch/m68k/atari/stdma.c b/arch/m68k/atari/stdma.c index 247b9f684..9dc82de18 100644 --- a/arch/m68k/atari/stdma.c +++ b/arch/m68k/atari/stdma.c @@ -32,6 +32,8 @@ #include <linux/types.h> #include <linux/genhd.h> #include <linux/sched.h> +#include <linux/init.h> + #include <asm/atari_stdma.h> #include <asm/atariints.h> #include <asm/atarihw.h> @@ -171,7 +173,7 @@ int stdma_islocked(void) * */ -void stdma_init(void) +__initfunc(void stdma_init(void)) { stdma_isr = NULL; request_irq(IRQ_MFP_FDC, stdma_int, IRQ_TYPE_SLOW, diff --git a/arch/m68k/atari/stram.c b/arch/m68k/atari/stram.c index 565b20535..4e5f57bc9 100644 --- a/arch/m68k/atari/stram.c +++ b/arch/m68k/atari/stram.c @@ -149,6 +149,7 @@ atari_stram_free (void *ptr) #else #include <linux/mm.h> +#include <linux/init.h> /* ++roman: * @@ -190,7 +191,7 @@ static unsigned long stram_end; /* Overall end of ST-Ram */ -void atari_stram_init( void ) +__initfunc(void atari_stram_init( void )) { int i; |