[Sound-open-firmware] [PTACH RFC 5/5] topolog: test: add loopback test topology

Liam Girdwood liam.r.girdwood at linux.intel.com
Mon Jun 4 11:41:09 CEST 2018


On Wed, 2018-05-30 at 17:51 +0800, Xiuli Pan wrote:
> +#
> +# DAI configuration
> +#
> +# SSP port TEST_SSP_PORT is our only pipeline DAI
> +#
> +
> +# playback DAI is SSP TEST_SSP_PORT using 2 periods
> +# Buffers use s24le format, with 48 frame per 1000us on core 0 with priority
> 0
> +DAI_ADD(sof/pipe-dai-loopback.m4,
> +       1, SSP, TEST_SSP_PORT, TEST_DAI_LINK_NAME,
> +       PIPELINE_SOURCE_1, 2, TEST_SSP_FORMAT,
> +       48, 1000, 0, 0)
> +
> +# capture DAI is SSP TEST_SSP_PORT using 2 periods
> +# Buffers use s24le format, with 48 frame per 1000us on core 0 with priority
> 0
> +DAI_ADD(sof/pipe-dai-capture.m4,
> +       2, SSP, TEST_SSP_PORT, TEST_DAI_LINK_NAME,
> +       PIPELINE_SINK_2, 2, TEST_SSP_FORMAT,
> +       48, 1000, 0, 0)
> +

I would add a new macro call DAI_ADD_SSP (defined in ssp.m4) which adds the DAI
loopback kcontrol and then just calls DAI_ADD.

This way you get the kcontrol for SSP loopback for free on every topology.

Liam


More information about the Sound-open-firmware mailing list