Lines Matching refs:portc
376 wavnc_port_info *portc; in waveartist_open() local
383 portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_open()
386 if (portc->open_mode || (devc->open_mode & mode)) { in waveartist_open()
393 portc->open_mode = mode; in waveartist_open()
409 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_close() local
417 devc->open_mode &= ~portc->open_mode; in waveartist_close()
418 portc->open_mode = 0; in waveartist_close()
426 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_output_block() local
437 if (portc->audio_format & (AFMT_S16_LE | AFMT_S16_BE)) in waveartist_output_block()
440 if (portc->channels > 1) in waveartist_output_block()
471 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_start_input() local
480 if (portc->audio_format & (AFMT_S16_LE | AFMT_S16_BE)) /* 16 bit data */ in waveartist_start_input()
483 if (portc->channels > 1) in waveartist_start_input()
518 waveartist_get_speed(wavnc_port_info *portc) in waveartist_get_speed() argument
525 if (portc->speed == 8000) in waveartist_get_speed()
527 else if (portc->speed == 11025) in waveartist_get_speed()
529 else if (portc->speed == 22050) in waveartist_get_speed()
531 else if (portc->speed == 44100) in waveartist_get_speed()
537 speed = portc->speed << 16; in waveartist_get_speed()
546 waveartist_get_bits(wavnc_port_info *portc) in waveartist_get_bits() argument
550 if (portc->audio_format == AFMT_S16_LE) in waveartist_get_bits()
552 else if (portc->audio_format == AFMT_S8) in waveartist_get_bits()
565 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_prepare_for_input() local
571 speed = waveartist_get_speed(portc); in waveartist_prepare_for_input()
572 bits = waveartist_get_bits(portc); in waveartist_prepare_for_input()
578 "record format to %d\n", portc->audio_format); in waveartist_prepare_for_input()
580 if (waveartist_cmd2(devc, WACMD_INPUTCHANNELS, portc->channels)) in waveartist_prepare_for_input()
582 "to %d channels\n", portc->channels); in waveartist_prepare_for_input()
589 "speed to %dHz.\n", portc->speed); in waveartist_prepare_for_input()
597 "format to %d\n", portc->audio_format); in waveartist_prepare_for_input()
620 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_prepare_for_output() local
626 speed = waveartist_get_speed(portc); in waveartist_prepare_for_output()
627 bits = waveartist_get_bits(portc); in waveartist_prepare_for_output()
634 "speed to %dHz.\n", portc->speed); in waveartist_prepare_for_output()
636 if (waveartist_cmd2(devc, WACMD_OUTPUTCHANNELS, portc->channels)) in waveartist_prepare_for_output()
638 "to %d channels\n", portc->channels); in waveartist_prepare_for_output()
646 "format to %d\n", portc->audio_format); in waveartist_prepare_for_output()
664 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_halt() local
667 if (portc->open_mode & OPEN_WRITE) in waveartist_halt()
670 if (portc->open_mode & OPEN_READ) in waveartist_halt()
732 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_trigger() local
748 if (portc->open_mode & OPEN_READ && in waveartist_trigger()
755 if (portc->open_mode & OPEN_WRITE && in waveartist_trigger()
768 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_set_speed() local
771 return portc->speed; in waveartist_set_speed()
778 portc->speed = arg; in waveartist_set_speed()
779 return portc->speed; in waveartist_set_speed()
786 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_set_channels() local
789 return portc->channels; in waveartist_set_channels()
791 portc->channels = arg; in waveartist_set_channels()
798 wavnc_port_info *portc = (wavnc_port_info *) audio_devs[dev]->portc; in waveartist_set_bits() local
801 return portc->audio_format; in waveartist_set_bits()
806 portc->audio_format = arg; in waveartist_set_bits()
1247 wavnc_port_info *portc; in waveartist_init() local
1265 portc = kzalloc(sizeof(wavnc_port_info), GFP_KERNEL); in waveartist_init()
1266 if (portc == NULL) in waveartist_init()
1277 audio_devs[my_dev]->portc = portc; in waveartist_init()
1326 kfree(portc); in waveartist_init()