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

Commit e9756715 authored by Jordan Crouse's avatar Jordan Crouse
Browse files

msm: kgsl: There is no need to map global PT entries for NOMMU



There is some tortured logic preventing a NULL pointer from being
dereferenced deep in the depths of kgsl_mmu_map if kgsl_mmu_type is
KGSL_MMU_TYPE_NONE but there isn't any reason to even go down the
path in the first place.

Change-Id: Ic0dedbad94c5374e62de3fd7e9c03a404c954014
Signed-off-by: default avatarJordan Crouse <jcrouse@codeaurora.org>
parent 75f44d14
Loading
Loading
Loading
Loading
+1 −5
Original line number Diff line number Diff line
@@ -537,11 +537,7 @@ int kgsl_mmu_start(struct kgsl_device *device)
	struct kgsl_mmu *mmu = &device->mmu;
	int ret = 0;

	if (kgsl_mmu_type == KGSL_MMU_TYPE_NONE) {
		/* Setup gpuaddr of global mappings */
		if (!mmu->setstate_memory.gpuaddr)
			ret = kgsl_map_global_pt_entries(NULL);
	} else
	if (kgsl_mmu_type != KGSL_MMU_TYPE_NONE)
		ret = mmu->mmu_ops->mmu_start(mmu);

	return ret;