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

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

Merge "msm: Update the permissions while making assign call"

parents 393e99a7 1a23d418
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -1917,7 +1917,7 @@ static void arm_smmu_unprepare_pgtable(void *cookie, void *addr)
	struct arm_smmu_domain *smmu_domain = cookie;
	int ret;
	int dest_vmids = VMID_HLOS;
	int dest_perms = PERM_READ | PERM_WRITE;
	int dest_perms = PERM_READ | PERM_WRITE | PERM_EXEC;
	int source_vmlist[2] = {VMID_HLOS, smmu_domain->secure_vmid};

	if (smmu_domain->secure_vmid == VMID_INVAL)
+4 −1
Original line number Diff line number Diff line
@@ -192,7 +192,7 @@ int pil_assign_mem_to_linux(struct pil_desc *desc, phys_addr_t addr,
	int ret;
	int srcVM[1] = {desc->subsys_vmid};
	int destVM[1] = {VMID_HLOS};
	int destVMperm[1] = {PERM_READ | PERM_WRITE};
	int destVMperm[1] = {PERM_READ | PERM_WRITE | PERM_EXEC};

	ret = hyp_assign_phys(addr, size, srcVM, 1, destVM, destVMperm, 1);
	if (ret)
@@ -228,6 +228,9 @@ int pil_reclaim_mem(struct pil_desc *desc, phys_addr_t addr, size_t size,
	int destVM[1] = {VMid};
	int destVMperm[1] = {PERM_READ | PERM_WRITE};

	if (VMid == VMID_HLOS)
		destVMperm[0] = PERM_READ | PERM_WRITE | PERM_EXEC;

	ret = hyp_assign_phys(addr, size, srcVM, 2, destVM, destVMperm, 1);
	if (ret)
		panic("%s: failed for %pa address of size %zx - subsys VMid %d. Fatal error.\n",