summaryrefslogtreecommitdiff
path: root/include/asm-parisc
diff options
context:
space:
mode:
authorMatthew Wilcox <willy@debian.org>2003-06-15 07:10:47 -0700
committerLinus Torvalds <torvalds@home.transmeta.com>2003-06-15 07:10:47 -0700
commit9ff05b1bdf4cfa7dc41fe7d878a780d35196a87d (patch)
tree612687a570b6f879cb292ec5e11d7dff99e389b3 /include/asm-parisc
parent20904d2543057fef12c928764922e1d190c2c455 (diff)
[PATCH] parisc arch update
This update covers a lot of changes to arch/parisc and parisc-specific drivers. - irq_return_t changes - more work on the module loader (James Bottomley) - rewrite of led.c by Helge Deller - many miscellaneous updates
Diffstat (limited to 'include/asm-parisc')
-rw-r--r--include/asm-parisc/compat.h9
-rw-r--r--include/asm-parisc/elf.h11
-rw-r--r--include/asm-parisc/fixmap.h9
-rw-r--r--include/asm-parisc/module.h8
-rw-r--r--include/asm-parisc/pdc_chassis.h2
-rw-r--r--include/asm-parisc/pgtable.h18
-rw-r--r--include/asm-parisc/processor.h1
-rw-r--r--include/asm-parisc/timex.h1
-rw-r--r--include/asm-parisc/unistd.h1
9 files changed, 48 insertions, 12 deletions
diff --git a/include/asm-parisc/compat.h b/include/asm-parisc/compat.h
index 3a3ac178498d..f888716df94f 100644
--- a/include/asm-parisc/compat.h
+++ b/include/asm-parisc/compat.h
@@ -4,6 +4,7 @@
* Architecture specific compatibility types
*/
#include <linux/types.h>
+#include <linux/sched.h>
#define COMPAT_USER_HZ 100
@@ -124,4 +125,12 @@ static inline void *compat_ptr(compat_uptr_t uptr)
return (void *)(unsigned long)uptr;
}
+static __inline__ void *compat_alloc_user_space(long len)
+{
+ struct pt_regs *regs = &current->thread.regs;
+ unsigned long usp = regs->gr[30];
+
+ return (void *)(usp + len);
+}
+
#endif /* _ASM_PARISC_COMPAT_H */
diff --git a/include/asm-parisc/elf.h b/include/asm-parisc/elf.h
index b1d2eaa70e1b..b9f6090b78f2 100644
--- a/include/asm-parisc/elf.h
+++ b/include/asm-parisc/elf.h
@@ -178,10 +178,11 @@
#define PF_HP_SBP 0x08000000
/*
- * The following definitions are those for 32-bit ELF binaries on a 32-bit kernel
- * and for 64-bit binaries on a 64-bit kernel. To run 32-bit binaries on a 64-bit
- * kernel, arch/parisc64/kernel/binfmt_elf32.c defines these macros appropriately
- * and then #includes binfmt_elf.c, which then includes this file.
+ * The following definitions are those for 32-bit ELF binaries on a 32-bit
+ * kernel and for 64-bit binaries on a 64-bit kernel. To run 32-bit binaries
+ * on a 64-bit kernel, arch/parisc64/kernel/binfmt_elf32.c defines these
+ * macros appropriately and then #includes binfmt_elf.c, which then includes
+ * this file.
*/
#ifndef ELF_CLASS
@@ -267,6 +268,8 @@ typedef elf_greg_t elf_gregset_t[ELF_NGREG];
typedef double elf_fpreg_t;
typedef elf_fpreg_t elf_fpregset_t[ELF_NFPREG];
+struct task_struct;
+
extern int dump_task_fpu (struct task_struct *, elf_fpregset_t *);
#define ELF_CORE_COPY_FPREGS(tsk, elf_fpregs) dump_task_fpu(tsk, elf_fpregs)
diff --git a/include/asm-parisc/fixmap.h b/include/asm-parisc/fixmap.h
index cbf916e4569b..52fc100f6b79 100644
--- a/include/asm-parisc/fixmap.h
+++ b/include/asm-parisc/fixmap.h
@@ -4,9 +4,16 @@
/*
* Allocate a 8 Mb temporary mapping area for copy_user_page/clear_user_page.
* This area needs to be aligned on a 8 Mb boundary.
+ *
+ * FIXME:
+ *
+ * For PA-RISC, this has no meaning. It is starting to be used on x86
+ * for vsyscalls. PA will probably do this using space registers.
*/
+/* This TMPALIAS_MAP_START reserves some of the memory where the
+ * FIXMAP region is on x86. It's only real use is to constrain
+ * VMALLOC_END (see pktable.h) */
#define TMPALIAS_MAP_START (__PAGE_OFFSET - 0x01000000)
-#define FIXADDR_START ((unsigned long)TMPALIAS_MAP_START)
#endif
diff --git a/include/asm-parisc/module.h b/include/asm-parisc/module.h
index acf6770cd5d3..22c916b738f0 100644
--- a/include/asm-parisc/module.h
+++ b/include/asm-parisc/module.h
@@ -24,10 +24,10 @@
struct mod_arch_specific
{
- unsigned long got_offset;
- unsigned long fdesc_offset, fdesc_count;
- unsigned long stub_offset;
- unsigned long stub_count;
+ unsigned long got_offset, got_count, got_max;
+ unsigned long fdesc_offset, fdesc_count, fdesc_max;
+ unsigned long stub_offset, stub_count, stub_max;
+ unsigned long init_stub_offset, init_stub_count, init_stub_max;
};
#endif /* _ASM_PARISC_MODULE_H */
diff --git a/include/asm-parisc/pdc_chassis.h b/include/asm-parisc/pdc_chassis.h
index df844ae34916..7378770f02eb 100644
--- a/include/asm-parisc/pdc_chassis.h
+++ b/include/asm-parisc/pdc_chassis.h
@@ -35,7 +35,7 @@
*/
int pdc_chassis_send_status(int message);
-void __init parisc_pdc_chassis_init(void);
+void parisc_pdc_chassis_init(void);
/*
diff --git a/include/asm-parisc/pgtable.h b/include/asm-parisc/pgtable.h
index 32b19f8bafa7..0262435e1514 100644
--- a/include/asm-parisc/pgtable.h
+++ b/include/asm-parisc/pgtable.h
@@ -109,7 +109,8 @@ extern void *vmalloc_start;
#define PCXL_DMA_MAP_SIZE (8*1024*1024)
#define VMALLOC_START ((unsigned long)vmalloc_start)
#define VMALLOC_VMADDR(x) ((unsigned long)(x))
-#define VMALLOC_END (FIXADDR_START)
+/* this is a fixmap remnant, see fixmap.h */
+#define VMALLOC_END (TMPALIAS_MAP_START)
#endif
/* NB: The tlb miss handlers make certain assumptions about the order */
@@ -122,6 +123,7 @@ extern void *vmalloc_start;
#define _PAGE_GATEWAY_BIT 28 /* (0x008) privilege promotion allowed */
#define _PAGE_DMB_BIT 27 /* (0x010) Data Memory Break enable (B bit) */
#define _PAGE_DIRTY_BIT 26 /* (0x020) Page Dirty (D bit) */
+#define _PAGE_FILE_BIT _PAGE_DIRTY_BIT /* overload this bit */
#define _PAGE_REFTRAP_BIT 25 /* (0x040) Page Ref. Trap enable (T bit) */
#define _PAGE_NO_CACHE_BIT 24 /* (0x080) Uncached Page (U bit) */
#define _PAGE_ACCESSED_BIT 23 /* (0x100) Software: Page Accessed */
@@ -135,6 +137,17 @@ extern void *vmalloc_start;
#define xlate_pabit(x) (31 - x)
+/* this defines the shift to the usable bits in the PTE it is set so
+ * that the valid bits _PAGE_PRESENT_BIT and _PAGE_USER_BIT are set
+ * to zero */
+#define PTE_SHIFT xlate_pabit(_PAGE_USER_BIT)
+
+/* this is how many bits may be used by the file functions */
+#define PTE_FILE_MAX_BITS (BITS_PER_LONG - PTE_SHIFT)
+
+#define pte_to_pgoff(pte) (pte_val(pte) >> PTE_SHIFT)
+#define pgoff_to_pte(off) ((pte_t) { ((off) << PTE_SHIFT) | _PAGE_FILE })
+
#define _PAGE_READ (1 << xlate_pabit(_PAGE_READ_BIT))
#define _PAGE_WRITE (1 << xlate_pabit(_PAGE_WRITE_BIT))
#define _PAGE_RW (_PAGE_READ | _PAGE_WRITE)
@@ -148,6 +161,7 @@ extern void *vmalloc_start;
#define _PAGE_PRESENT (1 << xlate_pabit(_PAGE_PRESENT_BIT))
#define _PAGE_FLUSH (1 << xlate_pabit(_PAGE_FLUSH_BIT))
#define _PAGE_USER (1 << xlate_pabit(_PAGE_USER_BIT))
+#define _PAGE_FILE (1 << xlate_pabit(_PAGE_FILE_BIT))
#define _PAGE_TABLE (_PAGE_PRESENT | _PAGE_READ | _PAGE_WRITE | _PAGE_DIRTY | _PAGE_ACCESSED)
#define _PAGE_CHG_MASK (PAGE_MASK | _PAGE_ACCESSED | _PAGE_DIRTY)
@@ -256,6 +270,8 @@ extern inline int pte_read(pte_t pte) { return pte_val(pte) & _PAGE_READ; }
extern inline int pte_dirty(pte_t pte) { return pte_val(pte) & _PAGE_DIRTY; }
extern inline int pte_young(pte_t pte) { return pte_val(pte) & _PAGE_ACCESSED; }
extern inline int pte_write(pte_t pte) { return pte_val(pte) & _PAGE_WRITE; }
+extern inline int pte_file(pte_t pte) { return pte_val(pte) & _PAGE_FILE; }
+extern inline int pte_user(pte_t pte) { return pte_val(pte) & _PAGE_USER; }
extern inline pte_t pte_rdprotect(pte_t pte) { pte_val(pte) &= ~_PAGE_READ; return pte; }
extern inline pte_t pte_mkclean(pte_t pte) { pte_val(pte) &= ~_PAGE_DIRTY; return pte; }
diff --git a/include/asm-parisc/processor.h b/include/asm-parisc/processor.h
index 30bdf987b3a5..55c38a184b8c 100644
--- a/include/asm-parisc/processor.h
+++ b/include/asm-parisc/processor.h
@@ -92,6 +92,7 @@ struct cpuinfo_parisc {
unsigned long fp_model;
unsigned int state;
struct parisc_device *dev;
+ unsigned long loops_per_jiffy;
};
extern struct system_cpuinfo_parisc boot_cpu_data;
diff --git a/include/asm-parisc/timex.h b/include/asm-parisc/timex.h
index 3808765c841a..a228b9167321 100644
--- a/include/asm-parisc/timex.h
+++ b/include/asm-parisc/timex.h
@@ -7,7 +7,6 @@
#define _ASMPARISC_TIMEX_H
#include <asm/system.h>
-#include <linux/time.h>
#define CLOCK_TICK_RATE 1193180 /* Underlying HZ */
diff --git a/include/asm-parisc/unistd.h b/include/asm-parisc/unistd.h
index 9aa3ef58c78b..410a871f910c 100644
--- a/include/asm-parisc/unistd.h
+++ b/include/asm-parisc/unistd.h
@@ -720,6 +720,7 @@
#define __NR_epoll_ctl (__NR_Linux + 225)
#define __NR_epoll_wait (__NR_Linux + 226)
#define __NR_remap_file_pages (__NR_Linux + 227)
+#define __NR_semtimedop (__NR_Linux + 228)
#define __NR_Linux_syscalls 228