summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorBrian Paul <[email protected]>2017-06-16 16:34:43 -0600
committerBrian Paul <[email protected]>2017-06-16 17:03:01 -0600
commitd6cb912d65c9f3790f0b93afa9fb185c739add22 (patch)
treea0178b92bc3a9bcd8cd4e9cc0a1692da394361c0
parent15f4c3ada4e9b9d8b5a5341187b46f77f8c21cd4 (diff)
svga: add a few minor comments
Trivial.
-rw-r--r--src/gallium/drivers/svga/svga_resource_buffer_upload.c5
-rw-r--r--src/gallium/drivers/svga/svga_screen_cache.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/src/gallium/drivers/svga/svga_resource_buffer_upload.c b/src/gallium/drivers/svga/svga_resource_buffer_upload.c
index 9d93b48fd36..1b82dbac0d0 100644
--- a/src/gallium/drivers/svga/svga_resource_buffer_upload.c
+++ b/src/gallium/drivers/svga/svga_resource_buffer_upload.c
@@ -138,7 +138,10 @@ svga_buffer_create_hw_storage(struct svga_screen *ss,
}
-
+/**
+ * Allocate graphics memory for vertex/index/constant/etc buffer (not
+ * textures).
+ */
enum pipe_error
svga_buffer_create_host_surface(struct svga_screen *ss,
struct svga_buffer *sbuf)
diff --git a/src/gallium/drivers/svga/svga_screen_cache.c b/src/gallium/drivers/svga/svga_screen_cache.c
index 82d2ebce976..bf66fc60105 100644
--- a/src/gallium/drivers/svga/svga_screen_cache.c
+++ b/src/gallium/drivers/svga/svga_screen_cache.c
@@ -461,6 +461,7 @@ svga_screen_surface_create(struct svga_screen *svgascreen,
key->cachable);
if (cachable) {
+ /* Try to re-cycle a previously freed, cached surface */
if (key->format == SVGA3D_BUFFER) {
SVGA3dSurfaceFlags hint_flag;
@@ -521,6 +522,7 @@ svga_screen_surface_create(struct svga_screen *svgascreen,
}
if (!handle) {
+ /* Unable to recycle surface, allocate a new one */
unsigned usage = 0;
if (!key->cachable)