Skip to content
Commit 1f23a56a authored by Jamie Fox's avatar Jamie Fox Committed by Liviu Dudau
Browse files

drm/malidp: Enable MMU prefetch on Mali-DP650



Mali-DP650 supports warming up the SMMU translations, by sending
requsts to the SMMU before a buffer is read.

There are two modes supported:

- PARTIAL: could be enabled when the buffer is composed of 4K or 64K
  pages, the display hardware will send a configurable number of
  requests before the actual reading.

- FULL: could be enabled when the buffer is composed of 1M or 2M
  pages, the display hardware will send requests before reading for
  all pages composing the buffer.

This patch adds a mechanism for detecting the page size and set the
MMU prefetch mode if possible.

Changes since v1:
 - For imported buffers use the already populated
   drm_gem_cma_object.sgt instead of calling
   driver.gem_prime_get_sg_table, which works just for buffers
   allocated through the gem_cma API.

Signed-off-by: default avatarJamie Fox <jamie.fox@arm.com>
Signed-off-by: default avatarAlexandru Gheorghe <alexandru-cosmin.gheorghe@arm.com>
Acked-by: default avatarLiviu Dudau <liviu.dudau@arm.com>
[rebased and re-ordered functions]
Signed-off-by: default avatarLiviu Dudau <liviu.dudau@arm.com>
parent 187f7f21
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment