summaryrefslogtreecommitdiffstats
path: root/src/gallium/drivers/nouveau
diff options
context:
space:
mode:
Diffstat (limited to 'src/gallium/drivers/nouveau')
-rw-r--r--src/gallium/drivers/nouveau/nv30/nv30_texture.c5
-rw-r--r--src/gallium/drivers/nouveau/nv50/nv50_state.c5
-rw-r--r--src/gallium/drivers/nouveau/nvc0/nvc0_state.c11
3 files changed, 16 insertions, 5 deletions
diff --git a/src/gallium/drivers/nouveau/nv30/nv30_texture.c b/src/gallium/drivers/nouveau/nv30/nv30_texture.c
index 4f4f87e2ce9..e5d3db39f17 100644
--- a/src/gallium/drivers/nouveau/nv30/nv30_texture.c
+++ b/src/gallium/drivers/nouveau/nv30/nv30_texture.c
@@ -188,7 +188,7 @@ nv30_sampler_state_delete(struct pipe_context *pipe, void *hwcso)
static void
nv30_bind_sampler_states(struct pipe_context *pipe,
- unsigned shader, unsigned start_slot,
+ enum pipe_shader_type shader, unsigned start_slot,
unsigned num_samplers, void **samplers)
{
switch (shader) {
@@ -198,6 +198,9 @@ nv30_bind_sampler_states(struct pipe_context *pipe,
case PIPE_SHADER_FRAGMENT:
nv30_fragtex_sampler_states_bind(pipe, num_samplers, samplers);
break;
+ default:
+ assert(!"unexpected shader type");
+ break;
}
}
diff --git a/src/gallium/drivers/nouveau/nv50/nv50_state.c b/src/gallium/drivers/nouveau/nv50/nv50_state.c
index b6741140e50..86674673e92 100644
--- a/src/gallium/drivers/nouveau/nv50/nv50_state.c
+++ b/src/gallium/drivers/nouveau/nv50/nv50_state.c
@@ -633,7 +633,7 @@ nv50_gp_sampler_states_bind(struct pipe_context *pipe, unsigned nr, void **s)
static void
nv50_bind_sampler_states(struct pipe_context *pipe,
- unsigned shader, unsigned start,
+ enum pipe_shader_type shader, unsigned start,
unsigned num_samplers, void **samplers)
{
assert(start == 0);
@@ -647,6 +647,9 @@ nv50_bind_sampler_states(struct pipe_context *pipe,
case PIPE_SHADER_FRAGMENT:
nv50_fp_sampler_states_bind(pipe, num_samplers, samplers);
break;
+ default:
+ assert(!"unexpected shader type");
+ break;
}
}
diff --git a/src/gallium/drivers/nouveau/nvc0/nvc0_state.c b/src/gallium/drivers/nouveau/nvc0/nvc0_state.c
index b9ac9f49ad9..0d971f3f2e4 100644
--- a/src/gallium/drivers/nouveau/nvc0/nvc0_state.c
+++ b/src/gallium/drivers/nouveau/nvc0/nvc0_state.c
@@ -426,7 +426,8 @@ nvc0_sampler_state_delete(struct pipe_context *pipe, void *hwcso)
}
static inline void
-nvc0_stage_sampler_states_bind(struct nvc0_context *nvc0, int s,
+nvc0_stage_sampler_states_bind(struct nvc0_context *nvc0,
+ enum pipe_shader_type s,
unsigned nr, void **hwcso)
{
unsigned i;
@@ -456,7 +457,7 @@ nvc0_stage_sampler_states_bind(struct nvc0_context *nvc0, int s,
static void
nvc0_stage_sampler_states_bind_range(struct nvc0_context *nvc0,
- const unsigned s,
+ const enum pipe_shader_type s,
unsigned start, unsigned nr, void **cso)
{
const unsigned end = start + nr;
@@ -497,7 +498,8 @@ nvc0_stage_sampler_states_bind_range(struct nvc0_context *nvc0,
}
static void
-nvc0_bind_sampler_states(struct pipe_context *pipe, unsigned shader,
+nvc0_bind_sampler_states(struct pipe_context *pipe,
+ enum pipe_shader_type shader,
unsigned start, unsigned nr, void **s)
{
switch (shader) {
@@ -526,6 +528,9 @@ nvc0_bind_sampler_states(struct pipe_context *pipe, unsigned shader,
start, nr, s);
nvc0_context(pipe)->dirty_cp |= NVC0_NEW_CP_SAMPLERS;
break;
+ default:
+ assert(!"unexpected shader type");
+ break;
}
}