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

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

Merge "soc: qcom: glink_ssr: Move queue_rx_intent after glink_tx"

parents 50acf772 9bf1c371
Loading
Loading
Loading
Loading
+19 −20
Original line number Diff line number Diff line
/* Copyright (c) 2014-2017, The Linux Foundation. All rights reserved.
/* Copyright (c) 2014-2018, 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
@@ -596,25 +596,6 @@ int notify_for_subsystem(struct subsys_info *ss_info)
		strlcpy(do_cleanup_data->name, ss_info->edge,
				do_cleanup_data->name_len + 1);

		ret = glink_queue_rx_intent(handle, do_cleanup_data,
				sizeof(struct cleanup_done_msg));
		if (ret) {
			GLINK_SSR_ERR(
				"%s %s: %s, ret[%d], resp. remaining[%d]\n",
				"<SSR>", __func__,
				"queue_rx_intent failed", ret,
				atomic_read(&responses_remaining));
			kfree(do_cleanup_data);

			if (!strcmp(ss_leaf_entry->ssr_name, "rpm"))
				panic("%s: Could not queue intent for RPM!\n",
						__func__);
			atomic_dec(&responses_remaining);
			kref_put(&ss_leaf_entry->cb_data->cb_kref,
							cb_data_release);
			continue;
		}

		if (strcmp(ss_leaf_entry->ssr_name, "rpm"))
			ret = glink_tx(handle, do_cleanup_data,
					do_cleanup_data,
@@ -640,6 +621,24 @@ int notify_for_subsystem(struct subsys_info *ss_info)
							cb_data_release);
			continue;
		}
		ret = glink_queue_rx_intent(handle, do_cleanup_data,
				sizeof(struct cleanup_done_msg));
		if (ret) {
			GLINK_SSR_ERR(
				"%s %s: %s, ret[%d], resp. remaining[%d]\n",
				"<SSR>", __func__,
				"queue_rx_intent failed", ret,
				atomic_read(&responses_remaining));
			kfree(do_cleanup_data);

			if (!strcmp(ss_leaf_entry->ssr_name, "rpm"))
				panic("%s: Could not queue intent for RPM!\n",
						__func__);
			atomic_dec(&responses_remaining);
			kref_put(&ss_leaf_entry->cb_data->cb_kref,
							cb_data_release);
			continue;
		}
		sequence_number++;
		kref_put(&ss_leaf_entry->cb_data->cb_kref, cb_data_release);
	}