summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorJosé Fonseca <[email protected]>2011-11-02 10:32:20 +0000
committerJosé Fonseca <[email protected]>2011-11-02 11:18:35 +0000
commite8f646fa7e9cf6f6793864384128157735aa03b3 (patch)
treeb3b6964b8f6631a6eec8e24314273b1956013c76 /src
parent666c70ce8eb7c8a21536f03be3a68a3c11997e09 (diff)
svga: Update state prototypes to return pipe_error.
Fixes a bunch of prototype mismatch warnings..
Diffstat (limited to 'src')
-rw-r--r--src/gallium/drivers/svga/svga_state_framebuffer.c20
-rw-r--r--src/gallium/drivers/svga/svga_state_need_swtnl.c15
-rw-r--r--src/gallium/drivers/svga/svga_state_tss.c6
-rw-r--r--src/gallium/drivers/svga/svga_state_vs.c5
-rw-r--r--src/gallium/drivers/svga/svga_swtnl_private.h2
-rw-r--r--src/gallium/drivers/svga/svga_swtnl_state.c13
6 files changed, 36 insertions, 25 deletions
diff --git a/src/gallium/drivers/svga/svga_state_framebuffer.c b/src/gallium/drivers/svga/svga_state_framebuffer.c
index 93f8f6a951d..8c0dddf7ae7 100644
--- a/src/gallium/drivers/svga/svga_state_framebuffer.c
+++ b/src/gallium/drivers/svga/svga_state_framebuffer.c
@@ -38,8 +38,9 @@
*/
-static int emit_framebuffer( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+emit_framebuffer( struct svga_context *svga,
+ unsigned dirty )
{
const struct pipe_framebuffer_state *curr = &svga->curr.framebuffer;
struct pipe_framebuffer_state *hw = &svga->state.hw_clear.framebuffer;
@@ -160,8 +161,9 @@ struct svga_tracked_state svga_hw_framebuffer =
/***********************************************************************
*/
-static int emit_viewport( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+emit_viewport( struct svga_context *svga,
+ unsigned dirty )
{
const struct pipe_viewport_state *viewport = &svga->curr.viewport;
struct svga_prescale prescale;
@@ -438,8 +440,9 @@ struct svga_tracked_state svga_hw_viewport =
/***********************************************************************
* Scissor state
*/
-static int emit_scissor_rect( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+emit_scissor_rect( struct svga_context *svga,
+ unsigned dirty )
{
const struct pipe_scissor_state *scissor = &svga->curr.scissor;
SVGA3dRect rect;
@@ -465,8 +468,9 @@ struct svga_tracked_state svga_hw_scissor =
* Userclip state
*/
-static int emit_clip_planes( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+emit_clip_planes( struct svga_context *svga,
+ unsigned dirty )
{
unsigned i;
enum pipe_error ret;
diff --git a/src/gallium/drivers/svga/svga_state_need_swtnl.c b/src/gallium/drivers/svga/svga_state_need_swtnl.c
index 5a37f9fc287..5693c1ac9b2 100644
--- a/src/gallium/drivers/svga/svga_state_need_swtnl.c
+++ b/src/gallium/drivers/svga/svga_state_need_swtnl.c
@@ -71,8 +71,9 @@ svga_translate_vertex_format(enum pipe_format format)
}
-static int update_need_swvfetch( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+update_need_swvfetch( struct svga_context *svga,
+ unsigned dirty )
{
unsigned i;
boolean need_swvfetch = FALSE;
@@ -110,8 +111,9 @@ struct svga_tracked_state svga_update_need_swvfetch =
/***********************************************************************
*/
-static int update_need_pipeline( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+update_need_pipeline( struct svga_context *svga,
+ unsigned dirty )
{
boolean need_pipeline = FALSE;
@@ -165,8 +167,9 @@ struct svga_tracked_state svga_update_need_pipeline =
/***********************************************************************
*/
-static int update_need_swtnl( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+update_need_swtnl( struct svga_context *svga,
+ unsigned dirty )
{
boolean need_swtnl;
diff --git a/src/gallium/drivers/svga/svga_state_tss.c b/src/gallium/drivers/svga/svga_state_tss.c
index 8dc51b70780..3015a446fe2 100644
--- a/src/gallium/drivers/svga/svga_state_tss.c
+++ b/src/gallium/drivers/svga/svga_state_tss.c
@@ -63,7 +63,7 @@ struct bind_queue {
};
-static int
+static enum pipe_error
update_tss_binding(struct svga_context *svga,
unsigned dirty )
{
@@ -284,7 +284,7 @@ svga_queue_tss( struct ts_queue *q,
}
-static int
+static enum pipe_error
update_tss(struct svga_context *svga,
unsigned dirty )
{
@@ -336,7 +336,7 @@ update_tss(struct svga_context *svga,
SVGA_FIFOCommitAll( svga->swc );
}
- return 0;
+ return PIPE_OK;
fail:
/* XXX: need to poison cached hardware state on failure to ensure
diff --git a/src/gallium/drivers/svga/svga_state_vs.c b/src/gallium/drivers/svga/svga_state_vs.c
index 823f328dd37..0b3b5418e3b 100644
--- a/src/gallium/drivers/svga/svga_state_vs.c
+++ b/src/gallium/drivers/svga/svga_state_vs.c
@@ -175,8 +175,9 @@ struct svga_tracked_state svga_hw_vs =
/***********************************************************************
*/
-static int update_zero_stride( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+update_zero_stride( struct svga_context *svga,
+ unsigned dirty )
{
unsigned i;
diff --git a/src/gallium/drivers/svga/svga_swtnl_private.h b/src/gallium/drivers/svga/svga_swtnl_private.h
index 8d080708438..608950d7af6 100644
--- a/src/gallium/drivers/svga/svga_swtnl_private.h
+++ b/src/gallium/drivers/svga/svga_swtnl_private.h
@@ -88,7 +88,7 @@ struct vbuf_render *
svga_vbuf_render_create( struct svga_context *svga );
-int
+enum pipe_error
svga_swtnl_update_vdecl( struct svga_context *svga );
diff --git a/src/gallium/drivers/svga/svga_swtnl_state.c b/src/gallium/drivers/svga/svga_swtnl_state.c
index efda2f605b9..cd1aa637a27 100644
--- a/src/gallium/drivers/svga/svga_swtnl_state.c
+++ b/src/gallium/drivers/svga/svga_swtnl_state.c
@@ -83,8 +83,9 @@ static void set_draw_viewport( struct svga_context *svga )
draw_set_viewport_state(svga->swtnl.draw, &vp);
}
-static int update_swtnl_draw( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+update_swtnl_draw( struct svga_context *svga,
+ unsigned dirty )
{
draw_flush( svga->swtnl.draw );
@@ -139,7 +140,8 @@ struct svga_tracked_state svga_update_swtnl_draw =
};
-int svga_swtnl_update_vdecl( struct svga_context *svga )
+enum pipe_error
+svga_swtnl_update_vdecl( struct svga_context *svga )
{
struct svga_vbuf_render *svga_render = svga_vbuf_render(svga->swtnl.backend);
struct draw_context *draw = svga->swtnl.draw;
@@ -221,8 +223,9 @@ int svga_swtnl_update_vdecl( struct svga_context *svga )
}
-static int update_swtnl_vdecl( struct svga_context *svga,
- unsigned dirty )
+static enum pipe_error
+update_swtnl_vdecl( struct svga_context *svga,
+ unsigned dirty )
{
return svga_swtnl_update_vdecl( svga );
}