winsys/radeon: remove superfluous distinction of cases
authorNiels Ole Salscheider <niels_ole@salscheider-online.de>
Wed, 18 Dec 2013 18:11:44 +0000 (19:11 +0100)
committerMarek Olšák <marek.olsak@amd.com>
Sun, 22 Dec 2013 00:41:02 +0000 (01:41 +0100)
Signed-off-by: Niels Ole Salscheider <niels_ole@salscheider-online.de>
Reviewed-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Marek Olšák <marek.olsak@amd.com>
src/gallium/winsys/radeon/drm/radeon_drm_cs.c

index acb12b249857fd5850df84c1a34eec1a62fe173d..d8ad297295862edb880dd2b2f315703089fc74fb 100644 (file)
@@ -482,22 +482,12 @@ static void radeon_drm_cs_flush(struct radeon_winsys_cs *rcs, unsigned flags, ui
            /* pad DMA ring to 8 DWs to meet CP fetch alignment requirements
             * r6xx, requires at least 4 dw alignment to avoid a hw bug.
             */
-            if (flags & RADEON_FLUSH_COMPUTE) {
-                   if (cs->ws->info.chip_class <= SI) {
-                           while (rcs->cdw & 7)
-                                   OUT_CS(&cs->base, 0x80000000); /* type2 nop packet */
-                   } else {
-                           while (rcs->cdw & 7)
-                                   OUT_CS(&cs->base, 0xffff1000); /* type3 nop packet */
-                   }
+           if (cs->ws->info.chip_class <= SI) {
+                   while (rcs->cdw & 7)
+                           OUT_CS(&cs->base, 0x80000000); /* type2 nop packet */
            } else {
-                   if (cs->ws->info.chip_class <= SI) {
-                           while (rcs->cdw & 7)
-                                   OUT_CS(&cs->base, 0x80000000); /* type2 nop packet */
-                   } else {
-                           while (rcs->cdw & 7)
-                                   OUT_CS(&cs->base, 0xffff1000); /* type3 nop packet */
-                   }
+                   while (rcs->cdw & 7)
+                           OUT_CS(&cs->base, 0xffff1000); /* type3 nop packet */
            }
            break;
     case RING_UVD: