[alsa-devel] [PATCH - hdsp.c 1/1] HDSP fixes for RPM
Adrian Knoth
adi at drcomp.erfurt.thur.de
Sat Dec 1 23:10:01 CET 2012
On 11/21/2012 10:33 PM, Karl Grill wrote:
> - hdsp_write (hdsp, HDSP_control2Reg, HDSP_PROGRAM);
> + hdsp_write (hdsp, HDSP_control2Reg, 0x10a0);
Where did you get the constant(s) from? Bus snooping?
> + if (hdsp_fifo_wait (hdsp, 0, HDSP_SHORT_WAIT) < 0) {
> + hdsp->io_type=Multiface;
> + snd_printk("Hammerfall-DSP: Multiface found\n");
> + return 0;
> + }
> + hdsp_write(hdsp, HDSP_control2Reg, 0x10a0);
> + hdsp_write (hdsp, HDSP_fifoData, 0);
> + if (hdsp_fifo_wait (hdsp, 0, HDSP_SHORT_WAIT) == 0) {
> + hdsp->io_type=Digiface;
> + snd_printk("Hammerfall-DSP: Digiface found\n");
> + return 0;
> + }
> + hdsp_write(hdsp, HDSP_control2Reg, 0x900);
> + hdsp_write(hdsp, HDSP_control2Reg, 0x10a0);
> + hdsp_write (hdsp, HDSP_fifoData, 0);
> + if (hdsp_fifo_wait (hdsp, 0, HDSP_SHORT_WAIT) == 0) {
> + hdsp->io_type=Multiface;
> + snd_printk("Hammerfall-DSP: Multiface found\n");
> + return 0;
> + }
> + hdsp_write(hdsp, HDSP_control2Reg, 0x900);
> + hdsp_write(hdsp, HDSP_control2Reg, 0x10a0);
> + hdsp_write (hdsp, HDSP_fifoData, 0);
> + if (hdsp_fifo_wait (hdsp, 0, HDSP_SHORT_WAIT) < 0) {
> + hdsp->io_type=Multiface;
> + snd_printk("Hammerfall-DSP: Multiface found\n");
> + return 0;
> }
> + hdsp->io_type=RPM;
> + snd_printk("Hammerfall-DSP: RPM found\n");
> + return 0;
> +
Question: I see two sequences of 0x900, 0x10a0 that detect the
Multiface. Is the duplicate intended or just a copy&paste error?
Cheers
More information about the Alsa-devel
mailing list