Module: Mesa
Branch: gallium-resources
Commit: b33fd3ce3daf2921a895367d0ed3fd9c718a8575
URL:    
http://cgit.freedesktop.org/mesa/mesa/commit/?id=b33fd3ce3daf2921a895367d0ed3fd9c718a8575

Author: Michal Krol <mic...@vmware.com>
Date:   Mon Mar 22 21:03:26 2010 +0100

gallium: Usage parameter of get_transfer/transfer_inline_write is a bitfield.

---

 src/gallium/auxiliary/util/u_resource.c          |    2 +-
 src/gallium/auxiliary/util/u_transfer.c          |    4 ++--
 src/gallium/auxiliary/util/u_transfer.h          |   12 ++++++------
 src/gallium/drivers/cell/ppu/cell_texture.c      |    2 +-
 src/gallium/drivers/i915/i915_resource_buffer.c  |    2 +-
 src/gallium/drivers/identity/id_context.c        |    4 ++--
 src/gallium/drivers/llvmpipe/lp_texture.c        |    2 +-
 src/gallium/drivers/nv50/nv50_transfer.c         |    2 +-
 src/gallium/drivers/nv50/nv50_transfer.h         |    2 +-
 src/gallium/drivers/nvfx/nvfx_transfer.c         |    2 +-
 src/gallium/drivers/nvfx/nvfx_transfer.h         |    2 +-
 src/gallium/drivers/softpipe/sp_texture.c        |    2 +-
 src/gallium/drivers/svga/svga_resource_texture.c |    2 +-
 src/gallium/drivers/trace/tr_context.c           |    4 ++--
 src/gallium/include/pipe/p_context.h             |    4 ++--
 15 files changed, 24 insertions(+), 24 deletions(-)

