Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit c49f738d authored by Linux Build Service Account's avatar Linux Build Service Account Committed by Gerrit - the friendly Code Review server
Browse files

Merge "ASoC: msm: set AFE_LOOPBACK_TX port id to EC ref port"

parents c2f29cd4 92ca4634
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -1491,6 +1491,7 @@ Optional properties:
- qcom,wsa-max-devs : Maximum number of WSA881x devices present in the target
- qcom,wsa-devs : List of phandles for all possible WSA881x devices supported for the target
- qcom,wsa-aux-dev-prefix : Name prefix with Left/Right configuration for WSA881x device
- qcom,afe-rxtx-lb: AFE RX to TX loopback.

Example:

+3 −2
Original line number Diff line number Diff line
@@ -81,6 +81,7 @@
	qcom,msm-mbhc-hphl-swh = <1>;
	qcom,msm-mbhc-gnd-swh = <1>;
	qcom,tdm-audio-intf;
	qcom,afe-rxtx-lb;
	reg = <0xc051000 0x4>,
		<0xc051004 0x4>,
		<0xc055000 0x4>,
@@ -143,7 +144,7 @@
		<&sb_5_rx>,  <&bt_sco_rx>,
		<&bt_sco_tx>, <&int_fm_rx>, <&int_fm_tx>,
		<&sb_6_rx>, <&dai_pri_tdm_rx_0>, <&dai_pri_tdm_tx_0>,
		<&dai_sec_tdm_rx_0>, <&dai_sec_tdm_tx_0>;
		<&dai_sec_tdm_rx_0>, <&dai_sec_tdm_tx_0>, <&afe_loopback_tx>;
	asoc-cpu-names = "msm-dai-q6-auxpcm.1",
			"msm-dai-q6-mi2s.2",
			"msm-dai-q6-mi2s.3", "msm-dai-q6-mi2s.5",
@@ -161,7 +162,7 @@
			"msm-dai-q6-dev.12292", "msm-dai-q6-dev.12293",
			"msm-dai-q6-dev.16396", "msm-dai-q6-tdm.36864",
			"msm-dai-q6-tdm.36865", "msm-dai-q6-tdm.36880",
			"msm-dai-q6-tdm.36881";
			"msm-dai-q6-tdm.36881", "msm-dai-q6-dev.24577";
	qcom,msm-gpios =
		"quin_i2s",
		"us_eu_gpio",
+6 −1
Original line number Diff line number Diff line
/*
 * Copyright (c) 2015-2016, The Linux Foundation. All rights reserved.
 * Copyright (c) 2015-2017, The Linux Foundation. All rights reserved.
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License version 2 and
@@ -232,6 +232,11 @@
			qcom,msm-dai-q6-dev-id = <240>;
		};

		afe_loopback_tx: qcom,msm-dai-q6-afe-loopback-tx {
			compatible = "qcom,msm-dai-q6-dev";
			qcom,msm-dai-q6-dev-id = <24577>;
		};

		incall_record_rx: qcom,msm-dai-q6-incall-record-rx {
			compatible = "qcom,msm-dai-q6-dev";
			qcom,msm-dai-q6-dev-id = <32771>;
+1 −1
Original line number Diff line number Diff line
@@ -100,7 +100,7 @@ int adm_dolby_dap_send_params(int port_id, int copp_idx, char *params,

int adm_open(int port, int path, int rate, int mode, int topology,
			   int perf_mode, uint16_t bits_per_sample,
			   int app_type, int acdbdev_id);
			   int app_type, int acdbdev_id, int session_type);

int adm_map_rtac_block(struct rtac_cal_block_data *cal_block);

+28 −2
Original line number Diff line number Diff line
@@ -1523,6 +1523,22 @@ static struct snd_soc_dai_link msm8952_tdm_be_dai_link[] = {
	},
};

static struct snd_soc_dai_link msm8952_afe_rxtx_lb_be_dai_link[] = {
	{
		.name = LPASS_BE_AFE_LOOPBACK_TX,
		.stream_name = "AFE Loopback Capture",
		.cpu_dai_name = "msm-dai-q6-dev.24577",
		.platform_name = "msm-pcm-routing",
		.codec_name = "msm-stub-codec.1",
		.codec_dai_name = "msm-stub-tx",
		.no_pcm = 1,
		.dpcm_capture = 1,
		.be_id = MSM_BACKEND_DAI_AFE_LOOPBACK_TX,
		.ignore_pmdown_time = 1,
		.ignore_suspend = 1,
	},
};

struct msm895x_wsa881x_dev_info {
	struct device_node *of_node;
	u32 index;
@@ -1538,7 +1554,8 @@ ARRAY_SIZE(msm8952_tdm_fe_dai) +
ARRAY_SIZE(msm8952_common_be_dai) +
ARRAY_SIZE(msm8952_tomtom_be_dai) +
ARRAY_SIZE(msm8952_quin_dai_link) +
ARRAY_SIZE(msm8952_tdm_be_dai_link)];
ARRAY_SIZE(msm8952_tdm_be_dai_link) +
ARRAY_SIZE(msm8952_afe_rxtx_lb_be_dai_link)];

static struct snd_soc_dai_link msm8952_tasha_dai_links[
ARRAY_SIZE(msm8952_common_fe_dai) +
@@ -1547,7 +1564,8 @@ ARRAY_SIZE(msm8952_tdm_fe_dai) +
ARRAY_SIZE(msm8952_common_be_dai) +
ARRAY_SIZE(msm8952_tasha_be_dai) +
ARRAY_SIZE(msm8952_hdmi_dba_dai_link) +
ARRAY_SIZE(msm8952_tdm_be_dai_link)];
ARRAY_SIZE(msm8952_tdm_be_dai_link) +
ARRAY_SIZE(msm8952_afe_rxtx_lb_be_dai_link)];

int msm8952_init_wsa_dev(struct platform_device *pdev,
			struct snd_soc_card *card)
@@ -1803,6 +1821,14 @@ struct snd_soc_card *populate_snd_card_dailinks(struct device *dev)
			sizeof(msm8952_tdm_be_dai_link));
		len5 += ARRAY_SIZE(msm8952_tdm_be_dai_link);
	}
	if (of_property_read_bool(dev->of_node, "qcom,afe-rxtx-lb")) {
		dev_dbg(dev, "%s(): AFE RX to TX loopback supported\n",
				__func__);
		memcpy(msm8952_dai_links + len5,
		       msm8952_afe_rxtx_lb_be_dai_link,
		       sizeof(msm8952_afe_rxtx_lb_be_dai_link));
		len5 += ARRAY_SIZE(msm8952_afe_rxtx_lb_be_dai_link);
	}
	card->dai_link = msm8952_dai_links;
	card->num_links = len5;
	card->dev = dev;
Loading