diff --git a/src/freedreno/common/freedreno_pm4.h b/src/freedreno/common/freedreno_pm4.h index 4320a5c8508..5a46c0a8124 100644 --- a/src/freedreno/common/freedreno_pm4.h +++ b/src/freedreno/common/freedreno_pm4.h @@ -71,6 +71,7 @@ pm4_pkt3_hdr(uint8_t opcode, uint16_t cnt) static inline uint32_t pm4_pkt4_hdr(uint16_t regindx, uint16_t cnt) { + assert(cnt < 0x7f); return CP_TYPE4_PKT | cnt | (pm4_odd_parity_bit(cnt) << 7) | ((regindx & 0x3ffff) << 8) | ((pm4_odd_parity_bit(regindx) << 27));