I'm having a problem with getting underruns and overruns when passing audio through the mcasp interfaces on dm8168 using ezsdk 5.05.
The structures for mcasp are as follows:
static u8 ti8168_mcasp0_serializer_direction[] = {
TX_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
RX_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
};
static struct snd_platform_data ti8168_evm_mcasp0_data = {
.tx_dma_offset = 0x46000000,
.rx_dma_offset = 0x46000000,
.op_mode = DAVINCI_MCASP_IIS_MODE,
.num_serializer = ARRAY_SIZE(ti8168_mcasp0_serializer_direction),
.tdm_slots = 2,
.serial_dir = ti8168_mcasp0_serializer_direction,
.asp_chan_q = EVENTQ_2,
.version = MCASP_VERSION_2,
.txnumevt = 1,
.rxnumevt = 1,
};
static u8 ti8168_mcasp1_serializer_direction[] = {
RX_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
};
static struct snd_platform_data ti8168_evm_mcasp1_data = {
.tx_dma_offset = 0x46400000,
.rx_dma_offset = 0x46400000,
.op_mode = DAVINCI_MCASP_IIS_MODE,
.num_serializer = ARRAY_SIZE(ti8168_mcasp1_serializer_direction),
.tdm_slots = 2,
.serial_dir = ti8168_mcasp1_serializer_direction,
.asp_chan_q = EVENTQ_1,
.version = MCASP_VERSION_2,
.txnumevt = 1,
.rxnumevt = 1,
};
static u8 ti8168_mcasp2_serializer_direction[] = {
TX_MODE, RX_MODE, INACTIVE_MODE, INACTIVE_MODE,
INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE, INACTIVE_MODE,
};
static struct snd_platform_data ti8168_evm_mcasp2_data = {
.tx_dma_offset = 0x46800000,
.rx_dma_offset = 0x46800000,
.op_mode = DAVINCI_MCASP_IIS_MODE,
.num_serializer = ARRAY_SIZE(ti8168_mcasp2_serializer_direction),
.tdm_slots = 2,
.serial_dir = ti8168_mcasp2_serializer_direction,
.asp_chan_q = EVENTQ_2,
.version = MCASP_VERSION_2,
.txnumevt = 1,
.rxnumevt = 1,
};
I'm taking audio in from the mcasp1 interface and sending the audio out to the mcasp2 interface. I also do the same thing from the mcasp1 interface and sending the audio out to the mcasp0 interface. I get overruns and underruns with both scenarios. I can hear the audio fine, it just gets interrupted intermittently with overruns and underruns.
I've tried changing which EVENTQ is used on each mcasp, but it makes no difference.
I'm testing with arecord and piping it through aplay right now.
Does anybody have any suggestions?