blob: 7a3c188ea0a85acc36018ce94c7ad7e85f61a100 [file] [log] [blame]
Linus Torvalds1da177e2005-04-16 15:20:36 -07001/* (C) 2000 Guenter Geiger <geiger@debian.org>
2 with copy/pastes from the driver of Winfried Ritsch <ritsch@iem.kug.ac.at>
3
4Modifications - Heiko Purnhagen <purnhage@tnt.uni-hannover.de>
5 HP20020116 towards REV 1.5 support, based on ALSA's card-rme9652.c
6 HP20020201 completed?
7
8A text/graphic control panel (rmectrl/xrmectrl) is available from
9 http://gige.xdv.org/pages/soft/pages/rme
10*/
11
12
13#ifndef AFMT_S32_BLOCKED
14#define AFMT_S32_BLOCKED 0x0000400
15#endif
16
17/* AFMT_S16_BLOCKED not yet supported */
18#ifndef AFMT_S16_BLOCKED
19#define AFMT_S16_BLOCKED 0x0000800
20#endif
21
22
23typedef struct rme_status {
24 unsigned int irq:1;
25 unsigned int lockmask:3; /* ADAT input PLLs locked */
26 /* 100=ADAT1, 010=ADAT2, 001=ADAT3 */
27 unsigned int sr48:1; /* sample rate: 0=44.1/88.2 1=48/96 kHz */
28 unsigned int wclock:1; /* 1=wordclock used */
29 unsigned int bufpoint:10;
30 unsigned int syncmask:3; /* ADAT input in sync with system clock */
31 /* 100=ADAT1, 010=ADAT2, 001=ADAT3 */
32 unsigned int doublespeed:1; /* sample rate: 0=44.1/48 1=88.2/96 kHz */
33 unsigned int tc_busy:1;
34 unsigned int tc_out:1;
35 unsigned int crystalrate:3; /* spdif input sample rate: */
36 /* 000=64kHz, 100=88.2kHz, 011=96kHz */
37 /* 111=32kHz, 110=44.1kHz, 101=48kHz */
38 unsigned int spdif_error:1; /* 1=no spdif lock */
39 unsigned int bufid:1;
40 unsigned int tc_valid:1; /* 1=timecode input detected */
41 unsigned int spdif_read:1;
42} rme_status_t;
43
44
45/* only fields marked W: can be modified by writing to SOUND_MIXER_PRIVATE3 */
46typedef struct rme_control {
47 unsigned int start:1;
48 unsigned int latency:3; /* buffer size / latency [samples]: */
49 /* 0=64 ... 7=8192 */
50 unsigned int master:1; /* W: clock mode: 1=master 0=slave/auto */
51 unsigned int ie:1;
52 unsigned int sr48:1; /* samplerate 0=44.1/88.2, 1=48/96 kHz */
53 unsigned int spare:1;
54 unsigned int doublespeed:1; /* double speed 0=44.1/48, 1=88.2/96 Khz */
55 unsigned int pro:1; /* W: SPDIF-OUT 0=consumer, 1=professional */
56 unsigned int emphasis:1; /* W: SPDIF-OUT emphasis 0=off, 1=on */
57 unsigned int dolby:1; /* W: SPDIF-OUT non-audio bit 1=set, 0=unset */
58 unsigned int opt_out:1; /* W: use 1st optical OUT as SPDIF: 1=yes, 0=no */
59 unsigned int wordclock:1; /* W: use Wordclock as sync (overwrites master) */
60 unsigned int spdif_in:2; /* W: SPDIF-IN: */
61 /* 00=optical (ADAT1), 01=coaxial (Cinch), 10=internal CDROM */
62 unsigned int sync_ref:2; /* W: preferred sync-source in autosync */
63 /* 00=ADAT1, 01=ADAT2, 10=ADAT3, 11=SPDIF */
64 unsigned int spdif_reset:1;
65 unsigned int spdif_select:1;
66 unsigned int spdif_clock:1;
67 unsigned int spdif_write:1;
68 unsigned int adat1_cd:1; /* W: Rev 1.5+: if set, internal CD connector carries ADAT */
69} rme_ctrl_t;
70
71
72typedef struct _rme_mixer {
73 int i_offset;
74 int o_offset;
75 int devnr;
76 int spare[8];
77} rme_mixer;
78