svga: single sample surface can be created as non-multisamples surface
[mesa.git] / src / gallium / drivers / svga / svga_screen_cache.h
index 424eb2c5ae1f78aee54ccc784691d592a9e572f0..9365f751f72c634adda37f676c07333ff02ab19d 100644 (file)
@@ -95,12 +95,13 @@ struct svga_host_surface_cache_entry
  * A cache entry can be in the following stages:
  * 1. empty (entry->handle = NULL)
  * 2. holding a buffer in a validate list
- * 3. holding a flushed buffer (not in any validate list) with an active fence
- * 4. holding a flushed buffer with an expired fence
+ * 3. holding a buffer in an invalidate list
+ * 4. holding a flushed buffer (not in any validate list) with an active fence
+ * 5. holding a flushed buffer with an expired fence
  * 
- * An entry progresses from 1 -> 2 -> 3 -> 4. When we need an entry to put a 
+ * An entry progresses from 1 -> 2 -> 3 -> 4 -> 5. When we need an entry to put a 
  * buffer into we preferentially take from 1, or from the least recently used 
- * buffer from 3/4.
+ * buffer from 4/5.
  */
 struct svga_host_surface_cache 
 {
@@ -113,9 +114,12 @@ struct svga_host_surface_cache
     * (3 and 4) */
    struct list_head unused;
    
-   /* Entries with buffers still in validate lists (2) */
+   /* Entries with buffers still in validate list (2) */
    struct list_head validated;
    
+   /* Entries with buffers still in invalidate list (3) */
+   struct list_head invalidated;
+   
    /** Empty entries (1) */
    struct list_head empty;
 
@@ -140,7 +144,7 @@ svga_screen_cache_init(struct svga_screen *svgascreen);
 
 struct svga_winsys_surface *
 svga_screen_surface_create(struct svga_screen *svgascreen,
-                           unsigned bind_flags, unsigned usage,
+                           unsigned bind_flags, enum pipe_resource_usage usage,
                            struct svga_host_surface_cache_key *key);
 
 void