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

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

Merge "msm: ipa: Fix to release IPA clock during ap suspend"

parents 30c85a17 835ccb37
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -3472,6 +3472,7 @@ static int apps_cons_request_resource(void)

static void ipa_sps_release_resource(struct work_struct *work)
{
	mutex_lock(&ipa_ctx->sps_pm.sps_pm_lock);
	/* check whether still need to decrease client usage */
	if (atomic_read(&ipa_ctx->sps_pm.dec_clients)) {
		if (atomic_read(&ipa_ctx->sps_pm.eot_activity)) {
@@ -3483,6 +3484,7 @@ static void ipa_sps_release_resource(struct work_struct *work)
		}
	}
	atomic_set(&ipa_ctx->sps_pm.eot_activity, 0);
	mutex_unlock(&ipa_ctx->sps_pm.sps_pm_lock);
}

int ipa_create_apps_resource(void)
@@ -3941,6 +3943,9 @@ static int ipa_init(const struct ipa_plat_drv_res *resource_p,
	wakeup_source_init(&ipa_ctx->w_lock, "IPA_WS");
	spin_lock_init(&ipa_ctx->wakelock_ref_cnt.spinlock);

	/* Initialize the SPS PM lock. */
	mutex_init(&ipa_ctx->sps_pm.sps_pm_lock);

	/* Initialize IPA RM (resource manager) */
	result = ipa_rm_initialize();
	if (result) {
+2 −0
Original line number Diff line number Diff line
@@ -1111,10 +1111,12 @@ struct ipa_uc_wdi_ctx {
 * @dec_clients: true if need to decrease active clients count
 * @eot_activity: represent EOT interrupt activity to determine to reset
 *  the inactivity timer
 * @sps_pm_lock: Lock to protect the sps_pm functionality.
 */
struct ipa_sps_pm {
	atomic_t dec_clients;
	atomic_t eot_activity;
	struct mutex sps_pm_lock;
};

/**