diff options
author | Dave Airlie <[email protected]> | 2016-01-30 07:59:32 +0200 |
---|---|---|
committer | Alex Deucher <[email protected]> | 2016-02-02 10:08:43 -0500 |
commit | 4b0e4e4af6c6dc8354dcb72182d52c1bc55f12fc (patch) | |
tree | f1e33a4be5b556791e9d26aa44194bf5ba8df091 | |
parent | ad32152eb26043d165eed9406cb9e2f7011f6b10 (diff) |
drm: add helper to check for wc memory support
Reviewed-by: Christian König <[email protected]>
Reviewed-by: Michel Dänzer <[email protected]>
Signed-off-by: Dave Airlie <[email protected]>
Signed-off-by: Oded Gabbay <[email protected]>
Signed-off-by: Alex Deucher <[email protected]>
Cc: [email protected]
-rw-r--r-- | include/drm/drm_cache.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/include/drm/drm_cache.h b/include/drm/drm_cache.h index 7bfb063029d8..461a0558bca4 100644 --- a/include/drm/drm_cache.h +++ b/include/drm/drm_cache.h @@ -35,4 +35,13 @@ void drm_clflush_pages(struct page *pages[], unsigned long num_pages); +static inline bool drm_arch_can_wc_memory(void) +{ +#if defined(CONFIG_PPC) && !defined(CONFIG_NOT_COHERENT_CACHE) + return false; +#else + return true; +#endif +} + #endif |