Linux 3.17-rc2
[linux/fpc-iii.git] / arch / unicore32 / include / mach / regs-ac97.h
blobb7563e9d65035be409221f37bc289a2f7199f297
1 /*
2 * PKUnity AC97 Registers
3 */
5 #define PKUNITY_AC97_CONR (PKUNITY_AC97_BASE + 0x0000)
6 #define PKUNITY_AC97_OCR (PKUNITY_AC97_BASE + 0x0004)
7 #define PKUNITY_AC97_ICR (PKUNITY_AC97_BASE + 0x0008)
8 #define PKUNITY_AC97_CRAC (PKUNITY_AC97_BASE + 0x000C)
9 #define PKUNITY_AC97_INTR (PKUNITY_AC97_BASE + 0x0010)
10 #define PKUNITY_AC97_INTRSTAT (PKUNITY_AC97_BASE + 0x0014)
11 #define PKUNITY_AC97_INTRCLEAR (PKUNITY_AC97_BASE + 0x0018)
12 #define PKUNITY_AC97_ENABLE (PKUNITY_AC97_BASE + 0x001C)
13 #define PKUNITY_AC97_OUT_FIFO (PKUNITY_AC97_BASE + 0x0020)
14 #define PKUNITY_AC97_IN_FIFO (PKUNITY_AC97_BASE + 0x0030)
16 #define AC97_CODEC_REG(v) FIELD((v), 7, 16)
17 #define AC97_CODEC_VAL(v) FIELD((v), 16, 0)
18 #define AC97_CODEC_WRITECOMPLETE FIELD(1, 1, 2)
21 * VAR PLAY SAMPLE RATE
23 #define AC97_CMD_VPSAMPLE (FIELD(3, 2, 16) | FIELD(3, 2, 0))
26 * FIX CAPTURE SAMPLE RATE
28 #define AC97_CMD_FCSAMPLE FIELD(7, 3, 0)
30 #define AC97_CMD_RESET FIELD(1, 1, 0)
31 #define AC97_CMD_ENABLE FIELD(1, 1, 0)
32 #define AC97_CMD_DISABLE FIELD(0, 1, 0)