These changes are the raw update to linux-4.4.6-rt14. Kernel sources
[kvmfornfv.git] / kernel / drivers / gpu / drm / vmwgfx / vmwgfx_resource_priv.h
index f3adeed..5994ef6 100644 (file)
@@ -1,6 +1,6 @@
 /**************************************************************************
  *
- * Copyright © 2012 VMware, Inc., Palo Alto, CA., USA
+ * Copyright © 2012-2014 VMware, Inc., Palo Alto, CA., USA
  * All Rights Reserved.
  *
  * Permission is hereby granted, free of charge, to any person obtaining a
 
 #include "vmwgfx_drv.h"
 
+enum vmw_cmdbuf_res_state {
+       VMW_CMDBUF_RES_COMMITTED,
+       VMW_CMDBUF_RES_ADD,
+       VMW_CMDBUF_RES_DEL
+};
+
 /**
  * struct vmw_user_resource_conv - Identify a derived user-exported resource
  * type and provide a function to convert its ttm_base_object pointer to
@@ -55,8 +61,10 @@ struct vmw_user_resource_conv {
  * @bind:              Bind a hardware resource to persistent buffer storage.
  * @unbind:            Unbind a hardware resource from persistent
  *                     buffer storage.
+ * @commit_notify:     If the resource is a command buffer managed resource,
+ *                     callback to notify that a define or remove command
+ *                     has been committed to the device.
  */
-
 struct vmw_res_func {
        enum vmw_res_type res_type;
        bool needs_backup;
@@ -71,6 +79,8 @@ struct vmw_res_func {
        int (*unbind) (struct vmw_resource *res,
                       bool readback,
                       struct ttm_validate_buffer *val_buf);
+       void (*commit_notify)(struct vmw_resource *res,
+                             enum vmw_cmdbuf_res_state state);
 };
 
 int vmw_resource_alloc_id(struct vmw_resource *res);