[Bug 218132] [snd_hda] audio channels are garbled or crossed over
bugzilla-noreply at freebsd.org
bugzilla-noreply at freebsd.org
Mon Apr 10 21:07:38 UTC 2017
https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=218132
--- Comment #3 from Sean Bruno <sbruno at FreeBSD.org> ---
It appears that we may need to support seperate capture/playback streams,
perhaps.
Linux seems to use a different tag assignment process based on the flag
hda_controller.h:#define AZX_DCAPS_SEPARATE_STREAM_TAG (1 << 30) /* capture
and playback use separate stream tag */
This seems to use two different identifiers in a 2 element array instead of a
single integer.
hda_controller.c::azx_init_streams():
/* initialize SD streams */
int azx_init_streams(struct azx *chip)
{
int i;
int stream_tags[2] = { 0, 0 };
/* initialize each stream (aka device)
* assign the starting bdl address to each stream (device)
* and initialize
*/
for (i = 0; i < chip->num_streams; i++) {
struct azx_dev *azx_dev = kzalloc(sizeof(*azx_dev),
GFP_KERNEL);
int dir, tag;
if (!azx_dev)
return -ENOMEM;
dir = stream_direction(chip, i);
/* stream tag must be unique throughout
* the stream direction group,
* valid values 1...15
* use separate stream tag if the flag
* AZX_DCAPS_SEPARATE_STREAM_TAG is used
*/
if (chip->driver_caps & AZX_DCAPS_SEPARATE_STREAM_TAG)
tag = ++stream_tags[dir];
else
tag = i + 1;
snd_hdac_stream_init(azx_bus(chip), azx_stream(azx_dev),
i, dir, tag);
}
return 0;
}
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the freebsd-multimedia
mailing list