azt1605.c 2.7 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192
  1. /*
  2. * Aztech AZT1605 Driver
  3. * Copyright (C) 2007,2010 Rene Herman
  4. *
  5. * This program is free software: you can redistribute it and/or modify
  6. * it under the terms of the GNU General Public License as published by
  7. * the Free Software Foundation, either version 2 of the License, or
  8. * (at your option) any later version.
  9. *
  10. * This program is distributed in the hope that it will be useful,
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  13. * GNU General Public License for more details.
  14. *
  15. * You should have received a copy of the GNU General Public License
  16. * along with this program. If not, see <http://www.gnu.org/licenses/>.
  17. *
  18. */
  19. #define AZT1605
  20. #define CRD_NAME "Aztech AZT1605"
  21. #define DRV_NAME "AZT1605"
  22. #define DEV_NAME "azt1605"
  23. #define GALAXY_DSP_MAJOR 2
  24. #define GALAXY_DSP_MINOR 1
  25. #define GALAXY_CONFIG_SIZE 3
  26. /*
  27. * 24-bit config register
  28. */
  29. #define GALAXY_CONFIG_SBA_220 (0 << 0)
  30. #define GALAXY_CONFIG_SBA_240 (1 << 0)
  31. #define GALAXY_CONFIG_SBA_260 (2 << 0)
  32. #define GALAXY_CONFIG_SBA_280 (3 << 0)
  33. #define GALAXY_CONFIG_SBA_MASK GALAXY_CONFIG_SBA_280
  34. #define GALAXY_CONFIG_MPUA_300 (0 << 2)
  35. #define GALAXY_CONFIG_MPUA_330 (1 << 2)
  36. #define GALAXY_CONFIG_MPU_ENABLE (1 << 3)
  37. #define GALAXY_CONFIG_GAME_ENABLE (1 << 4)
  38. #define GALAXY_CONFIG_CD_PANASONIC (1 << 5)
  39. #define GALAXY_CONFIG_CD_MITSUMI (1 << 6)
  40. #define GALAXY_CONFIG_CD_MASK (\
  41. GALAXY_CONFIG_CD_PANASONIC | GALAXY_CONFIG_CD_MITSUMI)
  42. #define GALAXY_CONFIG_UNUSED (1 << 7)
  43. #define GALAXY_CONFIG_UNUSED_MASK GALAXY_CONFIG_UNUSED
  44. #define GALAXY_CONFIG_SBIRQ_2 (1 << 8)
  45. #define GALAXY_CONFIG_SBIRQ_3 (1 << 9)
  46. #define GALAXY_CONFIG_SBIRQ_5 (1 << 10)
  47. #define GALAXY_CONFIG_SBIRQ_7 (1 << 11)
  48. #define GALAXY_CONFIG_MPUIRQ_2 (1 << 12)
  49. #define GALAXY_CONFIG_MPUIRQ_3 (1 << 13)
  50. #define GALAXY_CONFIG_MPUIRQ_5 (1 << 14)
  51. #define GALAXY_CONFIG_MPUIRQ_7 (1 << 15)
  52. #define GALAXY_CONFIG_WSSA_530 (0 << 16)
  53. #define GALAXY_CONFIG_WSSA_604 (1 << 16)
  54. #define GALAXY_CONFIG_WSSA_E80 (2 << 16)
  55. #define GALAXY_CONFIG_WSSA_F40 (3 << 16)
  56. #define GALAXY_CONFIG_WSS_ENABLE (1 << 18)
  57. #define GALAXY_CONFIG_CDIRQ_11 (1 << 19)
  58. #define GALAXY_CONFIG_CDIRQ_12 (1 << 20)
  59. #define GALAXY_CONFIG_CDIRQ_15 (1 << 21)
  60. #define GALAXY_CONFIG_CDIRQ_MASK (\
  61. GALAXY_CONFIG_CDIRQ_11 | GALAXY_CONFIG_CDIRQ_12 |\
  62. GALAXY_CONFIG_CDIRQ_15)
  63. #define GALAXY_CONFIG_CDDMA_DISABLE (0 << 22)
  64. #define GALAXY_CONFIG_CDDMA_0 (1 << 22)
  65. #define GALAXY_CONFIG_CDDMA_1 (2 << 22)
  66. #define GALAXY_CONFIG_CDDMA_3 (3 << 22)
  67. #define GALAXY_CONFIG_CDDMA_MASK GALAXY_CONFIG_CDDMA_3
  68. #define GALAXY_CONFIG_MASK (\
  69. GALAXY_CONFIG_SBA_MASK | GALAXY_CONFIG_CD_MASK |\
  70. GALAXY_CONFIG_UNUSED_MASK | GALAXY_CONFIG_CDIRQ_MASK |\
  71. GALAXY_CONFIG_CDDMA_MASK)
  72. #include "galaxy.c"