Skip to contentSkip to conversation

drm/radeon/r200: fix typo in packet checker for tracking textures

PATCH In review [email protected] 2 participants 2 messages Jun 9, 2010

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/radeon/r200: fix typo in packet checker for tracking textures

From: Roland Scheidegger <[email protected]>

using R100_TRACK_COMP_DXT1 instead of R100_TRACK_COMP_DXT35 for dxt3/5 textures leads to size calculations only half as big as they should be.

Signed-off-by [email protected]
---
 drivers/gpu/drm/radeon/r200.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/gpu/drm/radeon/r200.c +1 -1
index 85617c3..aac4b99 100644
@@ -476,7 +476,7 @@ int r200_packet0_check(struct radeon_cs_parser *p,
 		case R200_TXFORMAT_DXT23:
 		case R200_TXFORMAT_DXT45:
 			track->textures[i].cpp = 1;
-			track->textures[i].compress_format = R100_TRACK_COMP_DXT1;
+			track->textures[i].compress_format = R100_TRACK_COMP_DXT35;
 			break;
 		}
 		track->textures[i].cube_info[4].width = 1 << ((idx_value >> 16) & 0xf);
Signature · 1 line
1.5.2.4
Reviewed-by on v1 1/1
#1 lore raw
Quoted 17 lines · On Wed, Jun 9, 2010 at 10:17 AM, <[email protected]> wrote:

From: Roland Scheidegger <[email protected]>

using R100_TRACK_COMP_DXT1 instead of R100_TRACK_COMP_DXT35 for dxt3/5 textures leads to size calculations only half as big as they should be.

Signed-off-by [email protected]

---
 drivers/gpu/drm/radeon/r200.c |    2 +-

 1 files changed, 1 insertions(+), 1 deletions(-)
drivers/gpu/drm/radeon/r200.c +0 -0
index 85617c3..aac4b99 100644
@@ -476,7 +476,7 @@ int r200_packet0_check(struct radeon_cs_parser *p,

               case R200_TXFORMAT_DXT23:
               case R200_TXFORMAT_DXT45:

Quoted 8 lines

                       track->textures[i].cpp = 1;
-                       track->textures[i].compress_format = R100_TRACK_COMP_DXT1;
+                       track->textures[i].compress_format = R100_TRACK_COMP_DXT35; break;
               }
               track->textures[i].cube_info[4].width = 1 << ((idx_value >> 16) & 0xf); --
1.5.2.4

Blatant typo, as discussed on IRC. Very nice catch.

~ C.

Signature · 4 lines
When the facts change, I change my mind. What do you do, sir? ~ Keynes

Corbin Simpson
<[email protected]>