Ejemplo n.º 1
0
static void stop_tz_world(void)
{
	mutex_lock(&g_mutex_teez);
	register_l2cc_mutex(false);
	tee_shm_pool_destroy(DEV, TZop.Allocator);
	iounmap(shm_vaddr);
	mutex_unlock(&g_mutex_teez);
}
Ejemplo n.º 2
0
static int tz_stop(struct tee *tee)
{
	struct tee_tz *ptee;

	BUG_ON(!tee || !tee->priv);

	ptee = tee->priv;

	dev_dbg(tee->dev, "> dev=%s\n", tee->name);
	if (!CAPABLE(tee)) {
		dev_dbg(tee->dev, "< not capable\n");
		return -EBUSY;
	}

#ifdef CONFIG_OUTER_CACHE
	register_outercache_mutex(ptee, false);
#endif
	tee_shm_pool_destroy(tee->dev, ptee->shm_pool);
	iounmap(ptee->shm_vaddr);
	ptee->started = false;

	dev_dbg(tee->dev, "< ret=0 dev=%s\n", tee->name);
	return 0;
}