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

Commit 5b15694b authored by Shiraz Hashim's avatar Shiraz Hashim Committed by Patrick Daly
Browse files

iommu/io-pgtable-fast: cache clean the last level ptes



While preparing page tables for fastmap, last level ptes
are not being cache cleaned. Fix this.

Change-Id: I97f894b52484d0d223b15090b94c186bba9af734
Signed-off-by: default avatarShiraz Hashim <shashim@codeaurora.org>
parent 9c79f38b
Loading
Loading
Loading
Loading
+5 −0
Original line number Diff line number Diff line
@@ -395,11 +395,16 @@ av8l_fast_prepopulate_pgtables(struct av8l_fast_io_pgtable *data,
	for (i = 0; i < 4; ++i) {
		for (j = 0; j < 512; ++j) {
			av8l_fast_iopte pte, *pudp;
			void *addr;

			page = alloc_page(GFP_KERNEL | __GFP_ZERO);
			if (!page)
				goto err_free_pages;
			pages[pg++] = page;

			addr = page_address(page);
			dmac_clean_range(addr, addr + SZ_4K);

			pte = page_to_phys(page) | AV8L_FAST_PTE_TYPE_TABLE;
			pudp = data->puds[i] + j;
			*pudp = pte;