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

Commit f9a87bd7 authored by Gabriel Krisman Bertazi's avatar Gabriel Krisman Bertazi Committed by Daniel Vetter
Browse files

drm: Move drm_clflush prototypes to drm_cache header file



Continue to clean up drmP.h by moving the cache flushing functions into
it's own header file.

Compile-tested only

Signed-off-by: default avatarGabriel Krisman Bertazi <krisman@collabora.co.uk>
Reviewed-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
Link: http://patchwork.freedesktop.org/patch/msgid/20170109215649.6860-2-krisman@collabora.co.uk
parent f0e36723
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -49,6 +49,7 @@
#include <drm/drm_legacy.h> /* for struct drm_dma_handle */
#include <drm/drm_gem.h>
#include <drm/drm_auth.h>
#include <drm/drm_cache.h>

#include "i915_params.h"
#include "i915_reg.h"
+1 −0
Original line number Diff line number Diff line
@@ -31,6 +31,7 @@

#include <drm/drmP.h>
#include <drm/drm_gem.h>
#include <drm/drm_cache.h>

#include <uapi/drm/vgem_drm.h>

+0 −5
Original line number Diff line number Diff line
@@ -731,11 +731,6 @@ int drm_noop(struct drm_device *dev, void *data,
int drm_invalid_op(struct drm_device *dev, void *data,
		   struct drm_file *file_priv);

/* Cache management (drm_cache.c) */
void drm_clflush_pages(struct page *pages[], unsigned long num_pages);
void drm_clflush_sg(struct sg_table *st);
void drm_clflush_virt_range(void *addr, unsigned long length);

/*
 * These are exported to drivers so that they can implement fencing using
 * DMA quiscent + idle. DMA quiescent usually requires the hardware lock.
+4 −0
Original line number Diff line number Diff line
@@ -33,7 +33,11 @@
#ifndef _DRM_CACHE_H_
#define _DRM_CACHE_H_

#include <linux/scatterlist.h>

void drm_clflush_pages(struct page *pages[], unsigned long num_pages);
void drm_clflush_sg(struct sg_table *st);
void drm_clflush_virt_range(void *addr, unsigned long length);

static inline bool drm_arch_can_wc_memory(void)
{