pxa2xx-regs.h 4.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384
  1. /*
  2. * linux/include/asm-arm/arch-pxa/pxa2xx-regs.h
  3. *
  4. * Taken from pxa-regs.h by Russell King
  5. *
  6. * Author: Nicolas Pitre
  7. * Copyright: MontaVista Software Inc.
  8. *
  9. * This program is free software; you can redistribute it and/or modify
  10. * it under the terms of the GNU General Public License version 2 as
  11. * published by the Free Software Foundation.
  12. */
  13. #ifndef __PXA2XX_REGS_H
  14. #define __PXA2XX_REGS_H
  15. /*
  16. * Memory controller
  17. */
  18. #define MDCNFG __REG(0x48000000) /* SDRAM Configuration Register 0 */
  19. #define MDREFR __REG(0x48000004) /* SDRAM Refresh Control Register */
  20. #define MSC0 __REG(0x48000008) /* Static Memory Control Register 0 */
  21. #define MSC1 __REG(0x4800000C) /* Static Memory Control Register 1 */
  22. #define MSC2 __REG(0x48000010) /* Static Memory Control Register 2 */
  23. #define MECR __REG(0x48000014) /* Expansion Memory (PCMCIA/Compact Flash) Bus Configuration */
  24. #define SXLCR __REG(0x48000018) /* LCR value to be written to SDRAM-Timing Synchronous Flash */
  25. #define SXCNFG __REG(0x4800001C) /* Synchronous Static Memory Control Register */
  26. #define SXMRS __REG(0x48000024) /* MRS value to be written to Synchronous Flash or SMROM */
  27. #define MCMEM0 __REG(0x48000028) /* Card interface Common Memory Space Socket 0 Timing */
  28. #define MCMEM1 __REG(0x4800002C) /* Card interface Common Memory Space Socket 1 Timing */
  29. #define MCATT0 __REG(0x48000030) /* Card interface Attribute Space Socket 0 Timing Configuration */
  30. #define MCATT1 __REG(0x48000034) /* Card interface Attribute Space Socket 1 Timing Configuration */
  31. #define MCIO0 __REG(0x48000038) /* Card interface I/O Space Socket 0 Timing Configuration */
  32. #define MCIO1 __REG(0x4800003C) /* Card interface I/O Space Socket 1 Timing Configuration */
  33. #define MDMRS __REG(0x48000040) /* MRS value to be written to SDRAM */
  34. #define BOOT_DEF __REG(0x48000044) /* Read-Only Boot-Time Register. Contains BOOT_SEL and PKG_SEL */
  35. /*
  36. * More handy macros for PCMCIA
  37. *
  38. * Arg is socket number
  39. */
  40. #define MCMEM(s) __REG2(0x48000028, (s)<<2 ) /* Card interface Common Memory Space Socket s Timing */
  41. #define MCATT(s) __REG2(0x48000030, (s)<<2 ) /* Card interface Attribute Space Socket s Timing Configuration */
  42. #define MCIO(s) __REG2(0x48000038, (s)<<2 ) /* Card interface I/O Space Socket s Timing Configuration */
  43. /* MECR register defines */
  44. #define MECR_NOS (1 << 0) /* Number Of Sockets: 0 -> 1 sock, 1 -> 2 sock */
  45. #define MECR_CIT (1 << 1) /* Card Is There: 0 -> no card, 1 -> card inserted */
  46. #define MDREFR_K0DB4 (1 << 29) /* SDCLK0 Divide by 4 Control/Status */
  47. #define MDREFR_K2FREE (1 << 25) /* SDRAM Free-Running Control */
  48. #define MDREFR_K1FREE (1 << 24) /* SDRAM Free-Running Control */
  49. #define MDREFR_K0FREE (1 << 23) /* SDRAM Free-Running Control */
  50. #define MDREFR_SLFRSH (1 << 22) /* SDRAM Self-Refresh Control/Status */
  51. #define MDREFR_APD (1 << 20) /* SDRAM/SSRAM Auto-Power-Down Enable */
  52. #define MDREFR_K2DB2 (1 << 19) /* SDCLK2 Divide by 2 Control/Status */
  53. #define MDREFR_K2RUN (1 << 18) /* SDCLK2 Run Control/Status */
  54. #define MDREFR_K1DB2 (1 << 17) /* SDCLK1 Divide by 2 Control/Status */
  55. #define MDREFR_K1RUN (1 << 16) /* SDCLK1 Run Control/Status */
  56. #define MDREFR_E1PIN (1 << 15) /* SDCKE1 Level Control/Status */
  57. #define MDREFR_K0DB2 (1 << 14) /* SDCLK0 Divide by 2 Control/Status */
  58. #define MDREFR_K0RUN (1 << 13) /* SDCLK0 Run Control/Status */
  59. #define MDREFR_E0PIN (1 << 12) /* SDCKE0 Level Control/Status */
  60. #ifdef CONFIG_PXA27x
  61. #define ARB_CNTRL __REG(0x48000048) /* Arbiter Control Register */
  62. #define ARB_DMA_SLV_PARK (1<<31) /* Be parked with DMA slave when idle */
  63. #define ARB_CI_PARK (1<<30) /* Be parked with Camera Interface when idle */
  64. #define ARB_EX_MEM_PARK (1<<29) /* Be parked with external MEMC when idle */
  65. #define ARB_INT_MEM_PARK (1<<28) /* Be parked with internal MEMC when idle */
  66. #define ARB_USB_PARK (1<<27) /* Be parked with USB when idle */
  67. #define ARB_LCD_PARK (1<<26) /* Be parked with LCD when idle */
  68. #define ARB_DMA_PARK (1<<25) /* Be parked with DMA when idle */
  69. #define ARB_CORE_PARK (1<<24) /* Be parked with core when idle */
  70. #define ARB_LOCK_FLAG (1<<23) /* Only Locking masters gain access to the bus */
  71. #endif
  72. #endif