Mesa (master): i915g: Cleanup caps code a bit.

Stephane Marchesin marcheu at kemper.freedesktop.org
Sat Oct 8 18:03:19 PDT 2011


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

Author: Stéphane Marchesin <marcheu at chromium.org>
Date:   Sat Oct  8 17:12:37 2011 -0700

i915g: Cleanup caps code a bit.

---

 src/gallium/drivers/i915/i915_screen.c |   13 ++++++-------
 1 files changed, 6 insertions(+), 7 deletions(-)

diff --git a/src/gallium/drivers/i915/i915_screen.c b/src/gallium/drivers/i915/i915_screen.c
index f4e533c..cc81835 100644
--- a/src/gallium/drivers/i915/i915_screen.c
+++ b/src/gallium/drivers/i915/i915_screen.c
@@ -184,13 +184,8 @@ i915_get_shader_param(struct pipe_screen *screen, unsigned shader, enum pipe_sha
          return draw_get_shader_param(shader, cap);
       }
    case PIPE_SHADER_FRAGMENT:
-      break;
-   default:
-      return 0;
-   }
-
-   /* XXX: these are just shader model 2.0 values, fix this! */
-   switch(cap) {
+      /* XXX: these are just shader model 2.0 values, fix this! */
+      switch(cap) {
       case PIPE_SHADER_CAP_MAX_INSTRUCTIONS:
          return 96;
       case PIPE_SHADER_CAP_MAX_ALU_INSTRUCTIONS:
@@ -229,7 +224,11 @@ i915_get_shader_param(struct pipe_screen *screen, unsigned shader, enum pipe_sha
       default:
          debug_printf("%s: Unknown cap %u.\n", __FUNCTION__, cap);
          return 0;
+      }
+   default:
+      return 0;
    }
+
 }
 
 static float



More information about the mesa-commit mailing list