diff --git a/src/gallium/auxiliary/util/u_resource.c 
b/src/gallium/auxiliary/util/u_resource.c
index e0fa2dc..c37a68b 100644
--- a/src/gallium/auxiliary/util/u_resource.c
+++ b/src/gallium/auxiliary/util/u_resource.c
@@ -75,7 +75,7 @@ void u_transfer_unmap_vtbl( struct pipe_context *pipe,
 void u_transfer_inline_write_vtbl( struct pipe_context *pipe,
                                   struct pipe_resource *resource,
                                   struct pipe_subresource sr,
-                                  enum pipe_transfer_usage usage,
+                                  unsigned usage,
                                   const struct pipe_box *box,
                                   const void *data,
                                   unsigned stride,
diff --git a/src/gallium/auxiliary/util/u_transfer.c 
b/src/gallium/auxiliary/util/u_transfer.c
index 24a7873..02e714f 100644
--- a/src/gallium/auxiliary/util/u_transfer.c
+++ b/src/gallium/auxiliary/util/u_transfer.c
@@ -10,7 +10,7 @@
 void u_default_transfer_inline_write( struct pipe_context *pipe,
                                      struct pipe_resource *resource,
                                      struct pipe_subresource sr,
-                                     enum pipe_transfer_usage usage,
+                                     unsigned usage,
                                      const struct pipe_box *box,
                                      const void *data,
                                      unsigned stride,
@@ -79,7 +79,7 @@ unsigned u_default_is_resource_referenced( struct 
pipe_context *pipe,
 struct pipe_transfer * u_default_get_transfer(struct pipe_context *context,
                                              struct pipe_resource *resource,
                                              struct pipe_subresource sr,
-                                             enum pipe_transfer_usage usage,
+                                             unsigned usage,
                                              const struct pipe_box *box)
 {
    struct pipe_transfer *transfer = CALLOC_STRUCT(pipe_transfer);
diff --git a/src/gallium/auxiliary/util/u_transfer.h 
b/src/gallium/auxiliary/util/u_transfer.h
index 4d67b85..eb07945 100644
--- a/src/gallium/auxiliary/util/u_transfer.h
+++ b/src/gallium/auxiliary/util/u_transfer.h
@@ -16,7 +16,7 @@ boolean u_default_resource_get_handle(struct pipe_screen 
*screen,
 void u_default_transfer_inline_write( struct pipe_context *pipe,
                              struct pipe_resource *resource,
                              struct pipe_subresource sr,
-                             enum pipe_transfer_usage usage,
+                             unsigned usage,
                              const struct pipe_box *box,
                              const void *data,
                              unsigned stride,
@@ -33,7 +33,7 @@ unsigned u_default_is_resource_referenced( struct 
pipe_context *pipe,
 struct pipe_transfer * u_default_get_transfer(struct pipe_context *context,
                                              struct pipe_resource *resource,
                                              struct pipe_subresource sr,
-                                             enum pipe_transfer_usage usage,
+                                             unsigned usage,
                                              const struct pipe_box *box);
 
 void u_default_transfer_unmap( struct pipe_context *pipe,
@@ -63,7 +63,7 @@ struct u_resource_vtbl {
    struct pipe_transfer *(*get_transfer)(struct pipe_context *,
                                         struct pipe_resource *resource,
                                         struct pipe_subresource,
-                                        enum pipe_transfer_usage,
+                                        unsigned usage,
                                         const struct pipe_box *);
 
    void (*transfer_destroy)(struct pipe_context *,
@@ -82,7 +82,7 @@ struct u_resource_vtbl {
    void (*transfer_inline_write)( struct pipe_context *pipe,
                                  struct pipe_resource *resource,
                                  struct pipe_subresource sr,
-                                 enum pipe_transfer_usage usage,
+                                 unsigned usage,
                                  const struct pipe_box *box,
                                  const void *data,
                                  unsigned stride,
@@ -110,7 +110,7 @@ unsigned u_is_resource_referenced_vtbl( struct pipe_context 
*pipe,
 struct pipe_transfer *u_get_transfer_vtbl(struct pipe_context *context,
                                     struct pipe_resource *resource,
                                     struct pipe_subresource sr,
-                                    enum pipe_transfer_usage usage,
+                                    unsigned usage,
                                     const struct pipe_box *box);
 
 void u_transfer_destroy_vtbl(struct pipe_context *pipe,
@@ -129,7 +129,7 @@ void u_transfer_unmap_vtbl( struct pipe_context *rm_ctx,
 void u_transfer_inline_write_vtbl( struct pipe_context *rm_ctx,
                                   struct pipe_resource *resource,
                                   struct pipe_subresource sr,
-                                  enum pipe_transfer_usage usage,
+                                  unsigned usage,
                                   const struct pipe_box *box,
                                   const void *data,
                                   unsigned stride,
diff --git a/src/gallium/drivers/cell/ppu/cell_texture.c 
b/src/gallium/drivers/cell/ppu/cell_texture.c
index 4a241ee..7b9fa38 100644
--- a/src/gallium/drivers/cell/ppu/cell_texture.c
+++ b/src/gallium/drivers/cell/ppu/cell_texture.c
@@ -360,7 +360,7 @@ static struct pipe_transfer *
 cell_get_transfer(struct pipe_context *ctx,
                  struct pipe_resource *resource,
                  struct pipe_subresource sr,
-                 enum pipe_transfer_usage usage,
+                 unsigned usage,
                  const struct pipe_box *box)
 {
    struct cell_resource *ct = cell_resource(resource);
diff --git a/src/gallium/drivers/i915/i915_resource_buffer.c 
b/src/gallium/drivers/i915/i915_resource_buffer.c
index 9dcd50c..2fa2f70 100644
--- a/src/gallium/drivers/i915/i915_resource_buffer.c
+++ b/src/gallium/drivers/i915/i915_resource_buffer.c
@@ -75,7 +75,7 @@ static void
 i915_buffer_transfer_inline_write( struct pipe_context *rm_ctx,
                                   struct pipe_resource *resource,
                                   struct pipe_subresource sr,
-                                  enum pipe_transfer_usage usage,
+                                  unsigned usage,
                                   const struct pipe_box *box,
                                   const void *data,
                                   unsigned stride,
diff --git a/src/gallium/drivers/identity/id_context.c 
b/src/gallium/drivers/identity/id_context.c
index fc5aec0..d15c9b0 100644
--- a/src/gallium/drivers/identity/id_context.c
+++ b/src/gallium/drivers/identity/id_context.c
@@ -738,7 +738,7 @@ static struct pipe_transfer *
 identity_context_get_transfer(struct pipe_context *_context,
                              struct pipe_resource *_resource,
                              struct pipe_subresource sr,
-                             enum pipe_transfer_usage usage,
+                             unsigned usage,
                              const struct pipe_box *box)
 {
    struct identity_context *id_context = identity_context(_context);
@@ -815,7 +815,7 @@ static void
 identity_context_transfer_inline_write( struct pipe_context *_context,
                                        struct pipe_resource *_resource,
                                        struct pipe_subresource sr,
-                                       enum pipe_transfer_usage usage,
+                                       unsigned usage,
                                        const struct pipe_box *box,
                                        const void *data,
                                        unsigned stride,
diff --git a/src/gallium/drivers/llvmpipe/lp_texture.c 
b/src/gallium/drivers/llvmpipe/lp_texture.c
index 71459ab..d08960f 100644
--- a/src/gallium/drivers/llvmpipe/lp_texture.c
+++ b/src/gallium/drivers/llvmpipe/lp_texture.c
@@ -364,7 +364,7 @@ static struct pipe_transfer *
 llvmpipe_get_transfer(struct pipe_context *pipe,
                      struct pipe_resource *resource,
                      struct pipe_subresource sr,
-                     enum pipe_transfer_usage usage,
+                     unsigned usage,
                      const struct pipe_box *box)
 {
    struct llvmpipe_resource *lptex = llvmpipe_resource(resource);
diff --git a/src/gallium/drivers/nv50/nv50_transfer.c 
b/src/gallium/drivers/nv50/nv50_transfer.c
index 293bdf1..314b7b4 100644
--- a/src/gallium/drivers/nv50/nv50_transfer.c
+++ b/src/gallium/drivers/nv50/nv50_transfer.c
@@ -126,7 +126,7 @@ struct pipe_transfer *
 nv50_miptree_transfer_new(struct pipe_context *pcontext,
                          struct pipe_resource *pt,
                          struct pipe_subresource sr,
-                         enum pipe_transfer_usage usage,
+                         unsigned usage,
                          const struct pipe_box *box)
 {
         struct pipe_screen *pscreen = pcontext->screen;
diff --git a/src/gallium/drivers/nv50/nv50_transfer.h 
b/src/gallium/drivers/nv50/nv50_transfer.h
index c6373f1..6635035 100644
--- a/src/gallium/drivers/nv50/nv50_transfer.h
+++ b/src/gallium/drivers/nv50/nv50_transfer.h
@@ -9,7 +9,7 @@ struct pipe_transfer *
 nv50_miptree_transfer_new(struct pipe_context *pcontext,
                          struct pipe_resource *pt,
                          struct pipe_subresource sr,
-                         enum pipe_transfer_usage usage,
+                         unsigned usage,
                          const struct pipe_box *box);
 void
 nv50_miptree_transfer_del(struct pipe_context *pcontext,
diff --git a/src/gallium/drivers/nvfx/nvfx_transfer.c 
b/src/gallium/drivers/nvfx/nvfx_transfer.c
index 09eca00..4bcfe73 100644
--- a/src/gallium/drivers/nvfx/nvfx_transfer.c
+++ b/src/gallium/drivers/nvfx/nvfx_transfer.c
@@ -38,7 +38,7 @@ struct pipe_transfer *
 nvfx_miptree_transfer_new(struct pipe_context *pcontext,
                          struct pipe_resource *pt,
                          struct pipe_subresource sr,
-                         enum pipe_transfer_usage usage,
+                         unsigned usage,
                          const struct pipe_box *box)
 {
         struct pipe_screen *pscreen = pcontext->screen;
diff --git a/src/gallium/drivers/nvfx/nvfx_transfer.h 
b/src/gallium/drivers/nvfx/nvfx_transfer.h
index b2b9201..3e3317b 100644
--- a/src/gallium/drivers/nvfx/nvfx_transfer.h
+++ b/src/gallium/drivers/nvfx/nvfx_transfer.h
@@ -10,7 +10,7 @@ struct pipe_transfer *
 nvfx_miptree_transfer_new(struct pipe_context *pcontext,
                          struct pipe_resource *pt,
                          struct pipe_subresource sr,
-                         enum pipe_transfer_usage usage,
+                         unsigned usage,
                          const struct pipe_box *box);
 void
 nvfx_miptree_transfer_del(struct pipe_context *pcontext,
diff --git a/src/gallium/drivers/softpipe/sp_texture.c 
b/src/gallium/drivers/softpipe/sp_texture.c
index 89197be..e4ca9f2 100644
--- a/src/gallium/drivers/softpipe/sp_texture.c
+++ b/src/gallium/drivers/softpipe/sp_texture.c
@@ -310,7 +310,7 @@ static struct pipe_transfer *
 softpipe_get_transfer(struct pipe_context *pipe,
                      struct pipe_resource *resource,
                      struct pipe_subresource sr,
-                     enum pipe_transfer_usage usage,
+                     unsigned usage,
                      const struct pipe_box *box)
 {
    struct softpipe_resource *sptex = softpipe_resource(resource);
diff --git a/src/gallium/drivers/svga/svga_resource_texture.c 
b/src/gallium/drivers/svga/svga_resource_texture.c
index a288aa5..c2cea30 100644
--- a/src/gallium/drivers/svga/svga_resource_texture.c
+++ b/src/gallium/drivers/svga/svga_resource_texture.c
@@ -341,7 +341,7 @@ static struct pipe_transfer *
 svga_texture_get_transfer(struct pipe_context *pipe,
                          struct pipe_resource *texture,
                          struct pipe_subresource sr,
-                         enum pipe_transfer_usage usage,
+                         unsigned usage,
                          const struct pipe_box *box)
 {
    struct svga_screen *ss = svga_screen(pipe->screen);
diff --git a/src/gallium/drivers/trace/tr_context.c 
b/src/gallium/drivers/trace/tr_context.c
index 09ee5a7..dd0fd8e 100644
--- a/src/gallium/drivers/trace/tr_context.c
+++ b/src/gallium/drivers/trace/tr_context.c
@@ -1305,7 +1305,7 @@ static struct pipe_transfer *
 trace_context_get_transfer(struct pipe_context *_context,
                           struct pipe_resource *_resource,
                           struct pipe_subresource sr,
-                          enum pipe_transfer_usage usage,
+                          unsigned usage,
                           const struct pipe_box *box)
 {
    struct trace_context *tr_context = trace_context(_context);
@@ -1457,7 +1457,7 @@ static void
 trace_context_transfer_inline_write(struct pipe_context *_context,
                                    struct pipe_resource *_resource,
                                    struct pipe_subresource sr,
-                                   enum pipe_transfer_usage usage,
+                                   unsigned usage,
                                    const struct pipe_box *box,
                                    const void *data,
                                    unsigned stride,
diff --git a/src/gallium/include/pipe/p_context.h 
b/src/gallium/include/pipe/p_context.h
index 60fa6b3..2444683 100644
--- a/src/gallium/include/pipe/p_context.h
+++ b/src/gallium/include/pipe/p_context.h
@@ -315,7 +315,7 @@ struct pipe_context {
    struct pipe_transfer *(*get_transfer)(struct pipe_context *,
                                         struct pipe_resource *resource,
                                         struct pipe_subresource,
-                                        enum pipe_transfer_usage,
+                                        unsigned usage,  /* a combination of 
PIPE_TRANSFER_x */
                                         const struct pipe_box *);
 
    void (*transfer_destroy)(struct pipe_context *,
@@ -342,7 +342,7 @@ struct pipe_context {
    void (*transfer_inline_write)( struct pipe_context *,
                                  struct pipe_resource *,
                                  struct pipe_subresource,
-                                 enum pipe_transfer_usage,
+                                 unsigned usage, /* a combination of 
PIPE_TRANSFER_x */
                                  const struct pipe_box *,
                                  const void *data,
                                  unsigned stride,

_______________________________________________
mesa-commit mailing list
mesa-commit@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/mesa-commit

Reply via email to