diff options
Diffstat (limited to 'include/asm-m68k')
-rw-r--r-- | include/asm-m68k/contregs.h | 4 | ||||
-rw-r--r-- | include/asm-m68k/dvma.h | 16 | ||||
-rw-r--r-- | include/asm-m68k/fbio.h | 1 | ||||
-rw-r--r-- | include/asm-m68k/hardirq.h | 1 | ||||
-rw-r--r-- | include/asm-m68k/ide.h | 17 | ||||
-rw-r--r-- | include/asm-m68k/idprom.h | 8 | ||||
-rw-r--r-- | include/asm-m68k/intersil.h | 2 | ||||
-rw-r--r-- | include/asm-m68k/kbio.h | 1 | ||||
-rw-r--r-- | include/asm-m68k/mmu.h | 7 | ||||
-rw-r--r-- | include/asm-m68k/mmu_context.h | 25 | ||||
-rw-r--r-- | include/asm-m68k/processor.h | 1 | ||||
-rw-r--r-- | include/asm-m68k/semaphore-helper.h | 4 | ||||
-rw-r--r-- | include/asm-m68k/vuid_event.h | 4 |
13 files changed, 51 insertions, 40 deletions
diff --git a/include/asm-m68k/contregs.h b/include/asm-m68k/contregs.h new file mode 100644 index 000000000..1e233e7d1 --- /dev/null +++ b/include/asm-m68k/contregs.h @@ -0,0 +1,4 @@ +#ifndef _M68K_CONTREGS_H +#define _M68K_CONTREGS_H +#include <asm-sparc/contregs.h> +#endif /* _M68K_CONTREGS_H */ diff --git a/include/asm-m68k/dvma.h b/include/asm-m68k/dvma.h index b350911c6..afcb9b22b 100644 --- a/include/asm-m68k/dvma.h +++ b/include/asm-m68k/dvma.h @@ -14,18 +14,28 @@ #ifdef CONFIG_SUN3 /* sun3 dvma page support */ -/* memory and pmegs reserved for dvma */ +#define DVMA_RESERVED_PMEGS 2 /* 256k of dvma */ + +/* memory and pmegs potentially reserved for dvma */ #define DVMA_PMEG_START 10 #define DVMA_PMEG_END 16 #define DVMA_START 0xff00000 #define DVMA_END 0xffe0000 #define DVMA_SIZE (DVMA_END-DVMA_START) +/* empirical kludge -- dvma regions only seem to work right on 0x10000 + byte boundries */ +#define DVMA_REGION_SIZE 0x10000 +#define DVMA_ALIGN(addr) (((addr)+DVMA_REGION_SIZE-1) & \ + ~(DVMA_REGION_SIZE-1)) + + /* virt <-> phys conversions */ #define sun3_dvma_vtop(x) ((unsigned long)(x) & 0xffffff) #define sun3_dvma_ptov(x) ((unsigned long)(x) | 0xf000000) - -void *sun3_dvma_malloc(int len); + +extern void sun3_dvma_init(void); +extern void *sun3_dvma_malloc(int len); #else /* Sun3x */ /* Structure to describe the current status of DMA registers on the Sparc */ diff --git a/include/asm-m68k/fbio.h b/include/asm-m68k/fbio.h new file mode 100644 index 000000000..c17edf8c7 --- /dev/null +++ b/include/asm-m68k/fbio.h @@ -0,0 +1 @@ +#include <asm-sparc/fbio.h> diff --git a/include/asm-m68k/hardirq.h b/include/asm-m68k/hardirq.h index 8a1e6a445..615e0df01 100644 --- a/include/asm-m68k/hardirq.h +++ b/include/asm-m68k/hardirq.h @@ -2,6 +2,7 @@ #define __M68K_HARDIRQ_H #include <linux/threads.h> +#include <linux/cache.h> /* entry.S is sensitive to the offsets of these fields */ typedef struct { diff --git a/include/asm-m68k/ide.h b/include/asm-m68k/ide.h index 5ef14f29e..2031774a5 100644 --- a/include/asm-m68k/ide.h +++ b/include/asm-m68k/ide.h @@ -50,28 +50,21 @@ #define MAX_HWIFS 4 /* same as the other archs */ #endif -int q40ide_default_irq(q40ide_ioreg_t); static __inline__ int ide_default_irq(ide_ioreg_t base) { - if (MACH_IS_Q40) - return q40ide_default_irq((q40ide_ioreg_t) base); - else return 0; + return 0; } -int q40ide_default_io_base(int); - static __inline__ ide_ioreg_t ide_default_io_base(int index) { - if (MACH_IS_Q40) - return (ide_ioreg_t)q40ide_default_io_base(index); - else return 0; + return 0; } /* * Can we do this in a generic manner?? */ -void q40_ide_init_hwif_ports (hw_regs_t *hw, q40ide_ioreg_t data_port, q40ide_ioreg_t ctrl_port, int *irq); + /* * Set up a hw structure for a specified data port, control port and IRQ. @@ -79,10 +72,6 @@ void q40_ide_init_hwif_ports (hw_regs_t *hw, q40ide_ioreg_t data_port, q40ide_io */ static __inline__ void ide_init_hwif_ports(hw_regs_t *hw, ide_ioreg_t data_port, ide_ioreg_t ctrl_port, int *irq) { -#ifdef CONFIG_Q40 - if (MACH_IS_Q40) - return q40_ide_init_hwif_ports(hw, (q40ide_ioreg_t) data_port, (q40ide_ioreg_t) ctrl_port, irq); -#endif if (data_port || ctrl_port) printk("ide_init_hwif_ports: must not be called\n"); } diff --git a/include/asm-m68k/idprom.h b/include/asm-m68k/idprom.h new file mode 100644 index 000000000..4349eaf3c --- /dev/null +++ b/include/asm-m68k/idprom.h @@ -0,0 +1,8 @@ +#ifndef _M68K_IDPROM_H +#define _M68K_IDPROM_H +#include <asm-sparc/idprom.h> + +/* Sun3: in control space */ +#define SUN3_IDPROM_BASE 0x00000000 + +#endif /* !(_M68K_IDPROM_H) */ diff --git a/include/asm-m68k/intersil.h b/include/asm-m68k/intersil.h index e039ea320..ea2a5b572 100644 --- a/include/asm-m68k/intersil.h +++ b/include/asm-m68k/intersil.h @@ -11,7 +11,7 @@ #define INTERSIL_24H_MODE 0x04 /* bit 3 */ -#define INTESIL_STOP 0x00 +#define INTERSIL_STOP 0x00 #define INTERSIL_RUN 0x08 /* bit 4 */ diff --git a/include/asm-m68k/kbio.h b/include/asm-m68k/kbio.h new file mode 100644 index 000000000..e1fbf8fba --- /dev/null +++ b/include/asm-m68k/kbio.h @@ -0,0 +1 @@ +#include <asm-sparc/kbio.h> diff --git a/include/asm-m68k/mmu.h b/include/asm-m68k/mmu.h new file mode 100644 index 000000000..ccd36d266 --- /dev/null +++ b/include/asm-m68k/mmu.h @@ -0,0 +1,7 @@ +#ifndef __MMU_H +#define __MMU_H + +/* Default "unsigned long" context */ +typedef unsigned long mm_context_t; + +#endif diff --git a/include/asm-m68k/mmu_context.h b/include/asm-m68k/mmu_context.h index 003933fae..0e7dcd886 100644 --- a/include/asm-m68k/mmu_context.h +++ b/include/asm-m68k/mmu_context.h @@ -3,15 +3,16 @@ #include <linux/config.h> +static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_struct *tsk, unsigned cpu) +{ +} + #ifndef CONFIG_SUN3 #include <asm/setup.h> #include <asm/page.h> #include <asm/pgalloc.h> -static inline void enter_lazy_tlb(struct mm_struct *mm, struct task_struct *tsk, unsigned cpu) -{ -} extern inline int init_new_context(struct task_struct *tsk, struct mm_struct *mm) { @@ -105,8 +106,6 @@ extern inline void activate_mm(struct mm_struct *prev_mm, extern unsigned long get_free_context(struct mm_struct *mm); extern void clear_context(unsigned long context); -extern unsigned char ctx_next_to_die; -extern unsigned char ctx_live[SUN3_CONTEXTS_NUM]; /* set the context for a new task to unmapped */ static inline int init_new_context(struct task_struct *tsk, struct mm_struct *mm) @@ -123,28 +122,12 @@ static inline void get_mmu_context(struct mm_struct *mm) mm->context = get_free_context(mm); } -#if 0 -/* we used to clear the context after the process exited. we still - should, things are faster that way... but very unstable. so just - clear out a context next time we need a new one.. consider this a - FIXME. */ - /* flush context if allocated... */ static inline void destroy_context(struct mm_struct *mm) { if(mm->context != SUN3_INVALID_CONTEXT) clear_context(mm->context); } -#else -/* mark this context as dropped and set it for next death */ -static inline void destroy_context(struct mm_struct *mm) -{ - if(mm->context != SUN3_INVALID_CONTEXT) { - ctx_next_to_die = mm->context; - ctx_live[mm->context] = 0; - } -} -#endif static inline void activate_context(struct mm_struct *mm) { diff --git a/include/asm-m68k/processor.h b/include/asm-m68k/processor.h index 1bba1277f..0ad99a7f8 100644 --- a/include/asm-m68k/processor.h +++ b/include/asm-m68k/processor.h @@ -111,7 +111,6 @@ extern int kernel_thread(int (*fn)(void *), void * arg, unsigned long flags); #define copy_segments(tsk, mm) do { } while (0) #define release_segments(mm) do { } while (0) -#define forget_segments() do { } while (0) /* * Free current thread data structures etc.. diff --git a/include/asm-m68k/semaphore-helper.h b/include/asm-m68k/semaphore-helper.h index 0ae0b9705..aa38ab88e 100644 --- a/include/asm-m68k/semaphore-helper.h +++ b/include/asm-m68k/semaphore-helper.h @@ -19,6 +19,10 @@ static inline void wake_one_more(struct semaphore * sem) atomic_inc(&sem->waking); } +#ifndef CONFIG_RMW_INSNS +extern spinlock_t semaphore_wake_lock; +#endif + static inline int waking_non_zero(struct semaphore *sem) { int ret; diff --git a/include/asm-m68k/vuid_event.h b/include/asm-m68k/vuid_event.h new file mode 100644 index 000000000..52ecb521a --- /dev/null +++ b/include/asm-m68k/vuid_event.h @@ -0,0 +1,4 @@ +#ifndef _M68K_VUID_EVENT_H +#define _M68K_VUID_EVENT_H +#include <asm-sparc/vuid_event.h> +#endif |