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

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

Merge "msm: ADSPRPC: Enable session restart with remote heap"

parents cbac2b43 643e912d
Loading
Loading
Loading
Loading
+9 −2
Original line number Diff line number Diff line
@@ -169,6 +169,7 @@ struct fastrpc_channel_ctx {
	int sesscount;
	int ssrcount;
	void *handle;
	int prevssrcount;
	int ramdumpenabled;
	void *remoteheap_ramdump_dev;
};
@@ -1685,8 +1686,13 @@ static int fastrpc_device_open(struct inode *inode, struct file *filp)
		kref_init(&me->channel[cid].kref);
		pr_info("'opened /dev/%s c %d %d'\n", gcinfo[cid].name,
						MAJOR(me->dev_no), cid);
		if (me->channel[cid].ssrcount !=
				 me->channel[cid].prevssrcount) {
			if (fastrpc_mmap_remove_ssr(fl))
				pr_err("ADSPRPC: SSR: Failed to unmap remote heap\n");
			me->channel[cid].prevssrcount =
						me->channel[cid].ssrcount;
		}
	}
	spin_lock(&me->hlock);
	hlist_add_head(&fl->hn, &me->drivers);
@@ -2084,6 +2090,7 @@ static int __init fastrpc_device_init(void)
		if (err)
			goto device_create_bail;
		me->channel[i].ssrcount = 0;
		me->channel[i].prevssrcount = 0;
		me->channel[i].ramdumpenabled = 0;
		me->channel[i].remoteheap_ramdump_dev = 0;
		me->channel[i].nb.notifier_call = fastrpc_restart_notifier_cb;