radv: Fix config reg assert.
authorBas Nieuwenhuizen <bas@basnieuwenhuizen.nl>
Tue, 6 Aug 2019 09:50:37 +0000 (11:50 +0200)
committerDave Airlie <airlied@redhat.com>
Tue, 6 Aug 2019 22:58:23 +0000 (08:58 +1000)
Using the wrong bounds

Fixes: "219d6939df8 radv: add more assertions to make sure packets are correctly emitted"
Reviewed-by: Andres Rodriguez <andresx7@gmail.com>
Reviewed-by: Dave Airlie <airlied@redhat.com>
src/amd/vulkan/radv_cs.h

index d21acba7e8e44f6c402854ecd8ae9df6da33f3f4..16649c55e6ae906874584e36e172e93e0f3b97fb 100644 (file)
@@ -42,7 +42,7 @@ static inline unsigned radeon_check_space(struct radeon_winsys *ws,
 
 static inline void radeon_set_config_reg_seq(struct radeon_cmdbuf *cs, unsigned reg, unsigned num)
 {
-        assert(reg >= SI_CONTEXT_REG_OFFSET && reg < SI_CONFIG_REG_END);
+        assert(reg >= SI_CONFIG_REG_OFFSET && reg < SI_CONFIG_REG_END);
         assert(cs->cdw + 2 + num <= cs->max_dw);
         assert(num);
         radeon_emit(cs, PKT3(PKT3_SET_CONFIG_REG, num, 0));