Lines Matching +full:col +full:- +full:offset

1 // SPDX-License-Identifier: GPL-2.0-or-later
6 * 2002-07 Benny Sjostrand benny@hostmobility.com
51 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in shadow_and_reallocate_code()
54 return -EINVAL; in shadow_and_reallocate_code()
60 if (ins->code.offset > 0) { in shadow_and_reallocate_code()
75 dev_dbg(chip->card->dev, in shadow_and_reallocate_code()
80 address += (ins->code.offset / 2) - overlay_begin_address; in shadow_and_reallocate_code()
82 dev_dbg(chip->card->dev, in shadow_and_reallocate_code()
95 dev_dbg(chip->card->dev, in shadow_and_reallocate_code()
102 } /* ins->code.offset > 0 */ in shadow_and_reallocate_code()
104 ins->code.data[ins->code.size++] = loval; in shadow_and_reallocate_code()
105 ins->code.data[ins->code.size++] = hival; in shadow_and_reallocate_code()
108 dev_dbg(chip->card->dev, in shadow_and_reallocate_code()
116 for (i = 0;i < module->nsegments; ++i) { in get_segment_desc()
117 if (module->segments[i].segment_type == seg_type) { in get_segment_desc()
118 return (module->segments + i); in get_segment_desc()
127 int index = ins->symbol_table.nsymbols,i; in find_free_symbol_index()
129 for (i = ins->symbol_table.highest_frag_index; i < ins->symbol_table.nsymbols; ++i) { in find_free_symbol_index()
130 if (ins->symbol_table.symbols[i].deleted) { in find_free_symbol_index()
142 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in add_symbols()
144 if (module->symbol_table.nsymbols > 0) { in add_symbols()
145 if (!strcmp(module->symbol_table.symbols[0].symbol_name, "OVERLAYBEGINADDRESS") && in add_symbols()
146 module->symbol_table.symbols[0].symbol_type == SYMBOL_CONSTANT ) { in add_symbols()
147 module->overlay_begin_address = module->symbol_table.symbols[0].address; in add_symbols()
151 for (i = 0;i < module->symbol_table.nsymbols; ++i) { in add_symbols()
152 if (ins->symbol_table.nsymbols == (DSP_MAX_SYMBOLS - 1)) { in add_symbols()
153 dev_err(chip->card->dev, in add_symbols()
155 return -ENOMEM; in add_symbols()
160 module->symbol_table.symbols[i].symbol_name, in add_symbols()
161 module->symbol_table.symbols[i].symbol_type) == NULL) { in add_symbols()
163 ins->symbol_table.symbols[ins->symbol_table.nsymbols] = module->symbol_table.symbols[i]; in add_symbols()
164 …ins->symbol_table.symbols[ins->symbol_table.nsymbols].address += ((ins->code.offset / 2) - module- in add_symbols()
165 ins->symbol_table.symbols[ins->symbol_table.nsymbols].module = module; in add_symbols()
166 ins->symbol_table.symbols[ins->symbol_table.nsymbols].deleted = 0; in add_symbols()
168 if (ins->symbol_table.nsymbols > ins->symbol_table.highest_frag_index) in add_symbols()
169 ins->symbol_table.highest_frag_index = ins->symbol_table.nsymbols; in add_symbols()
171 ins->symbol_table.nsymbols++; in add_symbols()
174 dev_dbg(chip->card->dev, in add_symbols()
176 module->symbol_table.symbols[i].symbol_name); */ in add_symbols()
187 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in add_symbol()
191 if (ins->symbol_table.nsymbols == (DSP_MAX_SYMBOLS - 1)) { in add_symbol()
192 dev_err(chip->card->dev, "dsp_spos: symbol table is full\n"); in add_symbol()
199 dev_err(chip->card->dev, in add_symbol()
206 strcpy (ins->symbol_table.symbols[index].symbol_name, symbol_name); in add_symbol()
207 ins->symbol_table.symbols[index].address = address; in add_symbol()
208 ins->symbol_table.symbols[index].symbol_type = type; in add_symbol()
209 ins->symbol_table.symbols[index].module = NULL; in add_symbol()
210 ins->symbol_table.symbols[index].deleted = 0; in add_symbol()
211 symbol = (ins->symbol_table.symbols + index); in add_symbol()
213 if (index > ins->symbol_table.highest_frag_index) in add_symbol()
214 ins->symbol_table.highest_frag_index = index; in add_symbol()
216 if (index == ins->symbol_table.nsymbols) in add_symbol()
217 ins->symbol_table.nsymbols++; /* no frag. in list */ in add_symbol()
230 ins->symbol_table.symbols = in cs46xx_dsp_spos_create()
233 ins->code.data = kmalloc(DSP_CODE_BYTE_SIZE, GFP_KERNEL); in cs46xx_dsp_spos_create()
234 ins->modules = kmalloc_array(DSP_MAX_MODULES, in cs46xx_dsp_spos_create()
237 if (!ins->symbol_table.symbols || !ins->code.data || !ins->modules) { in cs46xx_dsp_spos_create()
241 ins->symbol_table.nsymbols = 0; in cs46xx_dsp_spos_create()
242 ins->symbol_table.highest_frag_index = 0; in cs46xx_dsp_spos_create()
243 ins->code.offset = 0; in cs46xx_dsp_spos_create()
244 ins->code.size = 0; in cs46xx_dsp_spos_create()
245 ins->nscb = 0; in cs46xx_dsp_spos_create()
246 ins->ntask = 0; in cs46xx_dsp_spos_create()
247 ins->nmodules = 0; in cs46xx_dsp_spos_create()
251 ins->spdif_in_sample_rate = 48000; in cs46xx_dsp_spos_create()
254 ins->dac_volume_right = 0x8000; in cs46xx_dsp_spos_create()
255 ins->dac_volume_left = 0x8000; in cs46xx_dsp_spos_create()
256 ins->spdif_input_volume_right = 0x8000; in cs46xx_dsp_spos_create()
257 ins->spdif_input_volume_left = 0x8000; in cs46xx_dsp_spos_create()
261 ins->spdif_csuv_default = in cs46xx_dsp_spos_create()
262 ins->spdif_csuv_stream = in cs46xx_dsp_spos_create()
271 kfree(ins->modules); in cs46xx_dsp_spos_create()
272 kfree(ins->code.data); in cs46xx_dsp_spos_create()
273 vfree(ins->symbol_table.symbols); in cs46xx_dsp_spos_create()
281 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_spos_destroy()
286 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_spos_destroy()
287 for (i = 0; i < ins->nscb; ++i) { in cs46xx_dsp_spos_destroy()
288 if (ins->scbs[i].deleted) continue; in cs46xx_dsp_spos_destroy()
290 cs46xx_dsp_proc_free_scb_desc ( (ins->scbs + i) ); in cs46xx_dsp_spos_destroy()
292 kfree(ins->scbs[i].data); in cs46xx_dsp_spos_destroy()
296 kfree(ins->code.data); in cs46xx_dsp_spos_destroy()
297 vfree(ins->symbol_table.symbols); in cs46xx_dsp_spos_destroy()
298 kfree(ins->modules); in cs46xx_dsp_spos_destroy()
300 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_spos_destroy()
309 dev_dbg(chip->card->dev, in dsp_load_parameter()
314 doffset = (parameter->offset * 4 + DSP_PARAMETER_BYTE_OFFSET); in dsp_load_parameter()
315 dsize = parameter->size * 4; in dsp_load_parameter()
317 dev_dbg(chip->card->dev, in dsp_load_parameter()
318 "dsp_spos: downloading parameter data to chip (%08x-%08x)\n", in dsp_load_parameter()
320 if (snd_cs46xx_download (chip, parameter->data, doffset, dsize)) { in dsp_load_parameter()
321 dev_err(chip->card->dev, in dsp_load_parameter()
323 return -EINVAL; in dsp_load_parameter()
334 dev_dbg(chip->card->dev, in dsp_load_sample()
339 doffset = (sample->offset * 4 + DSP_SAMPLE_BYTE_OFFSET); in dsp_load_sample()
340 dsize = sample->size * 4; in dsp_load_sample()
342 dev_dbg(chip->card->dev, in dsp_load_sample()
343 "dsp_spos: downloading sample data to chip (%08x-%08x)\n", in dsp_load_sample()
346 if (snd_cs46xx_download (chip,sample->data,doffset,dsize)) { in dsp_load_sample()
347 dev_err(chip->card->dev, in dsp_load_sample()
349 return -EINVAL; in dsp_load_sample()
356 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_load_module()
361 if (ins->nmodules == DSP_MAX_MODULES - 1) { in cs46xx_dsp_load_module()
362 dev_err(chip->card->dev, in cs46xx_dsp_load_module()
364 return -ENOMEM; in cs46xx_dsp_load_module()
367 dev_dbg(chip->card->dev, in cs46xx_dsp_load_module()
368 "dsp_spos: loading module %s into DSP\n", module->module_name); in cs46xx_dsp_load_module()
370 if (ins->nmodules == 0) { in cs46xx_dsp_load_module()
371 dev_dbg(chip->card->dev, "dsp_spos: clearing parameter area\n"); in cs46xx_dsp_load_module()
380 if (ins->nmodules == 0) { in cs46xx_dsp_load_module()
381 dev_dbg(chip->card->dev, "dsp_spos: clearing sample area\n"); in cs46xx_dsp_load_module()
390 if (ins->nmodules == 0) { in cs46xx_dsp_load_module()
391 dev_dbg(chip->card->dev, "dsp_spos: clearing code area\n"); in cs46xx_dsp_load_module()
396 dev_dbg(chip->card->dev, in cs46xx_dsp_load_module()
399 if (ins->code.offset + code->size > DSP_CODE_BYTE_SIZE) { in cs46xx_dsp_load_module()
400 dev_err(chip->card->dev, in cs46xx_dsp_load_module()
402 return -ENOMEM; in cs46xx_dsp_load_module()
405 module->load_address = ins->code.offset; in cs46xx_dsp_load_module()
406 module->overlay_begin_address = 0x000; in cs46xx_dsp_load_module()
410 if (snd_BUG_ON(!module->symbol_table.symbols)) in cs46xx_dsp_load_module()
411 return -ENOMEM; in cs46xx_dsp_load_module()
413 dev_err(chip->card->dev, in cs46xx_dsp_load_module()
415 return -ENOMEM; in cs46xx_dsp_load_module()
418 doffset = (code->offset * 4 + ins->code.offset * 4 + DSP_CODE_BYTE_OFFSET); in cs46xx_dsp_load_module()
419 dsize = code->size * 4; in cs46xx_dsp_load_module()
420 dev_dbg(chip->card->dev, in cs46xx_dsp_load_module()
421 "dsp_spos: downloading code to chip (%08x-%08x)\n", in cs46xx_dsp_load_module()
424 …module->nfixups = shadow_and_reallocate_code(chip,code->data,code->size,module->overlay_begin_addr… in cs46xx_dsp_load_module()
426 if (snd_cs46xx_download (chip,(ins->code.data + ins->code.offset),doffset,dsize)) { in cs46xx_dsp_load_module()
427 dev_err(chip->card->dev, in cs46xx_dsp_load_module()
429 return -EINVAL; in cs46xx_dsp_load_module()
432 ins->code.offset += code->size; in cs46xx_dsp_load_module()
438 ins->modules[ins->nmodules] = *module; in cs46xx_dsp_load_module()
439 ins->nmodules++; in cs46xx_dsp_load_module()
448 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_lookup_symbol()
450 for ( i = 0; i < ins->symbol_table.nsymbols; ++i ) { in cs46xx_dsp_lookup_symbol()
452 if (ins->symbol_table.symbols[i].deleted) in cs46xx_dsp_lookup_symbol()
455 if (!strcmp(ins->symbol_table.symbols[i].symbol_name,symbol_name) && in cs46xx_dsp_lookup_symbol()
456 ins->symbol_table.symbols[i].symbol_type == symbol_type) { in cs46xx_dsp_lookup_symbol()
457 return (ins->symbol_table.symbols + i); in cs46xx_dsp_lookup_symbol()
462 dev_err(chip->card->dev, "dsp_spos: symbol <%s> type %02x not found\n", in cs46xx_dsp_lookup_symbol()
475 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_lookup_symbol_addr()
477 for ( i = 0; i < ins->symbol_table.nsymbols; ++i ) { in cs46xx_dsp_lookup_symbol_addr()
479 if (ins->symbol_table.symbols[i].deleted) in cs46xx_dsp_lookup_symbol_addr()
482 if (ins->symbol_table.symbols[i].address == address && in cs46xx_dsp_lookup_symbol_addr()
483 ins->symbol_table.symbols[i].symbol_type == symbol_type) { in cs46xx_dsp_lookup_symbol_addr()
484 return (ins->symbol_table.symbols + i); in cs46xx_dsp_lookup_symbol_addr()
496 struct snd_cs46xx *chip = entry->private_data; in cs46xx_dsp_proc_symbol_table_read()
497 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_proc_symbol_table_read()
501 for ( i = 0; i < ins->symbol_table.nsymbols; ++i ) { in cs46xx_dsp_proc_symbol_table_read()
504 if (ins->symbol_table.symbols[i].deleted) in cs46xx_dsp_proc_symbol_table_read()
507 if (ins->symbol_table.symbols[i].module != NULL) { in cs46xx_dsp_proc_symbol_table_read()
508 module_str = ins->symbol_table.symbols[i].module->module_name; in cs46xx_dsp_proc_symbol_table_read()
513 ins->symbol_table.symbols[i].address, in cs46xx_dsp_proc_symbol_table_read()
514 ins->symbol_table.symbols[i].symbol_type, in cs46xx_dsp_proc_symbol_table_read()
515 ins->symbol_table.symbols[i].symbol_name, in cs46xx_dsp_proc_symbol_table_read()
524 struct snd_cs46xx *chip = entry->private_data; in cs46xx_dsp_proc_modules_read()
525 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_proc_modules_read()
528 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_proc_modules_read()
530 for ( i = 0; i < ins->nmodules; ++i ) { in cs46xx_dsp_proc_modules_read()
531 snd_iprintf(buffer, "\n%s:\n", ins->modules[i].module_name); in cs46xx_dsp_proc_modules_read()
532 snd_iprintf(buffer, " %d symbols\n", ins->modules[i].symbol_table.nsymbols); in cs46xx_dsp_proc_modules_read()
533 snd_iprintf(buffer, " %d fixups\n", ins->modules[i].nfixups); in cs46xx_dsp_proc_modules_read()
535 for (j = 0; j < ins->modules[i].nsegments; ++ j) { in cs46xx_dsp_proc_modules_read()
536 struct dsp_segment_desc * desc = (ins->modules[i].segments + j); in cs46xx_dsp_proc_modules_read()
537 snd_iprintf(buffer, " segment %02x offset %08x size %08x\n", in cs46xx_dsp_proc_modules_read()
538 desc->segment_type,desc->offset, desc->size); in cs46xx_dsp_proc_modules_read()
541 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_proc_modules_read()
547 struct snd_cs46xx *chip = entry->private_data; in cs46xx_dsp_proc_task_tree_read()
548 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_proc_task_tree_read()
549 int i, j, col; in cs46xx_dsp_proc_task_tree_read() local
550 void __iomem *dst = chip->region.idx[1].remap_addr + DSP_PARAMETER_BYTE_OFFSET; in cs46xx_dsp_proc_task_tree_read()
552 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_proc_task_tree_read()
554 for ( i = 0; i < ins->ntask; ++i) { in cs46xx_dsp_proc_task_tree_read()
555 snd_iprintf(buffer,"\n%04x %s:\n",ins->tasks[i].address,ins->tasks[i].task_name); in cs46xx_dsp_proc_task_tree_read()
557 for (col = 0,j = 0;j < ins->tasks[i].size; j++,col++) { in cs46xx_dsp_proc_task_tree_read()
559 if (col == 4) { in cs46xx_dsp_proc_task_tree_read()
561 col = 0; in cs46xx_dsp_proc_task_tree_read()
563 val = readl(dst + (ins->tasks[i].address + j) * sizeof(u32)); in cs46xx_dsp_proc_task_tree_read()
569 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_proc_task_tree_read()
575 struct snd_cs46xx *chip = entry->private_data; in cs46xx_dsp_proc_scb_read()
576 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_proc_scb_read()
579 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_proc_scb_read()
581 for ( i = 0; i < ins->nscb; ++i) { in cs46xx_dsp_proc_scb_read()
582 if (ins->scbs[i].deleted) in cs46xx_dsp_proc_scb_read()
584 snd_iprintf(buffer,"\n%04x %s:\n\n",ins->scbs[i].address,ins->scbs[i].scb_name); in cs46xx_dsp_proc_scb_read()
586 if (ins->scbs[i].parent_scb_ptr != NULL) { in cs46xx_dsp_proc_scb_read()
588 ins->scbs[i].parent_scb_ptr->scb_name, in cs46xx_dsp_proc_scb_read()
589 ins->scbs[i].parent_scb_ptr->address); in cs46xx_dsp_proc_scb_read()
593 ins->scbs[i].sub_list_ptr->scb_name, in cs46xx_dsp_proc_scb_read()
594 ins->scbs[i].sub_list_ptr->address, in cs46xx_dsp_proc_scb_read()
595 ins->scbs[i].next_scb_ptr->scb_name, in cs46xx_dsp_proc_scb_read()
596 ins->scbs[i].next_scb_ptr->address, in cs46xx_dsp_proc_scb_read()
597 ins->scbs[i].task_entry->symbol_name, in cs46xx_dsp_proc_scb_read()
598 ins->scbs[i].task_entry->address); in cs46xx_dsp_proc_scb_read()
602 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_proc_scb_read()
608 struct snd_cs46xx *chip = entry->private_data; in cs46xx_dsp_proc_parameter_dump_read()
609 /*struct dsp_spos_instance * ins = chip->dsp_spos_instance; */ in cs46xx_dsp_proc_parameter_dump_read()
610 unsigned int i, col = 0; in cs46xx_dsp_proc_parameter_dump_read() local
611 void __iomem *dst = chip->region.idx[1].remap_addr + DSP_PARAMETER_BYTE_OFFSET; in cs46xx_dsp_proc_parameter_dump_read()
614 for (i = 0;i < DSP_PARAMETER_BYTE_SIZE; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_parameter_dump_read()
615 if (col == 4) { in cs46xx_dsp_proc_parameter_dump_read()
617 col = 0; in cs46xx_dsp_proc_parameter_dump_read()
622 col = 0; in cs46xx_dsp_proc_parameter_dump_read()
623 snd_iprintf (buffer,"\n%s:\n",symbol->symbol_name); in cs46xx_dsp_proc_parameter_dump_read()
626 if (col == 0) { in cs46xx_dsp_proc_parameter_dump_read()
637 struct snd_cs46xx *chip = entry->private_data; in cs46xx_dsp_proc_sample_dump_read()
638 int i,col = 0; in cs46xx_dsp_proc_sample_dump_read() local
639 void __iomem *dst = chip->region.idx[2].remap_addr; in cs46xx_dsp_proc_sample_dump_read()
642 for (i = PCM_READER_BUF1;i < PCM_READER_BUF1 + 0x30; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_sample_dump_read()
643 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
645 col = 0; in cs46xx_dsp_proc_sample_dump_read()
648 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
657 col = 0; in cs46xx_dsp_proc_sample_dump_read()
658 for (i = MIX_SAMPLE_BUF1;i < MIX_SAMPLE_BUF1 + 0x40; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_sample_dump_read()
659 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
661 col = 0; in cs46xx_dsp_proc_sample_dump_read()
664 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
672 col = 0; in cs46xx_dsp_proc_sample_dump_read()
673 for (i = 0x2480 ; i < 0x2480 + 0x40 ; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_sample_dump_read()
674 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
676 col = 0; in cs46xx_dsp_proc_sample_dump_read()
679 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
688 col = 0; in cs46xx_dsp_proc_sample_dump_read()
689 for (i = SPDIFO_IP_OUTPUT_BUFFER1;i < SPDIFO_IP_OUTPUT_BUFFER1 + 0x30; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_sample_dump_read()
690 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
692 col = 0; in cs46xx_dsp_proc_sample_dump_read()
695 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
703 col = 0; in cs46xx_dsp_proc_sample_dump_read()
705 …for (i = SPDIFO_IP_OUTPUT_BUFFER1+0xD0;i < SPDIFO_IP_OUTPUT_BUFFER1 + 0x110; i += sizeof(u32),col in cs46xx_dsp_proc_sample_dump_read()
706 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
708 col = 0; in cs46xx_dsp_proc_sample_dump_read()
711 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
720 col = 0; in cs46xx_dsp_proc_sample_dump_read()
721 for (i = OUTPUT_SNOOP_BUFFER;i < OUTPUT_SNOOP_BUFFER + 0x40; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_sample_dump_read()
722 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
724 col = 0; in cs46xx_dsp_proc_sample_dump_read()
727 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
735 col = 0; in cs46xx_dsp_proc_sample_dump_read()
736 for (i = CODEC_INPUT_BUF1;i < CODEC_INPUT_BUF1 + 0x40; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_sample_dump_read()
737 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
739 col = 0; in cs46xx_dsp_proc_sample_dump_read()
742 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
750 col = 0; in cs46xx_dsp_proc_sample_dump_read()
751 for (i = WRITE_BACK_BUF1;i < WRITE_BACK_BUF1 + 0x40; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_sample_dump_read()
752 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
754 col = 0; in cs46xx_dsp_proc_sample_dump_read()
757 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
766 col = 0; in cs46xx_dsp_proc_sample_dump_read()
767 for (i = SPDIFI_IP_OUTPUT_BUFFER1;i < SPDIFI_IP_OUTPUT_BUFFER1 + 0x80; i += sizeof(u32),col ++) { in cs46xx_dsp_proc_sample_dump_read()
768 if (col == 4) { in cs46xx_dsp_proc_sample_dump_read()
770 col = 0; in cs46xx_dsp_proc_sample_dump_read()
773 if (col == 0) { in cs46xx_dsp_proc_sample_dump_read()
785 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_proc_init()
788 ins->snd_card = card; in cs46xx_dsp_proc_init()
790 entry = snd_info_create_card_entry(card, "dsp", card->proc_root); in cs46xx_dsp_proc_init()
792 entry->mode = S_IFDIR | 0555; in cs46xx_dsp_proc_init()
793 ins->proc_dsp_dir = entry; in cs46xx_dsp_proc_init()
795 if (!ins->proc_dsp_dir) in cs46xx_dsp_proc_init()
796 return -ENOMEM; in cs46xx_dsp_proc_init()
799 ins->proc_dsp_dir); in cs46xx_dsp_proc_init()
805 ins->proc_dsp_dir); in cs46xx_dsp_proc_init()
811 ins->proc_dsp_dir); in cs46xx_dsp_proc_init()
817 ins->proc_dsp_dir); in cs46xx_dsp_proc_init()
823 ins->proc_dsp_dir); in cs46xx_dsp_proc_init()
829 ins->proc_dsp_dir); in cs46xx_dsp_proc_init()
834 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_proc_init()
836 for (i = 0; i < ins->nscb; ++i) { in cs46xx_dsp_proc_init()
837 if (ins->scbs[i].deleted) continue; in cs46xx_dsp_proc_init()
839 cs46xx_dsp_proc_register_scb_desc (chip, (ins->scbs + i)); in cs46xx_dsp_proc_init()
841 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_proc_init()
848 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_proc_done()
854 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_proc_done()
855 for (i = 0; i < ins->nscb; ++i) { in cs46xx_dsp_proc_done()
856 if (ins->scbs[i].deleted) continue; in cs46xx_dsp_proc_done()
857 cs46xx_dsp_proc_free_scb_desc ( (ins->scbs + i) ); in cs46xx_dsp_proc_done()
859 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_proc_done()
861 snd_info_free_entry(ins->proc_dsp_dir); in cs46xx_dsp_proc_done()
862 ins->proc_dsp_dir = NULL; in cs46xx_dsp_proc_done()
871 void __iomem *spdst = chip->region.idx[1].remap_addr + in _dsp_create_task_tree()
876 dev_dbg(chip->card->dev, "addr %p, val %08x\n", in _dsp_create_task_tree()
885 void __iomem *spdst = chip->region.idx[1].remap_addr + in _dsp_create_scb()
890 dev_dbg(chip->card->dev, "addr %p, val %08x\n", in _dsp_create_scb()
899 int index = ins->nscb, i; in find_free_scb_index()
901 for (i = ins->scb_highest_frag_index; i < ins->nscb; ++i) { in find_free_scb_index()
902 if (ins->scbs[i].deleted) { in find_free_scb_index()
913 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in _map_scb()
917 if (ins->nscb == DSP_MAX_SCB_DESC - 1) { in _map_scb()
918 dev_err(chip->card->dev, in _map_scb()
925 memset(&ins->scbs[index], 0, sizeof(ins->scbs[index])); in _map_scb()
926 strcpy(ins->scbs[index].scb_name, name); in _map_scb()
927 ins->scbs[index].address = dest; in _map_scb()
928 ins->scbs[index].index = index; in _map_scb()
929 ins->scbs[index].ref_count = 1; in _map_scb()
931 desc = (ins->scbs + index); in _map_scb()
932 ins->scbs[index].scb_symbol = add_symbol (chip, name, dest, SYMBOL_PARAMETER); in _map_scb()
934 if (index > ins->scb_highest_frag_index) in _map_scb()
935 ins->scb_highest_frag_index = index; in _map_scb()
937 if (index == ins->nscb) in _map_scb()
938 ins->nscb++; in _map_scb()
946 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in _map_task_tree()
949 if (ins->ntask == DSP_MAX_TASK_DESC - 1) { in _map_task_tree()
950 dev_err(chip->card->dev, in _map_task_tree()
956 strcpy(ins->tasks[ins->ntask].task_name, name); in _map_task_tree()
958 strcpy(ins->tasks[ins->ntask].task_name, "(NULL)"); in _map_task_tree()
959 ins->tasks[ins->ntask].address = dest; in _map_task_tree()
960 ins->tasks[ins->ntask].size = size; in _map_task_tree()
963 ins->tasks[ins->ntask].index = ins->ntask; in _map_task_tree()
964 desc = (ins->tasks + ins->ntask); in _map_task_tree()
965 ins->ntask++; in _map_task_tree()
988 desc->data = scb_data; in cs46xx_dsp_create_scb()
991 dev_err(chip->card->dev, "dsp_spos: failed to map SCB\n"); in cs46xx_dsp_create_scb()
1009 desc->data = task_data; in cs46xx_dsp_create_task_tree()
1012 dev_err(chip->card->dev, "dsp_spos: failed to map TASK\n"); in cs46xx_dsp_create_task_tree()
1020 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_scb_and_task_init()
1065 dev_err(chip->card->dev, in cs46xx_dsp_scb_and_task_init()
1067 return -EIO; in cs46xx_dsp_scb_and_task_init()
1072 dev_err(chip->card->dev, in cs46xx_dsp_scb_and_task_init()
1074 return -EIO; in cs46xx_dsp_scb_and_task_init()
1079 dev_err(chip->card->dev, in cs46xx_dsp_scb_and_task_init()
1081 return -EIO; in cs46xx_dsp_scb_and_task_init()
1086 dev_err(chip->card->dev, in cs46xx_dsp_scb_and_task_init()
1088 return -EIO; in cs46xx_dsp_scb_and_task_init()
1093 dev_err(chip->card->dev, in cs46xx_dsp_scb_and_task_init()
1095 return -EIO; in cs46xx_dsp_scb_and_task_init()
1111 null_scb.entry_point = null_algorithm->address; in cs46xx_dsp_scb_and_task_init()
1112 ins->the_null_scb = cs46xx_dsp_create_scb(chip, "nullSCB", (u32 *)&null_scb, NULL_SCB_ADDR); in cs46xx_dsp_scb_and_task_init()
1113 ins->the_null_scb->task_entry = null_algorithm; in cs46xx_dsp_scb_and_task_init()
1114 ins->the_null_scb->sub_list_ptr = ins->the_null_scb; in cs46xx_dsp_scb_and_task_init()
1115 ins->the_null_scb->next_scb_ptr = ins->the_null_scb; in cs46xx_dsp_scb_and_task_init()
1116 ins->the_null_scb->parent_scb_ptr = NULL; in cs46xx_dsp_scb_and_task_init()
1117 cs46xx_dsp_proc_register_scb_desc (chip,ins->the_null_scb); in cs46xx_dsp_scb_and_task_init()
1190 fg_task_tree_hdr.links.entry_point = fg_task_tree_header_code->address; in cs46xx_dsp_scb_and_task_init()
1191 fg_task_tree_hdr.context_blk.stack0 = task_tree_thread->address; in cs46xx_dsp_scb_and_task_init()
1266 bg_task_tree_hdr.links.entry_point = task_tree_header_code->address; in cs46xx_dsp_scb_and_task_init()
1267 bg_task_tree_hdr.context_blk.stack0 = task_tree_thread->address; in cs46xx_dsp_scb_and_task_init()
1286 ins->master_mix_scb = master_mix_scb; in cs46xx_dsp_scb_and_task_init()
1296 ins->codec_in_scb = codec_in_scb; in cs46xx_dsp_scb_and_task_init()
1333 ins->record_mixer_scb = record_mix_scb; in cs46xx_dsp_scb_and_task_init()
1339 if (snd_BUG_ON(chip->nr_ac97_codecs != 1 && chip->nr_ac97_codecs != 2)) in cs46xx_dsp_scb_and_task_init()
1342 if (chip->nr_ac97_codecs == 1) { in cs46xx_dsp_scb_and_task_init()
1373 ins->rear_mix_scb = rear_mix_scb; in cs46xx_dsp_scb_and_task_init()
1376 if (chip->nr_ac97_codecs == 2) { in cs46xx_dsp_scb_and_task_init()
1388 ins->center_lfe_mix_scb = cs46xx_dsp_create_mix_only_scb(chip,"CLFEMixerSCB", in cs46xx_dsp_scb_and_task_init()
1393 if (!ins->center_lfe_mix_scb) goto _fail_end; in cs46xx_dsp_scb_and_task_init()
1399 ins->center_lfe_mix_scb = rear_mix_scb; in cs46xx_dsp_scb_and_task_init()
1414 ins->ref_snoop_scb = magic_snoop_scb; in cs46xx_dsp_scb_and_task_init()
1424 ins->spdif_in_sample_rate, in cs46xx_dsp_scb_and_task_init()
1435 ins->spdif_in_src = src_task_scb; in cs46xx_dsp_scb_and_task_init()
1441 dev_err(chip->card->dev, "dsp_spos: failed to setup SCB's in DSP\n"); in cs46xx_dsp_scb_and_task_init()
1442 return -EINVAL; in cs46xx_dsp_scb_and_task_init()
1448 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_async_init()
1456 dev_err(chip->card->dev, in cs46xx_dsp_async_init()
1458 return -EIO; in cs46xx_dsp_async_init()
1462 dev_err(chip->card->dev, in cs46xx_dsp_async_init()
1464 return -EIO; in cs46xx_dsp_async_init()
1469 dev_err(chip->card->dev, in cs46xx_dsp_async_init()
1471 return -EIO; in cs46xx_dsp_async_init()
1493 /* A */ spdifo_task->address, in cs46xx_dsp_async_init()
1516 /* A */ spdifi_task->address, in cs46xx_dsp_async_init()
1541 /* A */ s16_async_codec_input_task->address, in cs46xx_dsp_async_init()
1584 return -EIO; in cs46xx_dsp_async_init()
1587 return -EIO; in cs46xx_dsp_async_init()
1590 return -EIO; in cs46xx_dsp_async_init()
1592 async_codec_scb_desc->parent_scb_ptr = NULL; in cs46xx_dsp_async_init()
1593 async_codec_scb_desc->next_scb_ptr = spdifi_scb_desc; in cs46xx_dsp_async_init()
1594 async_codec_scb_desc->sub_list_ptr = ins->the_null_scb; in cs46xx_dsp_async_init()
1595 async_codec_scb_desc->task_entry = s16_async_codec_input_task; in cs46xx_dsp_async_init()
1597 spdifi_scb_desc->parent_scb_ptr = async_codec_scb_desc; in cs46xx_dsp_async_init()
1598 spdifi_scb_desc->next_scb_ptr = spdifo_scb_desc; in cs46xx_dsp_async_init()
1599 spdifi_scb_desc->sub_list_ptr = ins->the_null_scb; in cs46xx_dsp_async_init()
1600 spdifi_scb_desc->task_entry = spdifi_task; in cs46xx_dsp_async_init()
1602 spdifo_scb_desc->parent_scb_ptr = spdifi_scb_desc; in cs46xx_dsp_async_init()
1603 spdifo_scb_desc->next_scb_ptr = fg_entry; in cs46xx_dsp_async_init()
1604 spdifo_scb_desc->sub_list_ptr = ins->the_null_scb; in cs46xx_dsp_async_init()
1605 spdifo_scb_desc->task_entry = spdifo_task; in cs46xx_dsp_async_init()
1609 fg_entry->parent_scb_ptr = spdifo_scb_desc; in cs46xx_dsp_async_init()
1625 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_disable_spdif_hw()
1634 /*cs46xx_poke_via_dsp (chip,SP_SPDOUT_CSUV, ins->spdif_csuv_default);*/ in cs46xx_dsp_disable_spdif_hw()
1641 ins->spdif_status_out &= ~DSP_SPDIF_STATUS_HW_ENABLED; in cs46xx_dsp_disable_spdif_hw()
1646 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_enable_spdif_hw()
1648 /* if hw-ctrl already enabled, turn off to reset logic ... */ in cs46xx_dsp_enable_spdif_hw()
1659 cs46xx_poke_via_dsp (chip,SP_SPDOUT_CSUV, ins->spdif_csuv_default); in cs46xx_dsp_enable_spdif_hw()
1662 ins->spdif_status_out |= DSP_SPDIF_STATUS_HW_ENABLED; in cs46xx_dsp_enable_spdif_hw()
1669 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_enable_spdif_in()
1672 chip->active_ctrl(chip, 1); in cs46xx_dsp_enable_spdif_in()
1673 chip->amplifier_ctrl(chip, 1); in cs46xx_dsp_enable_spdif_in()
1675 if (snd_BUG_ON(ins->asynch_rx_scb)) in cs46xx_dsp_enable_spdif_in()
1676 return -EINVAL; in cs46xx_dsp_enable_spdif_in()
1677 if (snd_BUG_ON(!ins->spdif_in_src)) in cs46xx_dsp_enable_spdif_in()
1678 return -EINVAL; in cs46xx_dsp_enable_spdif_in()
1680 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_enable_spdif_in()
1682 if ( ! (ins->spdif_status_out & DSP_SPDIF_STATUS_INPUT_CTRL_ENABLED) ) { in cs46xx_dsp_enable_spdif_in()
1692 ins->spdif_status_out |= DSP_SPDIF_STATUS_INPUT_CTRL_ENABLED; in cs46xx_dsp_enable_spdif_in()
1696 ins->asynch_rx_scb = cs46xx_dsp_create_asynch_fg_rx_scb(chip,"AsynchFGRxSCB", in cs46xx_dsp_enable_spdif_in()
1700 ins->spdif_in_src, in cs46xx_dsp_enable_spdif_in()
1703 spin_lock_irq(&chip->reg_lock); in cs46xx_dsp_enable_spdif_in()
1711 cs46xx_src_link(chip,ins->spdif_in_src); in cs46xx_dsp_enable_spdif_in()
1714 cs46xx_dsp_scb_set_volume (chip,ins->spdif_in_src,0x7fff,0x7fff); in cs46xx_dsp_enable_spdif_in()
1716 spin_unlock_irq(&chip->reg_lock); in cs46xx_dsp_enable_spdif_in()
1720 /* cs46xx_dsp_set_src_sample_rate(chip,ins->spdif_in_src,48000); */ in cs46xx_dsp_enable_spdif_in()
1723 ins->spdif_status_in = 1; in cs46xx_dsp_enable_spdif_in()
1724 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_enable_spdif_in()
1731 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_disable_spdif_in()
1733 if (snd_BUG_ON(!ins->asynch_rx_scb)) in cs46xx_dsp_disable_spdif_in()
1734 return -EINVAL; in cs46xx_dsp_disable_spdif_in()
1735 if (snd_BUG_ON(!ins->spdif_in_src)) in cs46xx_dsp_disable_spdif_in()
1736 return -EINVAL; in cs46xx_dsp_disable_spdif_in()
1738 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_disable_spdif_in()
1741 cs46xx_dsp_remove_scb (chip,ins->asynch_rx_scb); in cs46xx_dsp_disable_spdif_in()
1742 ins->asynch_rx_scb = NULL; in cs46xx_dsp_disable_spdif_in()
1744 cs46xx_src_unlink(chip,ins->spdif_in_src); in cs46xx_dsp_disable_spdif_in()
1747 ins->spdif_status_in = 0; in cs46xx_dsp_disable_spdif_in()
1748 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_disable_spdif_in()
1751 chip->active_ctrl(chip, -1); in cs46xx_dsp_disable_spdif_in()
1752 chip->amplifier_ctrl(chip, -1); in cs46xx_dsp_disable_spdif_in()
1759 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_enable_pcm_capture()
1761 if (snd_BUG_ON(ins->pcm_input)) in cs46xx_dsp_enable_pcm_capture()
1762 return -EINVAL; in cs46xx_dsp_enable_pcm_capture()
1763 if (snd_BUG_ON(!ins->ref_snoop_scb)) in cs46xx_dsp_enable_pcm_capture()
1764 return -EINVAL; in cs46xx_dsp_enable_pcm_capture()
1766 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_enable_pcm_capture()
1767 ins->pcm_input = cs46xx_add_record_source(chip,ins->ref_snoop_scb,PCMSERIALIN_PCM_SCB_ADDR, in cs46xx_dsp_enable_pcm_capture()
1769 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_enable_pcm_capture()
1776 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_disable_pcm_capture()
1778 if (snd_BUG_ON(!ins->pcm_input)) in cs46xx_dsp_disable_pcm_capture()
1779 return -EINVAL; in cs46xx_dsp_disable_pcm_capture()
1781 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_disable_pcm_capture()
1782 cs46xx_dsp_remove_scb (chip,ins->pcm_input); in cs46xx_dsp_disable_pcm_capture()
1783 ins->pcm_input = NULL; in cs46xx_dsp_disable_pcm_capture()
1784 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_disable_pcm_capture()
1791 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_enable_adc_capture()
1793 if (snd_BUG_ON(ins->adc_input)) in cs46xx_dsp_enable_adc_capture()
1794 return -EINVAL; in cs46xx_dsp_enable_adc_capture()
1795 if (snd_BUG_ON(!ins->codec_in_scb)) in cs46xx_dsp_enable_adc_capture()
1796 return -EINVAL; in cs46xx_dsp_enable_adc_capture()
1798 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_enable_adc_capture()
1799 ins->adc_input = cs46xx_add_record_source(chip,ins->codec_in_scb,PCMSERIALIN_SCB_ADDR, in cs46xx_dsp_enable_adc_capture()
1801 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_enable_adc_capture()
1808 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_disable_adc_capture()
1810 if (snd_BUG_ON(!ins->adc_input)) in cs46xx_dsp_disable_adc_capture()
1811 return -EINVAL; in cs46xx_dsp_disable_adc_capture()
1813 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_disable_adc_capture()
1814 cs46xx_dsp_remove_scb (chip,ins->adc_input); in cs46xx_dsp_disable_adc_capture()
1815 ins->adc_input = NULL; in cs46xx_dsp_disable_adc_capture()
1816 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_disable_adc_capture()
1829 return -EINVAL; in cs46xx_poke_via_dsp()
1832 temp = ( address << 16 ) | ( address & 0x0000FFFF); /* offset 0 <-- address2 : address1 */ in cs46xx_poke_via_dsp()
1835 snd_cs46xx_poke(chip,((SPIOWRITE_SCB_ADDR + 1) << 2), data); /* offset 1 <-- data1 */ in cs46xx_poke_via_dsp()
1836 snd_cs46xx_poke(chip,((SPIOWRITE_SCB_ADDR + 2) << 2), data); /* offset 1 <-- data2 */ in cs46xx_poke_via_dsp()
1851 dev_err(chip->card->dev, in cs46xx_poke_via_dsp()
1853 return -EBUSY; in cs46xx_poke_via_dsp()
1861 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_set_dac_volume()
1864 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_set_dac_volume()
1867 scb = ins->master_mix_scb->sub_list_ptr; in cs46xx_dsp_set_dac_volume()
1868 while (scb != ins->the_null_scb) { in cs46xx_dsp_set_dac_volume()
1870 scb = scb->next_scb_ptr; in cs46xx_dsp_set_dac_volume()
1874 scb = ins->rear_mix_scb->sub_list_ptr; in cs46xx_dsp_set_dac_volume()
1875 while (scb != ins->the_null_scb) { in cs46xx_dsp_set_dac_volume()
1877 scb = scb->next_scb_ptr; in cs46xx_dsp_set_dac_volume()
1880 ins->dac_volume_left = left; in cs46xx_dsp_set_dac_volume()
1881 ins->dac_volume_right = right; in cs46xx_dsp_set_dac_volume()
1883 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_set_dac_volume()
1890 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_set_iec958_volume()
1892 mutex_lock(&chip->spos_mutex); in cs46xx_dsp_set_iec958_volume()
1894 if (ins->asynch_rx_scb != NULL) in cs46xx_dsp_set_iec958_volume()
1895 cs46xx_dsp_scb_set_volume (chip,ins->asynch_rx_scb, in cs46xx_dsp_set_iec958_volume()
1898 ins->spdif_input_volume_left = left; in cs46xx_dsp_set_iec958_volume()
1899 ins->spdif_input_volume_right = right; in cs46xx_dsp_set_iec958_volume()
1901 mutex_unlock(&chip->spos_mutex); in cs46xx_dsp_set_iec958_volume()
1909 struct dsp_spos_instance * ins = chip->dsp_spos_instance; in cs46xx_dsp_resume()
1919 for (i = 0; i < ins->nmodules; i++) { in cs46xx_dsp_resume()
1920 struct dsp_module_desc *module = &ins->modules[i]; in cs46xx_dsp_resume()
1938 doffset = seg->offset * 4 + module->load_address * 4 in cs46xx_dsp_resume()
1940 dsize = seg->size * 4; in cs46xx_dsp_resume()
1942 ins->code.data + module->load_address, in cs46xx_dsp_resume()
1948 for (i = 0; i < ins->ntask; i++) { in cs46xx_dsp_resume()
1949 struct dsp_task_descriptor *t = &ins->tasks[i]; in cs46xx_dsp_resume()
1950 _dsp_create_task_tree(chip, t->data, t->address, t->size); in cs46xx_dsp_resume()
1953 for (i = 0; i < ins->nscb; i++) { in cs46xx_dsp_resume()
1954 struct dsp_scb_descriptor *s = &ins->scbs[i]; in cs46xx_dsp_resume()
1955 if (s->deleted) in cs46xx_dsp_resume()
1957 _dsp_create_scb(chip, s->data, s->address); in cs46xx_dsp_resume()
1959 for (i = 0; i < ins->nscb; i++) { in cs46xx_dsp_resume()
1960 struct dsp_scb_descriptor *s = &ins->scbs[i]; in cs46xx_dsp_resume()
1961 if (s->deleted) in cs46xx_dsp_resume()
1963 if (s->updated) in cs46xx_dsp_resume()
1965 if (s->volume_set) in cs46xx_dsp_resume()
1967 s->volume[0], s->volume[1]); in cs46xx_dsp_resume()
1969 if (ins->spdif_status_out & DSP_SPDIF_STATUS_HW_ENABLED) { in cs46xx_dsp_resume()
1971 snd_cs46xx_poke(chip, (ins->ref_snoop_scb->address + 2) << 2, in cs46xx_dsp_resume()
1973 if (ins->spdif_status_out & DSP_SPDIF_STATUS_PLAYBACK_OPEN) in cs46xx_dsp_resume()
1975 ins->spdif_csuv_stream); in cs46xx_dsp_resume()
1977 if (chip->dsp_spos_instance->spdif_status_in) { in cs46xx_dsp_resume()