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

Commit 0ed4827e authored by qctecmdr's avatar qctecmdr Committed by Gerrit - the friendly Code Review server
Browse files

Merge "dsp: adm: use default rate for unsupported sample rates"

parents 9d0f53cc af3faf2a
Loading
Loading
Loading
Loading
+8 −3
Original line number Diff line number Diff line
@@ -3044,8 +3044,6 @@ int adm_open(int port_id, int path, int rate, int channel_mode, int topology,
	}

	if ((topology == VPM_TX_SM_ECNS_V2_COPP_TOPOLOGY) ||
	    (topology == VPM_TX_DM_FLUENCE_COPP_TOPOLOGY) ||
	    (topology == VPM_TX_DM_RFECNS_COPP_TOPOLOGY)||
	    (topology == VPM_TX_DM_FLUENCE_EF_COPP_TOPOLOGY)) {
		if ((rate != ADM_CMD_COPP_OPEN_SAMPLE_RATE_8K) &&
		    (rate != ADM_CMD_COPP_OPEN_SAMPLE_RATE_16K) &&
@@ -3053,6 +3051,13 @@ int adm_open(int port_id, int path, int rate, int channel_mode, int topology,
		    (rate != ADM_CMD_COPP_OPEN_SAMPLE_RATE_48K))
			rate = 16000;
	}
	if ((topology == VPM_TX_DM_FLUENCE_COPP_TOPOLOGY) ||
	    (topology == VPM_TX_DM_RFECNS_COPP_TOPOLOGY)) {
		if ((rate != ADM_CMD_COPP_OPEN_SAMPLE_RATE_8K) &&
		    (rate != ADM_CMD_COPP_OPEN_SAMPLE_RATE_16K) &&
		    (rate != ADM_CMD_COPP_OPEN_SAMPLE_RATE_32K))
			rate = 16000;
	}

	if (topology == FFECNS_TOPOLOGY) {
		this_adm.ffecns_port_id = port_id;