aboutsummaryrefslogtreecommitdiff
path: root/sound/pci/emu10k1/emu10k1_main.c
diff options
context:
space:
mode:
authorJames Courtier-Dutton <James@superbug.co.uk>2007-07-26 18:31:39 +0100
committerJaroslav Kysela <perex@perex.cz>2007-10-16 15:58:03 +0200
commitf93abe51e8dc7e929d29e6a9a1991bf7fd234d4a (patch)
treee23ba606e72d14b59297a8d2937d1b76f34e5e2a /sound/pci/emu10k1/emu10k1_main.c
parent95a5b0850a96c155f6b8dac03f45c19bc482ced7 (diff)
[ALSA] snd-emu10k1:Implement SPDIF/ADAT status.
Signed-off-by: James Courtier-Dutton <James@superbug.co.uk> Signed-off-by: Jaroslav Kysela <perex@suse.cz>
Diffstat (limited to 'sound/pci/emu10k1/emu10k1_main.c')
-rw-r--r--sound/pci/emu10k1/emu10k1_main.c10
1 files changed, 9 insertions, 1 deletions
diff --git a/sound/pci/emu10k1/emu10k1_main.c b/sound/pci/emu10k1/emu10k1_main.c
index b985e660c60..e22bb717e96 100644
--- a/sound/pci/emu10k1/emu10k1_main.c
+++ b/sound/pci/emu10k1/emu10k1_main.c
@@ -873,7 +873,15 @@ static int snd_emu10k1_emu1010_init(struct snd_emu10k1 * emu)
snd_printk(KERN_INFO "emu1010: Card options=0x%x\n",reg);
snd_emu1010_fpga_read(emu, EMU_HANA_OPTICAL_TYPE, &tmp );
/* Optical -> ADAT I/O */
- snd_emu1010_fpga_write(emu, EMU_HANA_OPTICAL_TYPE, EMU_HANA_OPTICAL_IN_ADAT | EMU_HANA_OPTICAL_OUT_ADAT );
+ /* 0 : SPDIF
+ * 1 : ADAT
+ */
+ emu->emu1010.optical_in = 1; /* IN_ADAT */
+ emu->emu1010.optical_out = 1; /* IN_ADAT */
+ tmp = 0;
+ tmp = (emu->emu1010.optical_in ? EMU_HANA_OPTICAL_IN_ADAT : 0) |
+ (emu->emu1010.optical_out ? EMU_HANA_OPTICAL_OUT_ADAT : 0);
+ snd_emu1010_fpga_write(emu, EMU_HANA_OPTICAL_TYPE, tmp );
snd_emu1010_fpga_read(emu, EMU_HANA_ADC_PADS, &tmp );
/* Set no attenuation on Audio Dock pads. */
snd_emu1010_fpga_write(emu, EMU_HANA_ADC_PADS, 0x00 );