From 768843e9e318675e2a0a89a2a4b1bf7b9a876a43 Mon Sep 17 00:00:00 2001 From: Harsha Priya Date: Fri, 1 Sep 2017 21:16:37 -0700 Subject: intel/skylake: nhlt: Add capture configuration format for IV feedback from max98927 This changelist adds the capture format to be set for max98927. The nhlt blob is the same but the format params for capture are different from the render. BUG=b:36724448 TEST=IV feedback data is of good quality Change-Id: I135cf4479e89cd2046ff46027f94c0f71aed650e Signed-off-by: Harsha Priya Reviewed-on: https://review.coreboot.org/21340 Tested-by: build bot (Jenkins) Reviewed-by: Aaron Durbin Reviewed-by: Furquan Shaikh --- src/soc/intel/skylake/nhlt/max98927.c | 21 +++++++++++++++++++++ 1 file changed, 21 insertions(+) diff --git a/src/soc/intel/skylake/nhlt/max98927.c b/src/soc/intel/skylake/nhlt/max98927.c index 8b14df7eef..bbaf15ded9 100644 --- a/src/soc/intel/skylake/nhlt/max98927.c +++ b/src/soc/intel/skylake/nhlt/max98927.c @@ -36,6 +36,18 @@ static const struct nhlt_format_config max98927_render_formats[] = { }, }; +static const struct nhlt_format_config max98927_capture_formats[] = { + /* 48 KHz 16-bits per sample. */ + { + .num_channels = 4, + .sample_freq_khz = 48, + .container_bits_per_sample = 32, + .valid_bits_per_sample = 16, + .speaker_mask = SPEAKER_FRONT_LEFT | SPEAKER_FRONT_RIGHT | + SPEAKER_BACK_LEFT | SPEAKER_BACK_RIGHT, + .settings_file = "max98927-render-2ch-48khz-16b.bin", + }, +}; static const struct nhlt_endp_descriptor max98927_descriptors[] = { { .link = NHLT_LINK_SSP, @@ -46,6 +58,15 @@ static const struct nhlt_endp_descriptor max98927_descriptors[] = { .formats = max98927_render_formats, .num_formats = ARRAY_SIZE(max98927_render_formats), }, + { + .link = NHLT_LINK_SSP, + .device = NHLT_SSP_DEV_I2S, + .direction = NHLT_DIR_CAPTURE, + .vid = NHLT_VID, + .did = NHLT_DID_SSP, + .formats = max98927_capture_formats, + .num_formats = ARRAY_SIZE(max98927_capture_formats), + }, }; int nhlt_soc_add_max98927(struct nhlt *nhlt, int hwlink) -- cgit v1.2.3