clcd-regs.h 2.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687
  1. /*
  2. * David A Rusling
  3. *
  4. * Copyright (C) 2001 ARM Limited
  5. *
  6. * This file is subject to the terms and conditions of the GNU General Public
  7. * License. See the file COPYING in the main directory of this archive
  8. * for more details.
  9. */
  10. #ifndef AMBA_CLCD_REGS_H
  11. #define AMBA_CLCD_REGS_H
  12. /*
  13. * CLCD Controller Internal Register addresses
  14. */
  15. #define CLCD_TIM0 0x00000000
  16. #define CLCD_TIM1 0x00000004
  17. #define CLCD_TIM2 0x00000008
  18. #define CLCD_TIM3 0x0000000c
  19. #define CLCD_UBAS 0x00000010
  20. #define CLCD_LBAS 0x00000014
  21. #define CLCD_PL110_IENB 0x00000018
  22. #define CLCD_PL110_CNTL 0x0000001c
  23. #define CLCD_PL110_STAT 0x00000020
  24. #define CLCD_PL110_INTR 0x00000024
  25. #define CLCD_PL110_UCUR 0x00000028
  26. #define CLCD_PL110_LCUR 0x0000002C
  27. #define CLCD_PL111_CNTL 0x00000018
  28. #define CLCD_PL111_IENB 0x0000001c
  29. #define CLCD_PL111_RIS 0x00000020
  30. #define CLCD_PL111_MIS 0x00000024
  31. #define CLCD_PL111_ICR 0x00000028
  32. #define CLCD_PL111_UCUR 0x0000002c
  33. #define CLCD_PL111_LCUR 0x00000030
  34. #define CLCD_PALL 0x00000200
  35. #define CLCD_PALETTE 0x00000200
  36. #define TIM2_PCD_LO_MASK GENMASK(4, 0)
  37. #define TIM2_PCD_LO_BITS 5
  38. #define TIM2_CLKSEL (1 << 5)
  39. #define TIM2_ACB_MASK GENMASK(10, 6)
  40. #define TIM2_IVS (1 << 11)
  41. #define TIM2_IHS (1 << 12)
  42. #define TIM2_IPC (1 << 13)
  43. #define TIM2_IOE (1 << 14)
  44. #define TIM2_BCD (1 << 26)
  45. #define TIM2_PCD_HI_MASK GENMASK(31, 27)
  46. #define TIM2_PCD_HI_BITS 5
  47. #define TIM2_PCD_HI_SHIFT 27
  48. #define CNTL_LCDEN (1 << 0)
  49. #define CNTL_LCDBPP1 (0 << 1)
  50. #define CNTL_LCDBPP2 (1 << 1)
  51. #define CNTL_LCDBPP4 (2 << 1)
  52. #define CNTL_LCDBPP8 (3 << 1)
  53. #define CNTL_LCDBPP16 (4 << 1)
  54. #define CNTL_LCDBPP16_565 (6 << 1)
  55. #define CNTL_LCDBPP16_444 (7 << 1)
  56. #define CNTL_LCDBPP24 (5 << 1)
  57. #define CNTL_LCDBW (1 << 4)
  58. #define CNTL_LCDTFT (1 << 5)
  59. #define CNTL_LCDMONO8 (1 << 6)
  60. #define CNTL_LCDDUAL (1 << 7)
  61. #define CNTL_BGR (1 << 8)
  62. #define CNTL_BEBO (1 << 9)
  63. #define CNTL_BEPO (1 << 10)
  64. #define CNTL_LCDPWR (1 << 11)
  65. #define CNTL_LCDVCOMP(x) ((x) << 12)
  66. #define CNTL_LDMAFIFOTIME (1 << 15)
  67. #define CNTL_WATERMARK (1 << 16)
  68. /* ST Microelectronics variant bits */
  69. #define CNTL_ST_1XBPP_444 0x0
  70. #define CNTL_ST_1XBPP_5551 (1 << 17)
  71. #define CNTL_ST_1XBPP_565 (1 << 18)
  72. #define CNTL_ST_CDWID_12 0x0
  73. #define CNTL_ST_CDWID_16 (1 << 19)
  74. #define CNTL_ST_CDWID_18 (1 << 20)
  75. #define CNTL_ST_CDWID_24 ((1 << 19)|(1 << 20))
  76. #define CNTL_ST_CEAEN (1 << 21)
  77. #define CNTL_ST_LCDBPP24_PACKED (6 << 1)
  78. #endif /* AMBA_CLCD_REGS_H */