Mesa (master): llvmpipe: llvmpipe_flush_texture -> llvmpipe_flush_resource

Jose Fonseca jrfonseca at kemper.freedesktop.org
Sun Apr 25 14:59:14 UTC 2010


Module: Mesa
Branch: master
Commit: 7951630d0877fc3c293151ad6476bec7288e63c6
URL:    http://cgit.freedesktop.org/mesa/mesa/commit/?id=7951630d0877fc3c293151ad6476bec7288e63c6

Author: José Fonseca <jfonseca at vmware.com>
Date:   Sun Apr 25 15:49:03 2010 +0100

llvmpipe: llvmpipe_flush_texture -> llvmpipe_flush_resource

---

 src/gallium/drivers/llvmpipe/lp_flush.c   |   19 ++++++++-----------
 src/gallium/drivers/llvmpipe/lp_flush.h   |    2 +-
 src/gallium/drivers/llvmpipe/lp_surface.c |    4 ++--
 src/gallium/drivers/llvmpipe/lp_texture.c |    2 +-
 4 files changed, 12 insertions(+), 15 deletions(-)

diff --git a/src/gallium/drivers/llvmpipe/lp_flush.c b/src/gallium/drivers/llvmpipe/lp_flush.c
index 3627dbd..1534913 100644
--- a/src/gallium/drivers/llvmpipe/lp_flush.c
+++ b/src/gallium/drivers/llvmpipe/lp_flush.c
@@ -97,19 +97,16 @@ llvmpipe_flush( struct pipe_context *pipe,
  * Flush context if necessary.
  *
  * TODO: move this logic to an auxiliary library?
- *
- * FIXME: We must implement DISCARD/DONTBLOCK/UNSYNCHRONIZED/etc for
- * textures to avoid blocking.
  */
 boolean
-llvmpipe_flush_texture(struct pipe_context *pipe,
-                       struct pipe_resource *texture,
-                       unsigned face,
-                       unsigned level,
-                       unsigned flush_flags,
-                       boolean read_only,
-                       boolean cpu_access,
-                       boolean do_not_flush)
+llvmpipe_flush_resource(struct pipe_context *pipe,
+                        struct pipe_resource *texture,
+                        unsigned face,
+                        unsigned level,
+                        unsigned flush_flags,
+                        boolean read_only,
+                        boolean cpu_access,
+                        boolean do_not_flush)
 {
    unsigned referenced;
 
diff --git a/src/gallium/drivers/llvmpipe/lp_flush.h b/src/gallium/drivers/llvmpipe/lp_flush.h
index 2375d22..e516cee 100644
--- a/src/gallium/drivers/llvmpipe/lp_flush.h
+++ b/src/gallium/drivers/llvmpipe/lp_flush.h
@@ -37,7 +37,7 @@ void llvmpipe_flush(struct pipe_context *pipe, unsigned flags,
                     struct pipe_fence_handle **fence);
 
 boolean
-llvmpipe_flush_texture(struct pipe_context *pipe,
+llvmpipe_flush_resource(struct pipe_context *pipe,
                        struct pipe_resource *texture,
                        unsigned face,
                        unsigned level,
diff --git a/src/gallium/drivers/llvmpipe/lp_surface.c b/src/gallium/drivers/llvmpipe/lp_surface.c
index ca03440..4934055 100644
--- a/src/gallium/drivers/llvmpipe/lp_surface.c
+++ b/src/gallium/drivers/llvmpipe/lp_surface.c
@@ -59,14 +59,14 @@ lp_surface_copy(struct pipe_context *pipe,
    struct llvmpipe_resource *dst_tex = llvmpipe_resource(dst->texture);
    const enum pipe_format format = src_tex->base.format;
 
-   llvmpipe_flush_texture(pipe,
+   llvmpipe_flush_resource(pipe,
                           dst->texture, dst->face, dst->level,
                           0, /* flush_flags */
                           FALSE, /* read_only */
                           FALSE, /* cpu_access */
                           FALSE); /* do_not_flush */
 
-   llvmpipe_flush_texture(pipe,
+   llvmpipe_flush_resource(pipe,
                           src->texture, src->face, src->level,
                           0, /* flush_flags */
                           TRUE, /* read_only */
diff --git a/src/gallium/drivers/llvmpipe/lp_texture.c b/src/gallium/drivers/llvmpipe/lp_texture.c
index 0c66f4a..e1aed7f 100644
--- a/src/gallium/drivers/llvmpipe/lp_texture.c
+++ b/src/gallium/drivers/llvmpipe/lp_texture.c
@@ -566,7 +566,7 @@ llvmpipe_transfer_map( struct pipe_context *pipe,
     * Transfers, like other pipe operations, must happen in order, so flush the
     * context if necessary.
     */
-   llvmpipe_flush_texture(pipe,
+   llvmpipe_flush_resource(pipe,
                           transfer->resource,
 			  transfer->sr.face,
 			  transfer->sr.level,




More information about the mesa-commit mailing list