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

Commit ae902683 authored by Lynus Vaz's avatar Lynus Vaz
Browse files

msm: kgsl: Ignore stale size when allocating pages



When allocating pages start out with a zero count for the size and
page count. This ignores any stale data in those fields.

Change-Id: I41fabcd66dbb17ffffefe03012a9cdc808b28214
Signed-off-by: default avatarLynus Vaz <lvaz@codeaurora.org>
parent 573e501b
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -736,6 +736,8 @@ kgsl_sharedmem_page_alloc_user(struct kgsl_memdesc *memdesc,
	 */

	memdesc->pages = kgsl_malloc(len_alloc * sizeof(struct page *));
	memdesc->page_count = 0;
	memdesc->size = 0;

	if (memdesc->pages == NULL) {
		ret = -ENOMEM;