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

Author: Boyan Ding <boyan.j.d...@gmail.com>
Date:   Wed Nov 25 13:27:07 2015 +0800

radeon: Unify the style of function pointer calls in structs

Signed-off-by: Boyan Ding <boyan.j.d...@gmail.com>
[Emil Velikov: handle the all cases]
Signed-off-by: Emil Velikov <emil.veli...@collabora.com>

---

 src/mesa/drivers/dri/radeon/radeon_common.c        |  8 ++++----
 .../drivers/dri/radeon/radeon_common_context.c     | 24 +++++++++++-----------
 src/mesa/drivers/dri/radeon/radeon_queryobj.c      |  2 +-
 3 files changed, 17 insertions(+), 17 deletions(-)

diff --git a/src/mesa/drivers/dri/radeon/radeon_common.c 
b/src/mesa/drivers/dri/radeon/radeon_common.c
index fde8921..ee4d5f8 100644
--- a/src/mesa/drivers/dri/radeon/radeon_common.c
+++ b/src/mesa/drivers/dri/radeon/radeon_common.c
@@ -426,7 +426,7 @@ static void radeon_print_state_atom(radeonContextPtr 
radeon, struct radeon_state
        if (!radeon_is_debug_enabled(RADEON_STATE, RADEON_VERBOSE) )
                return;
 
-       dwords = (*state->check) (&radeon->glCtx, state);
+       dwords = state->check(&radeon->glCtx, state);
 
        fprintf(stderr, "  emit %s %d/%d\n", state->name, dwords, 
state->cmd_size);
 
@@ -491,13 +491,13 @@ static inline void radeon_emit_atom(radeonContextPtr 
radeon, struct radeon_state
        BATCH_LOCALS(radeon);
        int dwords;
 
-       dwords = (*atom->check) (&radeon->glCtx, atom);
+       dwords = atom->check(&radeon->glCtx, atom);
        if (dwords) {
 
                radeon_print_state_atom(radeon, atom);
 
                if (atom->emit) {
-                       (*atom->emit)(&radeon->glCtx, atom);
+                       atom->emit(&radeon->glCtx, atom);
                } else {
                        BEGIN_BATCH(dwords);
                        OUT_BATCH_TABLE(atom->cmd, dwords);
@@ -591,7 +591,7 @@ flush_front:
                         */
                        radeon->front_buffer_dirty = GL_FALSE;
 
-                       (*screen->dri2.loader->flushFrontBuffer)(drawable, 
drawable->loaderPrivate);
+                       screen->dri2.loader->flushFrontBuffer(drawable, 
drawable->loaderPrivate);
                }
        }
 }
diff --git a/src/mesa/drivers/dri/radeon/radeon_common_context.c 
b/src/mesa/drivers/dri/radeon/radeon_common_context.c
index 4660d98..d981ca2 100644
--- a/src/mesa/drivers/dri/radeon/radeon_common_context.c
+++ b/src/mesa/drivers/dri/radeon/radeon_common_context.c
@@ -418,12 +418,12 @@ radeon_update_renderbuffers(__DRIcontext *context, 
__DRIdrawable *drawable,
                        }
                }
 
-               buffers = (*screen->dri2.loader->getBuffersWithFormat)(drawable,
-                                                               &drawable->w,
-                                                               &drawable->h,
-                                                               attachments, i 
/ 2,
-                                                               &count,
-                                                               
drawable->loaderPrivate);
+               buffers = screen->dri2.loader->getBuffersWithFormat(drawable,
+                                                                   
&drawable->w,
+                                                                   
&drawable->h,
+                                                                   
attachments, i / 2,
+                                                                   &count,
+                                                                   
drawable->loaderPrivate);
        } else if (screen->dri2.loader) {
                i = 0;
                if (draw->color_rb[0])
@@ -437,12 +437,12 @@ radeon_update_renderbuffers(__DRIcontext *context, 
__DRIdrawable *drawable,
                                attachments[i++] = __DRI_BUFFER_STENCIL;
                }
 
-               buffers = (*screen->dri2.loader->getBuffers)(drawable,
-                                                                &drawable->w,
-                                                                &drawable->h,
-                                                                attachments, i,
-                                                                &count,
-                                                                
drawable->loaderPrivate);
+               buffers = screen->dri2.loader->getBuffers(drawable,
+                                                         &drawable->w,
+                                                         &drawable->h,
+                                                         attachments, i,
+                                                         &count,
+                                                         
drawable->loaderPrivate);
        }
 
        if (buffers == NULL)
diff --git a/src/mesa/drivers/dri/radeon/radeon_queryobj.c 
b/src/mesa/drivers/dri/radeon/radeon_queryobj.c
index cd0075a..baf7081 100644
--- a/src/mesa/drivers/dri/radeon/radeon_queryobj.c
+++ b/src/mesa/drivers/dri/radeon/radeon_queryobj.c
@@ -206,7 +206,7 @@ void radeon_emit_queryobj(struct gl_context *ctx, struct 
radeon_state_atom *atom
        BATCH_LOCALS(radeon);
        int dwords;
 
-       dwords = (*atom->check) (ctx, atom);
+       dwords = atom->check(ctx, atom);
 
        BEGIN_BATCH(dwords);
        OUT_BATCH_TABLE(atom->cmd, dwords);

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

Reply via email to