cs4281_hwdefs.h 62 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980818283848586878889909192939495969798991001011021031041051061071081091101111121131141151161171181191201211221231241251261271281291301311321331341351361371381391401411421431441451461471481491501511521531541551561571581591601611621631641651661671681691701711721731741751761771781791801811821831841851861871881891901911921931941951961971981992002012022032042052062072082092102112122132142152162172182192202212222232242252262272282292302312322332342352362372382392402412422432442452462472482492502512522532542552562572582592602612622632642652662672682692702712722732742752762772782792802812822832842852862872882892902912922932942952962972982993003013023033043053063073083093103113123133143153163173183193203213223233243253263273283293303313323333343353363373383393403413423433443453463473483493503513523533543553563573583593603613623633643653663673683693703713723733743753763773783793803813823833843853863873883893903913923933943953963973983994004014024034044054064074084094104114124134144154164174184194204214224234244254264274284294304314324334344354364374384394404414424434444454464474484494504514524534544554564574584594604614624634644654664674684694704714724734744754764774784794804814824834844854864874884894904914924934944954964974984995005015025035045055065075085095105115125135145155165175185195205215225235245255265275285295305315325335345355365375385395405415425435445455465475485495505515525535545555565575585595605615625635645655665675685695705715725735745755765775785795805815825835845855865875885895905915925935945955965975985996006016026036046056066076086096106116126136146156166176186196206216226236246256266276286296306316326336346356366376386396406416426436446456466476486496506516526536546556566576586596606616626636646656666676686696706716726736746756766776786796806816826836846856866876886896906916926936946956966976986997007017027037047057067077087097107117127137147157167177187197207217227237247257267277287297307317327337347357367377387397407417427437447457467477487497507517527537547557567577587597607617627637647657667677687697707717727737747757767777787797807817827837847857867877887897907917927937947957967977987998008018028038048058068078088098108118128138148158168178188198208218228238248258268278288298308318328338348358368378388398408418428438448458468478488498508518528538548558568578588598608618628638648658668678688698708718728738748758768778788798808818828838848858868878888898908918928938948958968978988999009019029039049059069079089099109119129139149159169179189199209219229239249259269279289299309319329339349359369379389399409419429439449459469479489499509519529539549559569579589599609619629639649659669679689699709719729739749759769779789799809819829839849859869879889899909919929939949959969979989991000100110021003100410051006100710081009101010111012101310141015101610171018101910201021102210231024102510261027102810291030103110321033103410351036103710381039104010411042104310441045104610471048104910501051105210531054105510561057105810591060106110621063106410651066106710681069107010711072107310741075107610771078107910801081108210831084108510861087108810891090109110921093109410951096109710981099110011011102110311041105110611071108110911101111111211131114111511161117111811191120112111221123112411251126112711281129113011311132113311341135113611371138113911401141114211431144114511461147114811491150115111521153115411551156115711581159116011611162116311641165116611671168116911701171117211731174117511761177117811791180118111821183118411851186118711881189119011911192119311941195119611971198119912001201120212031204120512061207120812091210121112121213121412151216121712181219122012211222122312241225122612271228122912301231123212331234
  1. //****************************************************************************
  2. //
  3. // HWDEFS.H - Definitions of the registers and data structures used by the
  4. // CS4281
  5. //
  6. // Copyright (c) 1999,2000,2001 Crystal Semiconductor Corp.
  7. //
  8. //****************************************************************************
  9. #ifndef _H_HWDEFS
  10. #define _H_HWDEFS
  11. //****************************************************************************
  12. //
  13. // The following define the offsets of the registers located in the PCI
  14. // configuration space of the CS4281 part.
  15. //
  16. //****************************************************************************
  17. #define PCICONFIG_DEVID_VENID 0x00000000L
  18. #define PCICONFIG_STATUS_COMMAND 0x00000004L
  19. #define PCICONFIG_CLASS_REVISION 0x00000008L
  20. #define PCICONFIG_LATENCY_TIMER 0x0000000CL
  21. #define PCICONFIG_BA0 0x00000010L
  22. #define PCICONFIG_BA1 0x00000014L
  23. #define PCICONFIG_SUBSYSID_SUBSYSVENID 0x0000002CL
  24. #define PCICONFIG_INTERRUPT 0x0000003CL
  25. //****************************************************************************
  26. //
  27. // The following define the offsets of the registers accessed via base address
  28. // register zero on the CS4281 part.
  29. //
  30. //****************************************************************************
  31. #define BA0_HISR 0x00000000L
  32. #define BA0_HICR 0x00000008L
  33. #define BA0_HIMR 0x0000000CL
  34. #define BA0_IIER 0x00000010L
  35. #define BA0_HDSR0 0x000000F0L
  36. #define BA0_HDSR1 0x000000F4L
  37. #define BA0_HDSR2 0x000000F8L
  38. #define BA0_HDSR3 0x000000FCL
  39. #define BA0_DCA0 0x00000110L
  40. #define BA0_DCC0 0x00000114L
  41. #define BA0_DBA0 0x00000118L
  42. #define BA0_DBC0 0x0000011CL
  43. #define BA0_DCA1 0x00000120L
  44. #define BA0_DCC1 0x00000124L
  45. #define BA0_DBA1 0x00000128L
  46. #define BA0_DBC1 0x0000012CL
  47. #define BA0_DCA2 0x00000130L
  48. #define BA0_DCC2 0x00000134L
  49. #define BA0_DBA2 0x00000138L
  50. #define BA0_DBC2 0x0000013CL
  51. #define BA0_DCA3 0x00000140L
  52. #define BA0_DCC3 0x00000144L
  53. #define BA0_DBA3 0x00000148L
  54. #define BA0_DBC3 0x0000014CL
  55. #define BA0_DMR0 0x00000150L
  56. #define BA0_DCR0 0x00000154L
  57. #define BA0_DMR1 0x00000158L
  58. #define BA0_DCR1 0x0000015CL
  59. #define BA0_DMR2 0x00000160L
  60. #define BA0_DCR2 0x00000164L
  61. #define BA0_DMR3 0x00000168L
  62. #define BA0_DCR3 0x0000016CL
  63. #define BA0_DLMR 0x00000170L
  64. #define BA0_DLSR 0x00000174L
  65. #define BA0_FCR0 0x00000180L
  66. #define BA0_FCR1 0x00000184L
  67. #define BA0_FCR2 0x00000188L
  68. #define BA0_FCR3 0x0000018CL
  69. #define BA0_FPDR0 0x00000190L
  70. #define BA0_FPDR1 0x00000194L
  71. #define BA0_FPDR2 0x00000198L
  72. #define BA0_FPDR3 0x0000019CL
  73. #define BA0_FCHS 0x0000020CL
  74. #define BA0_FSIC0 0x00000210L
  75. #define BA0_FSIC1 0x00000214L
  76. #define BA0_FSIC2 0x00000218L
  77. #define BA0_FSIC3 0x0000021CL
  78. #define BA0_PCICFG00 0x00000300L
  79. #define BA0_PCICFG04 0x00000304L
  80. #define BA0_PCICFG08 0x00000308L
  81. #define BA0_PCICFG0C 0x0000030CL
  82. #define BA0_PCICFG10 0x00000310L
  83. #define BA0_PCICFG14 0x00000314L
  84. #define BA0_PCICFG18 0x00000318L
  85. #define BA0_PCICFG1C 0x0000031CL
  86. #define BA0_PCICFG20 0x00000320L
  87. #define BA0_PCICFG24 0x00000324L
  88. #define BA0_PCICFG28 0x00000328L
  89. #define BA0_PCICFG2C 0x0000032CL
  90. #define BA0_PCICFG30 0x00000330L
  91. #define BA0_PCICFG34 0x00000334L
  92. #define BA0_PCICFG38 0x00000338L
  93. #define BA0_PCICFG3C 0x0000033CL
  94. #define BA0_PCICFG40 0x00000340L
  95. #define BA0_PMCS 0x00000344L
  96. #define BA0_CWPR 0x000003E0L
  97. #define BA0_EPPMC 0x000003E4L
  98. #define BA0_GPIOR 0x000003E8L
  99. #define BA0_SPMC 0x000003ECL
  100. #define BA0_CFLR 0x000003F0L
  101. #define BA0_IISR 0x000003F4L
  102. #define BA0_TMS 0x000003F8L
  103. #define BA0_SSVID 0x000003FCL
  104. #define BA0_CLKCR1 0x00000400L
  105. #define BA0_FRR 0x00000410L
  106. #define BA0_SLT12O 0x0000041CL
  107. #define BA0_SERMC 0x00000420L
  108. #define BA0_SERC1 0x00000428L
  109. #define BA0_SERC2 0x0000042CL
  110. #define BA0_SLT12M 0x0000045CL
  111. #define BA0_ACCTL 0x00000460L
  112. #define BA0_ACSTS 0x00000464L
  113. #define BA0_ACOSV 0x00000468L
  114. #define BA0_ACCAD 0x0000046CL
  115. #define BA0_ACCDA 0x00000470L
  116. #define BA0_ACISV 0x00000474L
  117. #define BA0_ACSAD 0x00000478L
  118. #define BA0_ACSDA 0x0000047CL
  119. #define BA0_JSPT 0x00000480L
  120. #define BA0_JSCTL 0x00000484L
  121. #define BA0_MIDCR 0x00000490L
  122. #define BA0_MIDCMD 0x00000494L
  123. #define BA0_MIDSR 0x00000494L
  124. #define BA0_MIDWP 0x00000498L
  125. #define BA0_MIDRP 0x0000049CL
  126. #define BA0_AODSD1 0x000004A8L
  127. #define BA0_AODSD2 0x000004ACL
  128. #define BA0_CFGI 0x000004B0L
  129. #define BA0_SLT12M2 0x000004DCL
  130. #define BA0_ACSTS2 0x000004E4L
  131. #define BA0_ACISV2 0x000004F4L
  132. #define BA0_ACSAD2 0x000004F8L
  133. #define BA0_ACSDA2 0x000004FCL
  134. #define BA0_IOTGP 0x00000500L
  135. #define BA0_IOTSB 0x00000504L
  136. #define BA0_IOTFM 0x00000508L
  137. #define BA0_IOTDMA 0x0000050CL
  138. #define BA0_IOTAC0 0x00000500L
  139. #define BA0_IOTAC1 0x00000504L
  140. #define BA0_IOTAC2 0x00000508L
  141. #define BA0_IOTAC3 0x0000050CL
  142. #define BA0_IOTPCP 0x0000052CL
  143. #define BA0_IOTCC 0x00000530L
  144. #define BA0_IOTCR 0x0000058CL
  145. #define BA0_PCPRR 0x00000600L
  146. #define BA0_PCPGR 0x00000604L
  147. #define BA0_PCPCR 0x00000608L
  148. #define BA0_PCPCIEN 0x00000608L
  149. #define BA0_SBMAR 0x00000700L
  150. #define BA0_SBMDR 0x00000704L
  151. #define BA0_SBRR 0x00000708L
  152. #define BA0_SBRDP 0x0000070CL
  153. #define BA0_SBWDP 0x00000710L
  154. #define BA0_SBWBS 0x00000710L
  155. #define BA0_SBRBS 0x00000714L
  156. #define BA0_FMSR 0x00000730L
  157. #define BA0_B0AP 0x00000730L
  158. #define BA0_FMDP 0x00000734L
  159. #define BA0_B1AP 0x00000738L
  160. #define BA0_B1DP 0x0000073CL
  161. #define BA0_SSPM 0x00000740L
  162. #define BA0_DACSR 0x00000744L
  163. #define BA0_ADCSR 0x00000748L
  164. #define BA0_SSCR 0x0000074CL
  165. #define BA0_FMLVC 0x00000754L
  166. #define BA0_FMRVC 0x00000758L
  167. #define BA0_SRCSA 0x0000075CL
  168. #define BA0_PPLVC 0x00000760L
  169. #define BA0_PPRVC 0x00000764L
  170. #define BA0_PASR 0x00000768L
  171. #define BA0_CASR 0x0000076CL
  172. //****************************************************************************
  173. //
  174. // The following define the offsets of the AC97 shadow registers, which appear
  175. // as a virtual extension to the base address register zero memory range.
  176. //
  177. //****************************************************************************
  178. #define AC97_REG_OFFSET_MASK 0x0000007EL
  179. #define AC97_CODEC_NUMBER_MASK 0x00003000L
  180. #define BA0_AC97_RESET 0x00001000L
  181. #define BA0_AC97_MASTER_VOLUME 0x00001002L
  182. #define BA0_AC97_HEADPHONE_VOLUME 0x00001004L
  183. #define BA0_AC97_MASTER_VOLUME_MONO 0x00001006L
  184. #define BA0_AC97_MASTER_TONE 0x00001008L
  185. #define BA0_AC97_PC_BEEP_VOLUME 0x0000100AL
  186. #define BA0_AC97_PHONE_VOLUME 0x0000100CL
  187. #define BA0_AC97_MIC_VOLUME 0x0000100EL
  188. #define BA0_AC97_LINE_IN_VOLUME 0x00001010L
  189. #define BA0_AC97_CD_VOLUME 0x00001012L
  190. #define BA0_AC97_VIDEO_VOLUME 0x00001014L
  191. #define BA0_AC97_AUX_VOLUME 0x00001016L
  192. #define BA0_AC97_PCM_OUT_VOLUME 0x00001018L
  193. #define BA0_AC97_RECORD_SELECT 0x0000101AL
  194. #define BA0_AC97_RECORD_GAIN 0x0000101CL
  195. #define BA0_AC97_RECORD_GAIN_MIC 0x0000101EL
  196. #define BA0_AC97_GENERAL_PURPOSE 0x00001020L
  197. #define BA0_AC97_3D_CONTROL 0x00001022L
  198. #define BA0_AC97_MODEM_RATE 0x00001024L
  199. #define BA0_AC97_POWERDOWN 0x00001026L
  200. #define BA0_AC97_EXT_AUDIO_ID 0x00001028L
  201. #define BA0_AC97_EXT_AUDIO_POWER 0x0000102AL
  202. #define BA0_AC97_PCM_FRONT_DAC_RATE 0x0000102CL
  203. #define BA0_AC97_PCM_SURR_DAC_RATE 0x0000102EL
  204. #define BA0_AC97_PCM_LFE_DAC_RATE 0x00001030L
  205. #define BA0_AC97_PCM_LR_ADC_RATE 0x00001032L
  206. #define BA0_AC97_MIC_ADC_RATE 0x00001034L
  207. #define BA0_AC97_6CH_VOL_C_LFE 0x00001036L
  208. #define BA0_AC97_6CH_VOL_SURROUND 0x00001038L
  209. #define BA0_AC97_RESERVED_3A 0x0000103AL
  210. #define BA0_AC97_EXT_MODEM_ID 0x0000103CL
  211. #define BA0_AC97_EXT_MODEM_POWER 0x0000103EL
  212. #define BA0_AC97_LINE1_CODEC_RATE 0x00001040L
  213. #define BA0_AC97_LINE2_CODEC_RATE 0x00001042L
  214. #define BA0_AC97_HANDSET_CODEC_RATE 0x00001044L
  215. #define BA0_AC97_LINE1_CODEC_LEVEL 0x00001046L
  216. #define BA0_AC97_LINE2_CODEC_LEVEL 0x00001048L
  217. #define BA0_AC97_HANDSET_CODEC_LEVEL 0x0000104AL
  218. #define BA0_AC97_GPIO_PIN_CONFIG 0x0000104CL
  219. #define BA0_AC97_GPIO_PIN_TYPE 0x0000104EL
  220. #define BA0_AC97_GPIO_PIN_STICKY 0x00001050L
  221. #define BA0_AC97_GPIO_PIN_WAKEUP 0x00001052L
  222. #define BA0_AC97_GPIO_PIN_STATUS 0x00001054L
  223. #define BA0_AC97_MISC_MODEM_AFE_STAT 0x00001056L
  224. #define BA0_AC97_RESERVED_58 0x00001058L
  225. #define BA0_AC97_CRYSTAL_REV_N_FAB_ID 0x0000105AL
  226. #define BA0_AC97_TEST_AND_MISC_CTRL 0x0000105CL
  227. #define BA0_AC97_AC_MODE 0x0000105EL
  228. #define BA0_AC97_MISC_CRYSTAL_CONTROL 0x00001060L
  229. #define BA0_AC97_LINE1_HYPRID_CTRL 0x00001062L
  230. #define BA0_AC97_VENDOR_RESERVED_64 0x00001064L
  231. #define BA0_AC97_VENDOR_RESERVED_66 0x00001066L
  232. #define BA0_AC97_SPDIF_CONTROL 0x00001068L
  233. #define BA0_AC97_VENDOR_RESERVED_6A 0x0000106AL
  234. #define BA0_AC97_VENDOR_RESERVED_6C 0x0000106CL
  235. #define BA0_AC97_VENDOR_RESERVED_6E 0x0000106EL
  236. #define BA0_AC97_VENDOR_RESERVED_70 0x00001070L
  237. #define BA0_AC97_VENDOR_RESERVED_72 0x00001072L
  238. #define BA0_AC97_VENDOR_RESERVED_74 0x00001074L
  239. #define BA0_AC97_CAL_ADDRESS 0x00001076L
  240. #define BA0_AC97_CAL_DATA 0x00001078L
  241. #define BA0_AC97_VENDOR_RESERVED_7A 0x0000107AL
  242. #define BA0_AC97_VENDOR_ID1 0x0000107CL
  243. #define BA0_AC97_VENDOR_ID2 0x0000107EL
  244. //****************************************************************************
  245. //
  246. // The following define the offsets of the registers and memories accessed via
  247. // base address register one on the CS4281 part.
  248. //
  249. //****************************************************************************
  250. //****************************************************************************
  251. //
  252. // The following defines are for the flags in the PCI device ID/vendor ID
  253. // register.
  254. //
  255. //****************************************************************************
  256. #define PDV_VENID_MASK 0x0000FFFFL
  257. #define PDV_DEVID_MASK 0xFFFF0000L
  258. #define PDV_VENID_SHIFT 0L
  259. #define PDV_DEVID_SHIFT 16L
  260. #define VENID_CIRRUS_LOGIC 0x1013L
  261. #define DEVID_CS4281 0x6005L
  262. //****************************************************************************
  263. //
  264. // The following defines are for the flags in the PCI status and command
  265. // register.
  266. //
  267. //****************************************************************************
  268. #define PSC_IO_SPACE_ENABLE 0x00000001L
  269. #define PSC_MEMORY_SPACE_ENABLE 0x00000002L
  270. #define PSC_BUS_MASTER_ENABLE 0x00000004L
  271. #define PSC_SPECIAL_CYCLES 0x00000008L
  272. #define PSC_MWI_ENABLE 0x00000010L
  273. #define PSC_VGA_PALETTE_SNOOP 0x00000020L
  274. #define PSC_PARITY_RESPONSE 0x00000040L
  275. #define PSC_WAIT_CONTROL 0x00000080L
  276. #define PSC_SERR_ENABLE 0x00000100L
  277. #define PSC_FAST_B2B_ENABLE 0x00000200L
  278. #define PSC_UDF_MASK 0x007F0000L
  279. #define PSC_FAST_B2B_CAPABLE 0x00800000L
  280. #define PSC_PARITY_ERROR_DETECTED 0x01000000L
  281. #define PSC_DEVSEL_TIMING_MASK 0x06000000L
  282. #define PSC_TARGET_ABORT_SIGNALLED 0x08000000L
  283. #define PSC_RECEIVED_TARGET_ABORT 0x10000000L
  284. #define PSC_RECEIVED_MASTER_ABORT 0x20000000L
  285. #define PSC_SIGNALLED_SERR 0x40000000L
  286. #define PSC_DETECTED_PARITY_ERROR 0x80000000L
  287. #define PSC_UDF_SHIFT 16L
  288. #define PSC_DEVSEL_TIMING_SHIFT 25L
  289. //****************************************************************************
  290. //
  291. // The following defines are for the flags in the PCI class/revision ID
  292. // register.
  293. //
  294. //****************************************************************************
  295. #define PCR_REVID_MASK 0x000000FFL
  296. #define PCR_INTERFACE_MASK 0x0000FF00L
  297. #define PCR_SUBCLASS_MASK 0x00FF0000L
  298. #define PCR_CLASS_MASK 0xFF000000L
  299. #define PCR_REVID_SHIFT 0L
  300. #define PCR_INTERFACE_SHIFT 8L
  301. #define PCR_SUBCLASS_SHIFT 16L
  302. #define PCR_CLASS_SHIFT 24L
  303. //****************************************************************************
  304. //
  305. // The following defines are for the flags in the PCI latency timer register.
  306. //
  307. //****************************************************************************
  308. #define PLT_CACHE_LINE_SIZE_MASK 0x000000FFL
  309. #define PLT_LATENCY_TIMER_MASK 0x0000FF00L
  310. #define PLT_HEADER_TYPE_MASK 0x00FF0000L
  311. #define PLT_BIST_MASK 0xFF000000L
  312. #define PLT_CACHE_LINE_SIZE_SHIFT 0L
  313. #define PLT_LATENCY_TIMER_SHIFT 8L
  314. #define PLT_HEADER_TYPE_SHIFT 16L
  315. #define PLT_BIST_SHIFT 24L
  316. //****************************************************************************
  317. //
  318. // The following defines are for the flags in the PCI base address registers.
  319. //
  320. //****************************************************************************
  321. #define PBAR_MEMORY_SPACE_INDICATOR 0x00000001L
  322. #define PBAR_LOCATION_TYPE_MASK 0x00000006L
  323. #define PBAR_NOT_PREFETCHABLE 0x00000008L
  324. #define PBAR_ADDRESS_MASK 0xFFFFFFF0L
  325. #define PBAR_LOCATION_TYPE_SHIFT 1L
  326. //****************************************************************************
  327. //
  328. // The following defines are for the flags in the PCI subsystem ID/subsystem
  329. // vendor ID register.
  330. //
  331. //****************************************************************************
  332. #define PSS_SUBSYSTEM_VENDOR_ID_MASK 0x0000FFFFL
  333. #define PSS_SUBSYSTEM_ID_MASK 0xFFFF0000L
  334. #define PSS_SUBSYSTEM_VENDOR_ID_SHIFT 0L
  335. #define PSS_SUBSYSTEM_ID_SHIFT 16L
  336. //****************************************************************************
  337. //
  338. // The following defines are for the flags in the PCI interrupt register.
  339. //
  340. //****************************************************************************
  341. #define PI_LINE_MASK 0x000000FFL
  342. #define PI_PIN_MASK 0x0000FF00L
  343. #define PI_MIN_GRANT_MASK 0x00FF0000L
  344. #define PI_MAX_LATENCY_MASK 0xFF000000L
  345. #define PI_LINE_SHIFT 0L
  346. #define PI_PIN_SHIFT 8L
  347. #define PI_MIN_GRANT_SHIFT 16L
  348. #define PI_MAX_LATENCY_SHIFT 24L
  349. //****************************************************************************
  350. //
  351. // The following defines are for the flags in the host interrupt status
  352. // register.
  353. //
  354. //****************************************************************************
  355. #define HISR_HVOLMASK 0x00000003L
  356. #define HISR_VDNI 0x00000001L
  357. #define HISR_VUPI 0x00000002L
  358. #define HISR_GP1I 0x00000004L
  359. #define HISR_GP3I 0x00000008L
  360. #define HISR_GPSI 0x00000010L
  361. #define HISR_GPPI 0x00000020L
  362. #define HISR_DMAI 0x00040000L
  363. #define HISR_FIFOI 0x00100000L
  364. #define HISR_HVOL 0x00200000L
  365. #define HISR_MIDI 0x00400000L
  366. #define HISR_SBINT 0x00800000L
  367. #define HISR_INTENA 0x80000000L
  368. #define HISR_DMA_MASK 0x00000F00L
  369. #define HISR_FIFO_MASK 0x0000F000L
  370. #define HISR_DMA_SHIFT 8L
  371. #define HISR_FIFO_SHIFT 12L
  372. #define HISR_FIFO0 0x00001000L
  373. #define HISR_FIFO1 0x00002000L
  374. #define HISR_FIFO2 0x00004000L
  375. #define HISR_FIFO3 0x00008000L
  376. #define HISR_DMA0 0x00000100L
  377. #define HISR_DMA1 0x00000200L
  378. #define HISR_DMA2 0x00000400L
  379. #define HISR_DMA3 0x00000800L
  380. #define HISR_RESERVED 0x40000000L
  381. //****************************************************************************
  382. //
  383. // The following defines are for the flags in the host interrupt control
  384. // register.
  385. //
  386. //****************************************************************************
  387. #define HICR_IEV 0x00000001L
  388. #define HICR_CHGM 0x00000002L
  389. //****************************************************************************
  390. //
  391. // The following defines are for the flags in the DMA Mode Register n
  392. // (DMRn)
  393. //
  394. //****************************************************************************
  395. #define DMRn_TR_MASK 0x0000000CL
  396. #define DMRn_TR_SHIFT 2L
  397. #define DMRn_AUTO 0x00000010L
  398. #define DMRn_TR_READ 0x00000008L
  399. #define DMRn_TR_WRITE 0x00000004L
  400. #define DMRn_TYPE_MASK 0x000000C0L
  401. #define DMRn_TYPE_SHIFT 6L
  402. #define DMRn_SIZE8 0x00010000L
  403. #define DMRn_MONO 0x00020000L
  404. #define DMRn_BEND 0x00040000L
  405. #define DMRn_USIGN 0x00080000L
  406. #define DMRn_SIZE20 0x00100000L
  407. #define DMRn_SWAPC 0x00400000L
  408. #define DMRn_CBC 0x01000000L
  409. #define DMRn_TBC 0x02000000L
  410. #define DMRn_POLL 0x10000000L
  411. #define DMRn_DMA 0x20000000L
  412. #define DMRn_FSEL_MASK 0xC0000000L
  413. #define DMRn_FSEL_SHIFT 30L
  414. #define DMRn_FSEL0 0x00000000L
  415. #define DMRn_FSEL1 0x40000000L
  416. #define DMRn_FSEL2 0x80000000L
  417. #define DMRn_FSEL3 0xC0000000L
  418. //****************************************************************************
  419. //
  420. // The following defines are for the flags in the DMA Command Register n
  421. // (DCRn)
  422. //
  423. //****************************************************************************
  424. #define DCRn_HTCIE 0x00020000L
  425. #define DCRn_TCIE 0x00010000L
  426. #define DCRn_MSK 0x00000001L
  427. //****************************************************************************
  428. //
  429. // The following defines are for the flags in the FIFO Control
  430. // register n.(FCRn)
  431. //
  432. //****************************************************************************
  433. #define FCRn_OF_MASK 0x0000007FL
  434. #define FCRn_OF_SHIFT 0L
  435. #define FCRn_SZ_MASK 0x00007F00L
  436. #define FCRn_SZ_SHIFT 8L
  437. #define FCRn_LS_MASK 0x001F0000L
  438. #define FCRn_LS_SHIFT 16L
  439. #define FCRn_RS_MASK 0x1F000000L
  440. #define FCRn_RS_SHIFT 24L
  441. #define FCRn_FEN 0x80000000L
  442. #define FCRn_PSH 0x20000000L
  443. #define FCRn_DACZ 0x40000000L
  444. //****************************************************************************
  445. //
  446. // The following defines are for the flags in the serial port Power Management
  447. // control register.(SPMC)
  448. //
  449. //****************************************************************************
  450. #define SPMC_RSTN 0x00000001L
  451. #define SPMC_ASYN 0x00000002L
  452. #define SPMC_WUP1 0x00000004L
  453. #define SPMC_WUP2 0x00000008L
  454. #define SPMC_ASDI2E 0x00000100L
  455. #define SPMC_ESSPD 0x00000200L
  456. #define SPMC_GISPEN 0x00004000L
  457. #define SPMC_GIPPEN 0x00008000L
  458. //****************************************************************************
  459. //
  460. // The following defines are for the flags in the Configuration Load register.
  461. // (CFLR)
  462. //
  463. //****************************************************************************
  464. #define CFLR_CLOCK_SOURCE_MASK 0x00000003L
  465. #define CFLR_CLOCK_SOURCE_AC97 0x00000001L
  466. #define CFLR_CB0_MASK 0x000000FFL
  467. #define CFLR_CB1_MASK 0x0000FF00L
  468. #define CFLR_CB2_MASK 0x00FF0000L
  469. #define CFLR_CB3_MASK 0xFF000000L
  470. #define CFLR_CB0_SHIFT 0L
  471. #define CFLR_CB1_SHIFT 8L
  472. #define CFLR_CB2_SHIFT 16L
  473. #define CFLR_CB3_SHIFT 24L
  474. #define IOTCR_DMA0 0x00000000L
  475. #define IOTCR_DMA1 0x00000400L
  476. #define IOTCR_DMA2 0x00000800L
  477. #define IOTCR_DMA3 0x00000C00L
  478. #define IOTCR_CCLS 0x00000100L
  479. #define IOTCR_PCPCI 0x00000200L
  480. #define IOTCR_DDMA 0x00000300L
  481. #define SBWBS_WBB 0x00000080L
  482. //****************************************************************************
  483. //
  484. // The following defines are for the flags in the SRC Slot Assignment Register
  485. // (SRCSA)
  486. //
  487. //****************************************************************************
  488. #define SRCSA_PLSS_MASK 0x0000001FL
  489. #define SRCSA_PLSS_SHIFT 0L
  490. #define SRCSA_PRSS_MASK 0x00001F00L
  491. #define SRCSA_PRSS_SHIFT 8L
  492. #define SRCSA_CLSS_MASK 0x001F0000L
  493. #define SRCSA_CLSS_SHIFT 16L
  494. #define SRCSA_CRSS_MASK 0x1F000000L
  495. #define SRCSA_CRSS_SHIFT 24L
  496. //****************************************************************************
  497. //
  498. // The following defines are for the flags in the Sound System Power Management
  499. // register.(SSPM)
  500. //
  501. //****************************************************************************
  502. #define SSPM_FPDN 0x00000080L
  503. #define SSPM_MIXEN 0x00000040L
  504. #define SSPM_CSRCEN 0x00000020L
  505. #define SSPM_PSRCEN 0x00000010L
  506. #define SSPM_JSEN 0x00000008L
  507. #define SSPM_ACLEN 0x00000004L
  508. #define SSPM_FMEN 0x00000002L
  509. //****************************************************************************
  510. //
  511. // The following defines are for the flags in the Sound System Control
  512. // Register. (SSCR)
  513. //
  514. //****************************************************************************
  515. #define SSCR_SB 0x00000004L
  516. #define SSCR_HVC 0x00000008L
  517. #define SSCR_LPFIFO 0x00000040L
  518. #define SSCR_LPSRC 0x00000080L
  519. #define SSCR_XLPSRC 0x00000100L
  520. #define SSCR_MVMD 0x00010000L
  521. #define SSCR_MVAD 0x00020000L
  522. #define SSCR_MVLD 0x00040000L
  523. #define SSCR_MVCS 0x00080000L
  524. //****************************************************************************
  525. //
  526. // The following defines are for the flags in the Clock Control Register 1.
  527. // (CLKCR1)
  528. //
  529. //****************************************************************************
  530. #define CLKCR1_DLLSS_MASK 0x0000000CL
  531. #define CLKCR1_DLLSS_SHIFT 2L
  532. #define CLKCR1_DLLP 0x00000010L
  533. #define CLKCR1_SWCE 0x00000020L
  534. #define CLKCR1_DLLOS 0x00000040L
  535. #define CLKCR1_CKRA 0x00010000L
  536. #define CLKCR1_CKRN 0x00020000L
  537. #define CLKCR1_DLLRDY 0x01000000L
  538. #define CLKCR1_CLKON 0x02000000L
  539. //****************************************************************************
  540. //
  541. // The following defines are for the flags in the Sound Blaster Read Buffer
  542. // Status.(SBRBS)
  543. //
  544. //****************************************************************************
  545. #define SBRBS_RD_MASK 0x0000007FL
  546. #define SBRBS_RD_SHIFT 0L
  547. #define SBRBS_RBF 0x00000080L
  548. //****************************************************************************
  549. //
  550. // The following defines are for the flags in the serial port master control
  551. // register.(SERMC)
  552. //
  553. //****************************************************************************
  554. #define SERMC_MSPE 0x00000001L
  555. #define SERMC_PTC_MASK 0x0000000EL
  556. #define SERMC_PTC_SHIFT 1L
  557. #define SERMC_PTC_AC97 0x00000002L
  558. #define SERMC_PLB 0x00000010L
  559. #define SERMC_PXLB 0x00000020L
  560. #define SERMC_LOFV 0x00080000L
  561. #define SERMC_SLB 0x00100000L
  562. #define SERMC_SXLB 0x00200000L
  563. #define SERMC_ODSEN1 0x01000000L
  564. #define SERMC_ODSEN2 0x02000000L
  565. //****************************************************************************
  566. //
  567. // The following defines are for the flags in the General Purpose I/O Register.
  568. // (GPIOR)
  569. //
  570. //****************************************************************************
  571. #define GPIOR_VDNS 0x00000001L
  572. #define GPIOR_VUPS 0x00000002L
  573. #define GPIOR_GP1S 0x00000004L
  574. #define GPIOR_GP3S 0x00000008L
  575. #define GPIOR_GPSS 0x00000010L
  576. #define GPIOR_GPPS 0x00000020L
  577. #define GPIOR_GP1D 0x00000400L
  578. #define GPIOR_GP3D 0x00000800L
  579. #define GPIOR_VDNLT 0x00010000L
  580. #define GPIOR_VDNPO 0x00020000L
  581. #define GPIOR_VDNST 0x00040000L
  582. #define GPIOR_VDNW 0x00080000L
  583. #define GPIOR_VUPLT 0x00100000L
  584. #define GPIOR_VUPPO 0x00200000L
  585. #define GPIOR_VUPST 0x00400000L
  586. #define GPIOR_VUPW 0x00800000L
  587. #define GPIOR_GP1OE 0x01000000L
  588. #define GPIOR_GP1PT 0x02000000L
  589. #define GPIOR_GP1ST 0x04000000L
  590. #define GPIOR_GP1W 0x08000000L
  591. #define GPIOR_GP3OE 0x10000000L
  592. #define GPIOR_GP3PT 0x20000000L
  593. #define GPIOR_GP3ST 0x40000000L
  594. #define GPIOR_GP3W 0x80000000L
  595. //****************************************************************************
  596. //
  597. // The following defines are for the flags in the clock control register 1.
  598. //
  599. //****************************************************************************
  600. #define CLKCR1_PLLSS_MASK 0x0000000CL
  601. #define CLKCR1_PLLSS_SERIAL 0x00000000L
  602. #define CLKCR1_PLLSS_CRYSTAL 0x00000004L
  603. #define CLKCR1_PLLSS_PCI 0x00000008L
  604. #define CLKCR1_PLLSS_RESERVED 0x0000000CL
  605. #define CLKCR1_PLLP 0x00000010L
  606. #define CLKCR1_SWCE 0x00000020L
  607. #define CLKCR1_PLLOS 0x00000040L
  608. //****************************************************************************
  609. //
  610. // The following defines are for the flags in the feature reporting register.
  611. //
  612. //****************************************************************************
  613. #define FRR_FAB_MASK 0x00000003L
  614. #define FRR_MASK_MASK 0x0000001CL
  615. #define FRR_ID_MASK 0x00003000L
  616. #define FRR_FAB_SHIFT 0L
  617. #define FRR_MASK_SHIFT 2L
  618. #define FRR_ID_SHIFT 12L
  619. //****************************************************************************
  620. //
  621. // The following defines are for the flags in the serial port 1 configuration
  622. // register.
  623. //
  624. //****************************************************************************
  625. #define SERC1_VALUE 0x00000003L
  626. #define SERC1_SO1EN 0x00000001L
  627. #define SERC1_SO1F_MASK 0x0000000EL
  628. #define SERC1_SO1F_CS423X 0x00000000L
  629. #define SERC1_SO1F_AC97 0x00000002L
  630. #define SERC1_SO1F_DAC 0x00000004L
  631. #define SERC1_SO1F_SPDIF 0x00000006L
  632. //****************************************************************************
  633. //
  634. // The following defines are for the flags in the serial port 2 configuration
  635. // register.
  636. //
  637. //****************************************************************************
  638. #define SERC2_VALUE 0x00000003L
  639. #define SERC2_SI1EN 0x00000001L
  640. #define SERC2_SI1F_MASK 0x0000000EL
  641. #define SERC2_SI1F_CS423X 0x00000000L
  642. #define SERC2_SI1F_AC97 0x00000002L
  643. #define SERC2_SI1F_ADC 0x00000004L
  644. #define SERC2_SI1F_SPDIF 0x00000006L
  645. //****************************************************************************
  646. //
  647. // The following defines are for the flags in the AC97 control register.
  648. //
  649. //****************************************************************************
  650. #define ACCTL_ESYN 0x00000002L
  651. #define ACCTL_VFRM 0x00000004L
  652. #define ACCTL_DCV 0x00000008L
  653. #define ACCTL_CRW 0x00000010L
  654. #define ACCTL_TC 0x00000040L
  655. //****************************************************************************
  656. //
  657. // The following defines are for the flags in the AC97 status register.
  658. //
  659. //****************************************************************************
  660. #define ACSTS_CRDY 0x00000001L
  661. #define ACSTS_VSTS 0x00000002L
  662. //****************************************************************************
  663. //
  664. // The following defines are for the flags in the AC97 output slot valid
  665. // register.
  666. //
  667. //****************************************************************************
  668. #define ACOSV_SLV3 0x00000001L
  669. #define ACOSV_SLV4 0x00000002L
  670. #define ACOSV_SLV5 0x00000004L
  671. #define ACOSV_SLV6 0x00000008L
  672. #define ACOSV_SLV7 0x00000010L
  673. #define ACOSV_SLV8 0x00000020L
  674. #define ACOSV_SLV9 0x00000040L
  675. #define ACOSV_SLV10 0x00000080L
  676. #define ACOSV_SLV11 0x00000100L
  677. #define ACOSV_SLV12 0x00000200L
  678. //****************************************************************************
  679. //
  680. // The following defines are for the flags in the AC97 command address
  681. // register.
  682. //
  683. //****************************************************************************
  684. #define ACCAD_CI_MASK 0x0000007FL
  685. #define ACCAD_CI_SHIFT 0L
  686. //****************************************************************************
  687. //
  688. // The following defines are for the flags in the AC97 command data register.
  689. //
  690. //****************************************************************************
  691. #define ACCDA_CD_MASK 0x0000FFFFL
  692. #define ACCDA_CD_SHIFT 0L
  693. //****************************************************************************
  694. //
  695. // The following defines are for the flags in the AC97 input slot valid
  696. // register.
  697. //
  698. //****************************************************************************
  699. #define ACISV_ISV3 0x00000001L
  700. #define ACISV_ISV4 0x00000002L
  701. #define ACISV_ISV5 0x00000004L
  702. #define ACISV_ISV6 0x00000008L
  703. #define ACISV_ISV7 0x00000010L
  704. #define ACISV_ISV8 0x00000020L
  705. #define ACISV_ISV9 0x00000040L
  706. #define ACISV_ISV10 0x00000080L
  707. #define ACISV_ISV11 0x00000100L
  708. #define ACISV_ISV12 0x00000200L
  709. //****************************************************************************
  710. //
  711. // The following defines are for the flags in the AC97 status address
  712. // register.
  713. //
  714. //****************************************************************************
  715. #define ACSAD_SI_MASK 0x0000007FL
  716. #define ACSAD_SI_SHIFT 0L
  717. //****************************************************************************
  718. //
  719. // The following defines are for the flags in the AC97 status data register.
  720. //
  721. //****************************************************************************
  722. #define ACSDA_SD_MASK 0x0000FFFFL
  723. #define ACSDA_SD_SHIFT 0L
  724. //****************************************************************************
  725. //
  726. // The following defines are for the flags in the I/O trap address and control
  727. // registers (all 12).
  728. //
  729. //****************************************************************************
  730. #define IOTAC_SA_MASK 0x0000FFFFL
  731. #define IOTAC_MSK_MASK 0x000F0000L
  732. #define IOTAC_IODC_MASK 0x06000000L
  733. #define IOTAC_IODC_16_BIT 0x00000000L
  734. #define IOTAC_IODC_10_BIT 0x02000000L
  735. #define IOTAC_IODC_12_BIT 0x04000000L
  736. #define IOTAC_WSPI 0x08000000L
  737. #define IOTAC_RSPI 0x10000000L
  738. #define IOTAC_WSE 0x20000000L
  739. #define IOTAC_WE 0x40000000L
  740. #define IOTAC_RE 0x80000000L
  741. #define IOTAC_SA_SHIFT 0L
  742. #define IOTAC_MSK_SHIFT 16L
  743. //****************************************************************************
  744. //
  745. // The following defines are for the flags in the PC/PCI master enable
  746. // register.
  747. //
  748. //****************************************************************************
  749. #define PCPCIEN_EN 0x00000001L
  750. //****************************************************************************
  751. //
  752. // The following defines are for the flags in the joystick poll/trigger
  753. // register.
  754. //
  755. //****************************************************************************
  756. #define JSPT_CAX 0x00000001L
  757. #define JSPT_CAY 0x00000002L
  758. #define JSPT_CBX 0x00000004L
  759. #define JSPT_CBY 0x00000008L
  760. #define JSPT_BA1 0x00000010L
  761. #define JSPT_BA2 0x00000020L
  762. #define JSPT_BB1 0x00000040L
  763. #define JSPT_BB2 0x00000080L
  764. //****************************************************************************
  765. //
  766. // The following defines are for the flags in the joystick control register.
  767. // The TBF bit has been moved from MIDSR register to JSCTL register bit 8.
  768. //
  769. //****************************************************************************
  770. #define JSCTL_SP_MASK 0x00000003L
  771. #define JSCTL_SP_SLOW 0x00000000L
  772. #define JSCTL_SP_MEDIUM_SLOW 0x00000001L
  773. #define JSCTL_SP_MEDIUM_FAST 0x00000002L
  774. #define JSCTL_SP_FAST 0x00000003L
  775. #define JSCTL_ARE 0x00000004L
  776. #define JSCTL_TBF 0x00000100L
  777. //****************************************************************************
  778. //
  779. // The following defines are for the flags in the MIDI control register.
  780. //
  781. //****************************************************************************
  782. #define MIDCR_TXE 0x00000001L
  783. #define MIDCR_RXE 0x00000002L
  784. #define MIDCR_RIE 0x00000004L
  785. #define MIDCR_TIE 0x00000008L
  786. #define MIDCR_MLB 0x00000010L
  787. #define MIDCR_MRST 0x00000020L
  788. //****************************************************************************
  789. //
  790. // The following defines are for the flags in the MIDI status register.
  791. //
  792. //****************************************************************************
  793. #define MIDSR_RBE 0x00000080L
  794. #define MIDSR_RDA 0x00008000L
  795. //****************************************************************************
  796. //
  797. // The following defines are for the flags in the MIDI write port register.
  798. //
  799. //****************************************************************************
  800. #define MIDWP_MWD_MASK 0x000000FFL
  801. #define MIDWP_MWD_SHIFT 0L
  802. //****************************************************************************
  803. //
  804. // The following defines are for the flags in the MIDI read port register.
  805. //
  806. //****************************************************************************
  807. #define MIDRP_MRD_MASK 0x000000FFL
  808. #define MIDRP_MRD_SHIFT 0L
  809. //****************************************************************************
  810. //
  811. // The following defines are for the flags in the configuration interface
  812. // register.
  813. //
  814. //****************************************************************************
  815. #define CFGI_CLK 0x00000001L
  816. #define CFGI_DOUT 0x00000002L
  817. #define CFGI_DIN_EEN 0x00000004L
  818. #define CFGI_EELD 0x00000008L
  819. //****************************************************************************
  820. //
  821. // The following defines are for the flags in the subsystem ID and vendor ID
  822. // register.
  823. //
  824. //****************************************************************************
  825. #define SSVID_VID_MASK 0x0000FFFFL
  826. #define SSVID_SID_MASK 0xFFFF0000L
  827. #define SSVID_VID_SHIFT 0L
  828. #define SSVID_SID_SHIFT 16L
  829. //****************************************************************************
  830. //
  831. // The following defines are for the flags in the GPIO pin interface register.
  832. //
  833. //****************************************************************************
  834. #define GPIOR_VOLDN 0x00000001L
  835. #define GPIOR_VOLUP 0x00000002L
  836. #define GPIOR_SI2D 0x00000004L
  837. #define GPIOR_SI2OE 0x00000008L
  838. //****************************************************************************
  839. //
  840. // The following defines are for the flags in the AC97 status register 2.
  841. //
  842. //****************************************************************************
  843. #define ACSTS2_CRDY 0x00000001L
  844. #define ACSTS2_VSTS 0x00000002L
  845. //****************************************************************************
  846. //
  847. // The following defines are for the flags in the AC97 input slot valid
  848. // register 2.
  849. //
  850. //****************************************************************************
  851. #define ACISV2_ISV3 0x00000001L
  852. #define ACISV2_ISV4 0x00000002L
  853. #define ACISV2_ISV5 0x00000004L
  854. #define ACISV2_ISV6 0x00000008L
  855. #define ACISV2_ISV7 0x00000010L
  856. #define ACISV2_ISV8 0x00000020L
  857. #define ACISV2_ISV9 0x00000040L
  858. #define ACISV2_ISV10 0x00000080L
  859. #define ACISV2_ISV11 0x00000100L
  860. #define ACISV2_ISV12 0x00000200L
  861. //****************************************************************************
  862. //
  863. // The following defines are for the flags in the AC97 status address
  864. // register 2.
  865. //
  866. //****************************************************************************
  867. #define ACSAD2_SI_MASK 0x0000007FL
  868. #define ACSAD2_SI_SHIFT 0L
  869. //****************************************************************************
  870. //
  871. // The following defines are for the flags in the AC97 status data register 2.
  872. //
  873. //****************************************************************************
  874. #define ACSDA2_SD_MASK 0x0000FFFFL
  875. #define ACSDA2_SD_SHIFT 0L
  876. //****************************************************************************
  877. //
  878. // The following defines are for the flags in the I/O trap control register.
  879. //
  880. //****************************************************************************
  881. #define IOTCR_ITD 0x00000001L
  882. #define IOTCR_HRV 0x00000002L
  883. #define IOTCR_SRV 0x00000004L
  884. #define IOTCR_DTI 0x00000008L
  885. #define IOTCR_DFI 0x00000010L
  886. #define IOTCR_DDP 0x00000020L
  887. #define IOTCR_JTE 0x00000040L
  888. #define IOTCR_PPE 0x00000080L
  889. //****************************************************************************
  890. //
  891. // The following defines are for the flags in the I/O trap address and control
  892. // registers for Hardware Master Volume.
  893. //
  894. //****************************************************************************
  895. #define IOTGP_SA_MASK 0x0000FFFFL
  896. #define IOTGP_MSK_MASK 0x000F0000L
  897. #define IOTGP_IODC_MASK 0x06000000L
  898. #define IOTGP_IODC_16_BIT 0x00000000L
  899. #define IOTGP_IODC_10_BIT 0x02000000L
  900. #define IOTGP_IODC_12_BIT 0x04000000L
  901. #define IOTGP_WSPI 0x08000000L
  902. #define IOTGP_RSPI 0x10000000L
  903. #define IOTGP_WSE 0x20000000L
  904. #define IOTGP_WE 0x40000000L
  905. #define IOTGP_RE 0x80000000L
  906. #define IOTGP_SA_SHIFT 0L
  907. #define IOTGP_MSK_SHIFT 16L
  908. //****************************************************************************
  909. //
  910. // The following defines are for the flags in the I/O trap address and control
  911. // registers for Sound Blaster
  912. //
  913. //****************************************************************************
  914. #define IOTSB_SA_MASK 0x0000FFFFL
  915. #define IOTSB_MSK_MASK 0x000F0000L
  916. #define IOTSB_IODC_MASK 0x06000000L
  917. #define IOTSB_IODC_16_BIT 0x00000000L
  918. #define IOTSB_IODC_10_BIT 0x02000000L
  919. #define IOTSB_IODC_12_BIT 0x04000000L
  920. #define IOTSB_WSPI 0x08000000L
  921. #define IOTSB_RSPI 0x10000000L
  922. #define IOTSB_WSE 0x20000000L
  923. #define IOTSB_WE 0x40000000L
  924. #define IOTSB_RE 0x80000000L
  925. #define IOTSB_SA_SHIFT 0L
  926. #define IOTSB_MSK_SHIFT 16L
  927. //****************************************************************************
  928. //
  929. // The following defines are for the flags in the I/O trap address and control
  930. // registers for FM.
  931. //
  932. //****************************************************************************
  933. #define IOTFM_SA_MASK 0x0000FFFFL
  934. #define IOTFM_MSK_MASK 0x000F0000L
  935. #define IOTFM_IODC_MASK 0x06000000L
  936. #define IOTFM_IODC_16_BIT 0x00000000L
  937. #define IOTFM_IODC_10_BIT 0x02000000L
  938. #define IOTFM_IODC_12_BIT 0x04000000L
  939. #define IOTFM_WSPI 0x08000000L
  940. #define IOTFM_RSPI 0x10000000L
  941. #define IOTFM_WSE 0x20000000L
  942. #define IOTFM_WE 0x40000000L
  943. #define IOTFM_RE 0x80000000L
  944. #define IOTFM_SA_SHIFT 0L
  945. #define IOTFM_MSK_SHIFT 16L
  946. //****************************************************************************
  947. //
  948. // The following defines are for the flags in the PC/PCI request register.
  949. //
  950. //****************************************************************************
  951. #define PCPRR_RDC_MASK 0x00000007L
  952. #define PCPRR_REQ 0x00008000L
  953. #define PCPRR_RDC_SHIFT 0L
  954. //****************************************************************************
  955. //
  956. // The following defines are for the flags in the PC/PCI grant register.
  957. //
  958. //****************************************************************************
  959. #define PCPGR_GDC_MASK 0x00000007L
  960. #define PCPGR_VL 0x00008000L
  961. #define PCPGR_GDC_SHIFT 0L
  962. //****************************************************************************
  963. //
  964. // The following defines are for the flags in the PC/PCI Control Register.
  965. //
  966. //****************************************************************************
  967. #define PCPCR_EN 0x00000001L
  968. //****************************************************************************
  969. //
  970. // The following defines are for the flags in the debug index register.
  971. //
  972. //****************************************************************************
  973. #define DREG_REGID_MASK 0x0000007FL
  974. #define DREG_DEBUG 0x00000080L
  975. #define DREG_RGBK_MASK 0x00000700L
  976. #define DREG_TRAP 0x00000800L
  977. #if !defined(NO_CS4612)
  978. #if !defined(NO_CS4615)
  979. #define DREG_TRAPX 0x00001000L
  980. #endif
  981. #endif
  982. #define DREG_REGID_SHIFT 0L
  983. #define DREG_RGBK_SHIFT 8L
  984. #define DREG_RGBK_REGID_MASK 0x0000077FL
  985. #define DREG_REGID_R0 0x00000010L
  986. #define DREG_REGID_R1 0x00000011L
  987. #define DREG_REGID_R2 0x00000012L
  988. #define DREG_REGID_R3 0x00000013L
  989. #define DREG_REGID_R4 0x00000014L
  990. #define DREG_REGID_R5 0x00000015L
  991. #define DREG_REGID_R6 0x00000016L
  992. #define DREG_REGID_R7 0x00000017L
  993. #define DREG_REGID_R8 0x00000018L
  994. #define DREG_REGID_R9 0x00000019L
  995. #define DREG_REGID_RA 0x0000001AL
  996. #define DREG_REGID_RB 0x0000001BL
  997. #define DREG_REGID_RC 0x0000001CL
  998. #define DREG_REGID_RD 0x0000001DL
  999. #define DREG_REGID_RE 0x0000001EL
  1000. #define DREG_REGID_RF 0x0000001FL
  1001. #define DREG_REGID_RA_BUS_LOW 0x00000020L
  1002. #define DREG_REGID_RA_BUS_HIGH 0x00000038L
  1003. #define DREG_REGID_YBUS_LOW 0x00000050L
  1004. #define DREG_REGID_YBUS_HIGH 0x00000058L
  1005. #define DREG_REGID_TRAP_0 0x00000100L
  1006. #define DREG_REGID_TRAP_1 0x00000101L
  1007. #define DREG_REGID_TRAP_2 0x00000102L
  1008. #define DREG_REGID_TRAP_3 0x00000103L
  1009. #define DREG_REGID_TRAP_4 0x00000104L
  1010. #define DREG_REGID_TRAP_5 0x00000105L
  1011. #define DREG_REGID_TRAP_6 0x00000106L
  1012. #define DREG_REGID_TRAP_7 0x00000107L
  1013. #define DREG_REGID_INDIRECT_ADDRESS 0x0000010EL
  1014. #define DREG_REGID_TOP_OF_STACK 0x0000010FL
  1015. #if !defined(NO_CS4612)
  1016. #if !defined(NO_CS4615)
  1017. #define DREG_REGID_TRAP_8 0x00000110L
  1018. #define DREG_REGID_TRAP_9 0x00000111L
  1019. #define DREG_REGID_TRAP_10 0x00000112L
  1020. #define DREG_REGID_TRAP_11 0x00000113L
  1021. #define DREG_REGID_TRAP_12 0x00000114L
  1022. #define DREG_REGID_TRAP_13 0x00000115L
  1023. #define DREG_REGID_TRAP_14 0x00000116L
  1024. #define DREG_REGID_TRAP_15 0x00000117L
  1025. #define DREG_REGID_TRAP_16 0x00000118L
  1026. #define DREG_REGID_TRAP_17 0x00000119L
  1027. #define DREG_REGID_TRAP_18 0x0000011AL
  1028. #define DREG_REGID_TRAP_19 0x0000011BL
  1029. #define DREG_REGID_TRAP_20 0x0000011CL
  1030. #define DREG_REGID_TRAP_21 0x0000011DL
  1031. #define DREG_REGID_TRAP_22 0x0000011EL
  1032. #define DREG_REGID_TRAP_23 0x0000011FL
  1033. #endif
  1034. #endif
  1035. #define DREG_REGID_RSA0_LOW 0x00000200L
  1036. #define DREG_REGID_RSA0_HIGH 0x00000201L
  1037. #define DREG_REGID_RSA1_LOW 0x00000202L
  1038. #define DREG_REGID_RSA1_HIGH 0x00000203L
  1039. #define DREG_REGID_RSA2 0x00000204L
  1040. #define DREG_REGID_RSA3 0x00000205L
  1041. #define DREG_REGID_RSI0_LOW 0x00000206L
  1042. #define DREG_REGID_RSI0_HIGH 0x00000207L
  1043. #define DREG_REGID_RSI1 0x00000208L
  1044. #define DREG_REGID_RSI2 0x00000209L
  1045. #define DREG_REGID_SAGUSTATUS 0x0000020AL
  1046. #define DREG_REGID_RSCONFIG01_LOW 0x0000020BL
  1047. #define DREG_REGID_RSCONFIG01_HIGH 0x0000020CL
  1048. #define DREG_REGID_RSCONFIG23_LOW 0x0000020DL
  1049. #define DREG_REGID_RSCONFIG23_HIGH 0x0000020EL
  1050. #define DREG_REGID_RSDMA01E 0x0000020FL
  1051. #define DREG_REGID_RSDMA23E 0x00000210L
  1052. #define DREG_REGID_RSD0_LOW 0x00000211L
  1053. #define DREG_REGID_RSD0_HIGH 0x00000212L
  1054. #define DREG_REGID_RSD1_LOW 0x00000213L
  1055. #define DREG_REGID_RSD1_HIGH 0x00000214L
  1056. #define DREG_REGID_RSD2_LOW 0x00000215L
  1057. #define DREG_REGID_RSD2_HIGH 0x00000216L
  1058. #define DREG_REGID_RSD3_LOW 0x00000217L
  1059. #define DREG_REGID_RSD3_HIGH 0x00000218L
  1060. #define DREG_REGID_SRAR_HIGH 0x0000021AL
  1061. #define DREG_REGID_SRAR_LOW 0x0000021BL
  1062. #define DREG_REGID_DMA_STATE 0x0000021CL
  1063. #define DREG_REGID_CURRENT_DMA_STREAM 0x0000021DL
  1064. #define DREG_REGID_NEXT_DMA_STREAM 0x0000021EL
  1065. #define DREG_REGID_CPU_STATUS 0x00000300L
  1066. #define DREG_REGID_MAC_MODE 0x00000301L
  1067. #define DREG_REGID_STACK_AND_REPEAT 0x00000302L
  1068. #define DREG_REGID_INDEX0 0x00000304L
  1069. #define DREG_REGID_INDEX1 0x00000305L
  1070. #define DREG_REGID_DMA_STATE_0_3 0x00000400L
  1071. #define DREG_REGID_DMA_STATE_4_7 0x00000404L
  1072. #define DREG_REGID_DMA_STATE_8_11 0x00000408L
  1073. #define DREG_REGID_DMA_STATE_12_15 0x0000040CL
  1074. #define DREG_REGID_DMA_STATE_16_19 0x00000410L
  1075. #define DREG_REGID_DMA_STATE_20_23 0x00000414L
  1076. #define DREG_REGID_DMA_STATE_24_27 0x00000418L
  1077. #define DREG_REGID_DMA_STATE_28_31 0x0000041CL
  1078. #define DREG_REGID_DMA_STATE_32_35 0x00000420L
  1079. #define DREG_REGID_DMA_STATE_36_39 0x00000424L
  1080. #define DREG_REGID_DMA_STATE_40_43 0x00000428L
  1081. #define DREG_REGID_DMA_STATE_44_47 0x0000042CL
  1082. #define DREG_REGID_DMA_STATE_48_51 0x00000430L
  1083. #define DREG_REGID_DMA_STATE_52_55 0x00000434L
  1084. #define DREG_REGID_DMA_STATE_56_59 0x00000438L
  1085. #define DREG_REGID_DMA_STATE_60_63 0x0000043CL
  1086. #define DREG_REGID_DMA_STATE_64_67 0x00000440L
  1087. #define DREG_REGID_DMA_STATE_68_71 0x00000444L
  1088. #define DREG_REGID_DMA_STATE_72_75 0x00000448L
  1089. #define DREG_REGID_DMA_STATE_76_79 0x0000044CL
  1090. #define DREG_REGID_DMA_STATE_80_83 0x00000450L
  1091. #define DREG_REGID_DMA_STATE_84_87 0x00000454L
  1092. #define DREG_REGID_DMA_STATE_88_91 0x00000458L
  1093. #define DREG_REGID_DMA_STATE_92_95 0x0000045CL
  1094. #define DREG_REGID_TRAP_SELECT 0x00000500L
  1095. #define DREG_REGID_TRAP_WRITE_0 0x00000500L
  1096. #define DREG_REGID_TRAP_WRITE_1 0x00000501L
  1097. #define DREG_REGID_TRAP_WRITE_2 0x00000502L
  1098. #define DREG_REGID_TRAP_WRITE_3 0x00000503L
  1099. #define DREG_REGID_TRAP_WRITE_4 0x00000504L
  1100. #define DREG_REGID_TRAP_WRITE_5 0x00000505L
  1101. #define DREG_REGID_TRAP_WRITE_6 0x00000506L
  1102. #define DREG_REGID_TRAP_WRITE_7 0x00000507L
  1103. #if !defined(NO_CS4612)
  1104. #if !defined(NO_CS4615)
  1105. #define DREG_REGID_TRAP_WRITE_8 0x00000510L
  1106. #define DREG_REGID_TRAP_WRITE_9 0x00000511L
  1107. #define DREG_REGID_TRAP_WRITE_10 0x00000512L
  1108. #define DREG_REGID_TRAP_WRITE_11 0x00000513L
  1109. #define DREG_REGID_TRAP_WRITE_12 0x00000514L
  1110. #define DREG_REGID_TRAP_WRITE_13 0x00000515L
  1111. #define DREG_REGID_TRAP_WRITE_14 0x00000516L
  1112. #define DREG_REGID_TRAP_WRITE_15 0x00000517L
  1113. #define DREG_REGID_TRAP_WRITE_16 0x00000518L
  1114. #define DREG_REGID_TRAP_WRITE_17 0x00000519L
  1115. #define DREG_REGID_TRAP_WRITE_18 0x0000051AL
  1116. #define DREG_REGID_TRAP_WRITE_19 0x0000051BL
  1117. #define DREG_REGID_TRAP_WRITE_20 0x0000051CL
  1118. #define DREG_REGID_TRAP_WRITE_21 0x0000051DL
  1119. #define DREG_REGID_TRAP_WRITE_22 0x0000051EL
  1120. #define DREG_REGID_TRAP_WRITE_23 0x0000051FL
  1121. #endif
  1122. #endif
  1123. #define DREG_REGID_MAC0_ACC0_LOW 0x00000600L
  1124. #define DREG_REGID_MAC0_ACC1_LOW 0x00000601L
  1125. #define DREG_REGID_MAC0_ACC2_LOW 0x00000602L
  1126. #define DREG_REGID_MAC0_ACC3_LOW 0x00000603L
  1127. #define DREG_REGID_MAC1_ACC0_LOW 0x00000604L
  1128. #define DREG_REGID_MAC1_ACC1_LOW 0x00000605L
  1129. #define DREG_REGID_MAC1_ACC2_LOW 0x00000606L
  1130. #define DREG_REGID_MAC1_ACC3_LOW 0x00000607L
  1131. #define DREG_REGID_MAC0_ACC0_MID 0x00000608L
  1132. #define DREG_REGID_MAC0_ACC1_MID 0x00000609L
  1133. #define DREG_REGID_MAC0_ACC2_MID 0x0000060AL
  1134. #define DREG_REGID_MAC0_ACC3_MID 0x0000060BL
  1135. #define DREG_REGID_MAC1_ACC0_MID 0x0000060CL
  1136. #define DREG_REGID_MAC1_ACC1_MID 0x0000060DL
  1137. #define DREG_REGID_MAC1_ACC2_MID 0x0000060EL
  1138. #define DREG_REGID_MAC1_ACC3_MID 0x0000060FL
  1139. #define DREG_REGID_MAC0_ACC0_HIGH 0x00000610L
  1140. #define DREG_REGID_MAC0_ACC1_HIGH 0x00000611L
  1141. #define DREG_REGID_MAC0_ACC2_HIGH 0x00000612L
  1142. #define DREG_REGID_MAC0_ACC3_HIGH 0x00000613L
  1143. #define DREG_REGID_MAC1_ACC0_HIGH 0x00000614L
  1144. #define DREG_REGID_MAC1_ACC1_HIGH 0x00000615L
  1145. #define DREG_REGID_MAC1_ACC2_HIGH 0x00000616L
  1146. #define DREG_REGID_MAC1_ACC3_HIGH 0x00000617L
  1147. #define DREG_REGID_RSHOUT_LOW 0x00000620L
  1148. #define DREG_REGID_RSHOUT_MID 0x00000628L
  1149. #define DREG_REGID_RSHOUT_HIGH 0x00000630L
  1150. //****************************************************************************
  1151. //
  1152. // The following defines are for the flags in the AC97 S/PDIF Control register.
  1153. //
  1154. //****************************************************************************
  1155. #define SPDIF_CONTROL_SPDIF_EN 0x00008000L
  1156. #define SPDIF_CONTROL_VAL 0x00004000L
  1157. #define SPDIF_CONTROL_COPY 0x00000004L
  1158. #define SPDIF_CONTROL_CC0 0x00000010L
  1159. #define SPDIF_CONTROL_CC1 0x00000020L
  1160. #define SPDIF_CONTROL_CC2 0x00000040L
  1161. #define SPDIF_CONTROL_CC3 0x00000080L
  1162. #define SPDIF_CONTROL_CC4 0x00000100L
  1163. #define SPDIF_CONTROL_CC5 0x00000200L
  1164. #define SPDIF_CONTROL_CC6 0x00000400L
  1165. #define SPDIF_CONTROL_L 0x00000800L
  1166. #endif // _H_HWDEFS