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

Commit 1764ed46 authored by Jordan Crouse's avatar Jordan Crouse
Browse files

msm: kgsl: Correct the size of memlist entries in snapshot



The memlist header was correctly updated for 64 bit GPU addressing
but the individual memory entries were still in a 32 bit state of
mind.

Change-Id: Ic0dedbad17a3150739d9644195a653c31d49af17
Signed-off-by: default avatarJordan Crouse <jcrouse@codeaurora.org>
parent 09827569
Loading
Loading
Loading
Loading
+2 −3
Original line number Diff line number Diff line
@@ -468,8 +468,7 @@ static size_t snapshot_capture_mem_list(struct kgsl_device *device,
	if (num_mem == 0)
		goto out;

	if (remain < ((num_mem * 3 * sizeof(unsigned int)) +
			sizeof(*header))) {
	if (remain < ((num_mem * sizeof(struct mem_entry)) + sizeof(*header))) {
		KGSL_CORE_ERR("snapshot: Not enough memory for the mem list");
		goto out;
	}
@@ -483,7 +482,7 @@ static size_t snapshot_capture_mem_list(struct kgsl_device *device,

	idr_for_each(&process->mem_idr, _save_mem_entries, data);

	ret = sizeof(*header) + (num_mem * 3 * sizeof(unsigned int));
	ret = sizeof(*header) + (num_mem * sizeof(struct mem_entry));
out:
	spin_unlock(&process->mem_lock);
	return ret;