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

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

Merge "diag: Send non real time control packet to all peripherals"

parents 88f8dcff 6dc2e287
Loading
Loading
Loading
Loading
+12 −3
Original line number Diff line number Diff line
@@ -349,10 +349,19 @@ void diag_send_diag_mode_update_by_smd(struct diag_smd_info *smd_info,
	int wr_size = -ENOMEM, retry_count = 0, timer;
	struct diag_smd_info *data = NULL;

	/* For now only allow the modem to receive the message */
	if (!smd_info || smd_info->type != SMD_CNTL_TYPE ||
		(smd_info->peripheral != MODEM_DATA))
	if (!smd_info && smd_info->type != SMD_CNTL_TYPE) {
		pr_err("diag: In %s, invalid channel info, smd_info: %p type: %d\n",
					__func__, smd_info,
					((smd_info) ? smd_info->type : -1));
		return;
	}

	if (smd_info->peripheral < MODEM_DATA ||
					smd_info->peripheral > WCNSS_DATA) {
		pr_err("diag: In %s, invalid peripheral %d\n", __func__,
							smd_info->peripheral);
		return;
	}

	data = &driver->smd_data[smd_info->peripheral];
	if (!data)