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

Commit a7687d99 authored by Linux Build Service Account's avatar Linux Build Service Account
Browse files

Merge fa68ddc5 on remote branch

Change-Id: Ia0c005f129c866045453c7e3e9aff7e85a138184
parents a57f3cdf fa68ddc5
Loading
Loading
Loading
Loading
+8 −1
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0-only
/*
 * Copyright (c) 2013-2020, The Linux Foundation. All rights reserved.
 * Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. All rights reserved.
 * Copyright (c) 2022-2024 Qualcomm Innovation Center, Inc. All rights reserved.
 */
#include <linux/init.h>
#include <linux/err.h>
@@ -879,6 +879,13 @@ static int msm_lsm_dereg_model(struct snd_pcm_substream *substream,

	if (p_info->model_id != 0 &&
		p_info->param_type == LSM_DEREG_MULTI_SND_MODEL) {

		if(list_empty(&client->stage_cfg[p_info->stage_idx].sound_models)) {
				 pr_err("%s: sound_models list is empty \n",
                                 __func__);
				 return -EINVAL;
		}

		list_for_each_entry(sm,
				   &client->stage_cfg[p_info->stage_idx].sound_models,
				   list) {
+5 −10
Original line number Diff line number Diff line
@@ -1713,17 +1713,12 @@ static int32_t adm_callback(struct apr_client_data *data, void *priv)
		if (data->opcode == APR_BASIC_RSP_RESULT) {
			pr_debug("%s: APR_BASIC_RSP_RESULT id 0x%x\n",
				__func__, payload[0]);

			if (!((client_id != ADM_CLIENT_ID_SOURCE_TRACKING) &&
			     ((payload[0] == ADM_CMD_SET_PP_PARAMS_V5) ||
			      (payload[0] == ADM_CMD_SET_PP_PARAMS_V6)))) {
			if (data->payload_size <
					(2 * sizeof(uint32_t))) {
				pr_err("%s: Invalid payload size %d\n",
					__func__, data->payload_size);
				return 0;
			}
			}

			if (payload[1] != 0) {
				pr_err("%s: cmd = 0x%x returned error = 0x%x\n",
+13 −1
Original line number Diff line number Diff line
// SPDX-License-Identifier: GPL-2.0-only
/*
 * Copyright (c) 2013-2021, Linux Foundation. All rights reserved.
 * Copyright (c) 2023 Qualcomm Innovation Center, Inc. All rights reserved.
 * Copyright (c) 2023-2024 Qualcomm Innovation Center, Inc. All rights reserved.
 */
#include <linux/fs.h>
#include <linux/mutex.h>
@@ -2130,6 +2130,12 @@ static int q6lsm_mmapcallback(struct apr_client_data *data, void *priv)
		return 0;
	}

	if (data->payload_size < (2 * sizeof(uint32_t))) {
		pr_err("%s: payload has invalid size[%d]\n", __func__,
			data->payload_size);
		return -EINVAL;
	}

	command = payload[0];
	retcode = payload[1];
	sid = (data->token >> 8) & 0x0F;
@@ -2454,6 +2460,12 @@ int q6lsm_set_one_param(struct lsm_client *client,
				       sizeof(struct param_hdr_v2);

		if (param_type == LSM_REG_MULTI_SND_MODEL) {
			if(list_empty(&client->stage_cfg[p_info->stage_idx].sound_models)) {
				 pr_err("%s: sound_models list is empty \n",
                                 __func__);
				 return -EINVAL;
			}

			list_for_each_entry(sm,
					    &client->stage_cfg[p_info->stage_idx].sound_models,
					    list) {