summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/msm/msm_drv.h
diff options
context:
space:
mode:
authorDave Airlie <airlied@redhat.com>2016-07-18 15:38:17 +1000
committerDave Airlie <airlied@redhat.com>2016-07-18 15:38:17 +1000
commitd315495d21bf44fd5e422807e8324ff82bfaabab (patch)
treea03cee37dbb6d1bb16006fc18a59b4777fee7ffe /drivers/gpu/drm/msm/msm_drv.h
parent2d635fded22b71381b01e194a59544f2e8d71ef0 (diff)
parent0a677125d0ff726ed3d75ab311cf54674bf512bc (diff)
downloadtalos-obmc-linux-d315495d21bf44fd5e422807e8324ff82bfaabab.tar.gz
talos-obmc-linux-d315495d21bf44fd5e422807e8324ff82bfaabab.zip
Merge branch 'msm-next' of git://people.freedesktop.org/~robclark/linux into drm-next
This time, a bunch of cleanups and refactoring work so that we can get dt bindings upstream. In general, we keep compatibility with existing downstream bindings as much as possible, to make backports to device kernels easier, but now we have cleaner upstream bindings so that we can start landing gpu/display support in upstream dts files. Plus shrinker and madvise support, which has been on my todo list for a long time. And support for arbitrary # of cmd bufs in submit ioctl (I've got libdrm+mesa userspace for this on branches) to enable some of the mesa batch/reorder stuff I'm working on. Userspace decides whether this is supported based on advertised driver version. For the interesting userspace bits, see: https://github.com/freedreno/libdrm/commit/1baf03ac6e77049d9c8be1e3d5164283ce82c9db Plus support for ASoC hdmi audio codec, and few other random other cleanups. * 'msm-next' of git://people.freedesktop.org/~robclark/linux: (52 commits) drm/msm: Delete an unnecessary check before drm_gem_object_unreference() drm/msm: Delete unnecessary checks before drm_gem_object_unreference_unlocked() drm/msm/hdmi: Delete an unnecessary check before the function call "kfree" drm/msm: return -EFAULT instead of bytes remaining drm/msm/hdmi: use PTR_ERR_OR_ZERO() to simplify the code drm/msm: add missing of_node_put after calling of_parse_phandle drm/msm: Replace drm_fb_get_bpp_depth() with drm_format_plane_cpp() drm/msm/dsi: Fix return value check in msm_dsi_host_set_display_mode() drm: msm: Add ASoC generic hdmi audio codec support. drm/msm/rd: add module param to dump all bo's drm/msm/rd: split out snapshot_buf helper drm/msm: bump kernel api version drm/msm: deal with arbitrary # of cmd buffers drm/msm: wire up vmap shrinker drm/msm: change gem->vmap() to get/put drm/msm: shrinker support drm/msm: add put_iova() helper drm/msm: add madvise ioctl drm/msm: use mutex_lock_interruptible for submit ioctl dt-bindings: msm/mdp: Provide details on MDP interface ports ...
Diffstat (limited to 'drivers/gpu/drm/msm/msm_drv.h')
-rw-r--r--drivers/gpu/drm/msm/msm_drv.h24
1 files changed, 22 insertions, 2 deletions
diff --git a/drivers/gpu/drm/msm/msm_drv.h b/drivers/gpu/drm/msm/msm_drv.h
index 5b2963f32291..b4bc7f1ef717 100644
--- a/drivers/gpu/drm/msm/msm_drv.h
+++ b/drivers/gpu/drm/msm/msm_drv.h
@@ -46,6 +46,7 @@
struct msm_kms;
struct msm_gpu;
struct msm_mmu;
+struct msm_mdss;
struct msm_rd_state;
struct msm_perf_state;
struct msm_gem_submit;
@@ -77,11 +78,16 @@ struct msm_vblank_ctrl {
struct msm_drm_private {
+ struct drm_device *dev;
+
struct msm_kms *kms;
/* subordinate devices, if present: */
struct platform_device *gpu_pdev;
+ /* top level MDSS wrapper device (for MDP5 only) */
+ struct msm_mdss *mdss;
+
/* possibly this should be in the kms component, but it is
* shared by both mdp4 and mdp5..
*/
@@ -147,6 +153,9 @@ struct msm_drm_private {
struct drm_mm mm;
} vram;
+ struct notifier_block vmap_notifier;
+ struct shrinker shrinker;
+
struct msm_vblank_ctrl vblank_ctrl;
};
@@ -165,6 +174,9 @@ void msm_gem_submit_free(struct msm_gem_submit *submit);
int msm_ioctl_gem_submit(struct drm_device *dev, void *data,
struct drm_file *file);
+void msm_gem_shrinker_init(struct drm_device *dev);
+void msm_gem_shrinker_cleanup(struct drm_device *dev);
+
int msm_gem_mmap_obj(struct drm_gem_object *obj,
struct vm_area_struct *vma);
int msm_gem_mmap(struct file *filp, struct vm_area_struct *vma);
@@ -189,8 +201,13 @@ struct drm_gem_object *msm_gem_prime_import_sg_table(struct drm_device *dev,
struct dma_buf_attachment *attach, struct sg_table *sg);
int msm_gem_prime_pin(struct drm_gem_object *obj);
void msm_gem_prime_unpin(struct drm_gem_object *obj);
-void *msm_gem_vaddr_locked(struct drm_gem_object *obj);
-void *msm_gem_vaddr(struct drm_gem_object *obj);
+void *msm_gem_get_vaddr_locked(struct drm_gem_object *obj);
+void *msm_gem_get_vaddr(struct drm_gem_object *obj);
+void msm_gem_put_vaddr_locked(struct drm_gem_object *obj);
+void msm_gem_put_vaddr(struct drm_gem_object *obj);
+int msm_gem_madvise(struct drm_gem_object *obj, unsigned madv);
+void msm_gem_purge(struct drm_gem_object *obj);
+void msm_gem_vunmap(struct drm_gem_object *obj);
int msm_gem_sync_object(struct drm_gem_object *obj,
struct msm_fence_context *fctx, bool exclusive);
void msm_gem_move_to_active(struct drm_gem_object *obj,
@@ -257,6 +274,9 @@ static inline int msm_dsi_modeset_init(struct msm_dsi *msm_dsi,
}
#endif
+void __init msm_mdp_register(void);
+void __exit msm_mdp_unregister(void);
+
#ifdef CONFIG_DEBUG_FS
void msm_gem_describe(struct drm_gem_object *obj, struct seq_file *m);
void msm_gem_describe_objects(struct list_head *list, struct seq_file *m);
OpenPOWER on IntegriCloud