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

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

Merge "gpu: ion: fix zero'ing of cached buffers in system heap"

parents e4913f90 a08db806
Loading
Loading
Loading
Loading
+1 −4
Original line number Diff line number Diff line
@@ -218,14 +218,11 @@ void ion_system_heap_free(struct ion_buffer *buffer)
							struct ion_system_heap,
							heap);
	struct sg_table *table = buffer->sg_table;
	bool cached = ion_buffer_cached(buffer);
	struct scatterlist *sg;
	LIST_HEAD(pages);
	int i;

	/* uncached pages come from the page pools, zero them before returning
	   for security purposes (other allocations are zerod at alloc time */
	if (!cached && !(buffer->flags & ION_FLAG_FREED_FROM_SHRINKER))
	if (!(buffer->flags & ION_FLAG_FREED_FROM_SHRINKER))
		ion_heap_buffer_zero(buffer);

	for_each_sg(table->sgl, sg, table->nents, i)