1 /* $Id: vaddrs.h,v 1.15 1995/11/25 02:33:20 davem Exp $ */ 2 #ifndef _SPARC_VADDRS_H 3 #define _SPARC_VADDRS_H 4 5 #include <asm/head.h> 6 7 /* asm-sparc/vaddrs.h: Here will be define the virtual addresses at 8 * which important I/O addresses will be mapped. 9 * For instance the timer register virtual address 10 * is defined here. 11 * 12 * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu) 13 */ 14 15 /* I can see only one reason why we should have statically defined 16 * mappings for devices and is the speedup improvements of not loading 17 * a pointer and then the value in the assembly code 18 */ 19 20 #define AUXIO_VADDR (KERNBASE+0x6000) /* Auxiliary IO register */ 21 #define TIMER_VADDR (AUXIO_VADDR+0x1000) /* One page after AUXIO, length is 22 * 5 pages which is needed on sun4m. 23 */ 24 #define INTREG_VADDR (TIMER_VADDR+0x5000) 25 26 #define IOBASE_VADDR 0xfe000000 /* Base for mapping pages */ 27 #define IOBASE_LEN 0x00100000 /* Length of the IO area */ 28 #define IOBASE_END 0xfe100000 29 #define DVMA_VADDR 0xfff00000 /* Base area of the DVMA on suns */ 30 #define DVMA_LEN 0x00040000 /* Size of the DVMA address space */ 31 #define DVMA_END 0xfff40000 32 33 /* On sun4m machines we need per-cpu virtual areas */ 34 #define PERCPU_VADDR 0xff000000 /* Base for per-cpu virtual mappings */ 35 #define PERCPU_ENTSIZE 0x00100000 36 #define PERCPU_LEN ((PERCPU_ENTSIZE*NCPUS)) 37 38 /* per-cpu offsets */ 39 #define PERCPU_TBR_OFFSET 0x00000 /* %tbr, mainly used for identification. */ 40 #define PERCPU_KSTACK_OFFSET 0x01000 /* Beginning of kernel stack for this cpu */ 41 #define PERCPU_MBOX_OFFSET 0x02000 /* Prom SMP Mailbox */ 42 #define PERCPU_CPUID_OFFSET 0x03000 /* Per-cpu ID number. */ 43 #define PERCPU_ISALIVE_OFFSET 0x03004 /* Has CPU been initted yet? */ 44 #define PERCPU_ISIDLING_OFFSET 0x03008 /* Is CPU in idle loop spinning? */ 45 46 #endif /* !(_SPARC_VADDRS_H) */