vaddrs.h 2.3 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970
  1. /* $Id: vaddrs.h,v 1.27 2001/07/04 00:18:18 davem Exp $ */
  2. #ifndef _SPARC_VADDRS_H
  3. #define _SPARC_VADDRS_H
  4. #include <asm/head.h>
  5. /*
  6. * asm-sparc/vaddrs.h: Here we define the virtual addresses at
  7. * which important things will be mapped.
  8. *
  9. * Copyright (C) 1995 David S. Miller (davem@caip.rutgers.edu)
  10. * Copyright (C) 2000 Anton Blanchard (anton@samba.org)
  11. */
  12. #define SRMMU_MAXMEM 0x0c000000
  13. #define SRMMU_NOCACHE_VADDR (KERNBASE + SRMMU_MAXMEM)
  14. /* = 0x0fc000000 */
  15. /* XXX Empiricals - this needs to go away - KMW */
  16. #define SRMMU_MIN_NOCACHE_PAGES (550)
  17. #define SRMMU_MAX_NOCACHE_PAGES (1280)
  18. /* The following constant is used in mm/srmmu.c::srmmu_nocache_calcsize()
  19. * to determine the amount of memory that will be reserved as nocache:
  20. *
  21. * 256 pages will be taken as nocache per each
  22. * SRMMU_NOCACHE_ALCRATIO MB of system memory.
  23. *
  24. * limits enforced: nocache minimum = 256 pages
  25. * nocache maximum = 1280 pages
  26. */
  27. #define SRMMU_NOCACHE_ALCRATIO 64 /* 256 pages per 64MB of system RAM */
  28. #define SUN4M_IOBASE_VADDR 0xfd000000 /* Base for mapping pages */
  29. #define IOBASE_VADDR 0xfe000000
  30. #define IOBASE_END 0xfe600000
  31. #define VMALLOC_START 0xfe600000
  32. /* XXX Alter this when I get around to fixing sun4c - Anton */
  33. #define VMALLOC_END 0xffc00000
  34. /*
  35. * On the sun4/4c we need a place
  36. * to reliably map locked down kernel data. This includes the
  37. * task_struct and kernel stack pages of each process plus the
  38. * scsi buffers during dvma IO transfers, also the floppy buffers
  39. * during pseudo dma which runs with traps off (no faults allowed).
  40. * Some quick calculations yield:
  41. * NR_TASKS <512> * (3 * PAGE_SIZE) == 0x600000
  42. * Subtract this from 0xc00000 and you get 0x927C0 of vm left
  43. * over to map SCSI dvma + floppy pseudo-dma buffers. So be
  44. * careful if you change NR_TASKS or else there won't be enough
  45. * room for it all.
  46. */
  47. #define SUN4C_LOCK_VADDR 0xff000000
  48. #define SUN4C_LOCK_END 0xffc00000
  49. #define KADB_DEBUGGER_BEGVM 0xffc00000 /* Where kern debugger is in virt-mem */
  50. #define KADB_DEBUGGER_ENDVM 0xffd00000
  51. #define DEBUG_FIRSTVADDR KADB_DEBUGGER_BEGVM
  52. #define DEBUG_LASTVADDR KADB_DEBUGGER_ENDVM
  53. #define LINUX_OPPROM_BEGVM 0xffd00000
  54. #define LINUX_OPPROM_ENDVM 0xfff00000
  55. #define DVMA_VADDR 0xfff00000 /* Base area of the DVMA on suns */
  56. #define DVMA_END 0xfffc0000
  57. #endif /* !(_SPARC_VADDRS_H) */