diff options
author | Chia-I Wu <[email protected]> | 2015-01-26 16:08:23 +0800 |
---|---|---|
committer | Chia-I Wu <[email protected]> | 2015-02-12 07:56:11 +0800 |
commit | 6f77bd3bdc3bfb004d3e4d0b17b641786e16cde9 (patch) | |
tree | 3997f71e36572a7cd85548357673a527c8abefe9 | |
parent | 3be0504399d7710d9cefcfcfe0b75cffc8cd7ad5 (diff) |
ilo: update 3DSTATE_{DS,HS,GS} for Gen8
-rw-r--r-- | src/gallium/drivers/ilo/ilo_builder_3d_top.h | 32 |
1 files changed, 24 insertions, 8 deletions
diff --git a/src/gallium/drivers/ilo/ilo_builder_3d_top.h b/src/gallium/drivers/ilo/ilo_builder_3d_top.h index ee16ca81e41..6c07e253321 100644 --- a/src/gallium/drivers/ilo/ilo_builder_3d_top.h +++ b/src/gallium/drivers/ilo/ilo_builder_3d_top.h @@ -599,10 +599,10 @@ gen6_disable_3DSTATE_VS(struct ilo_builder *builder) static inline void gen7_disable_3DSTATE_HS(struct ilo_builder *builder) { - const uint8_t cmd_len = 7; + const uint8_t cmd_len = (ilo_dev_gen(builder->dev) >= ILO_GEN(8)) ? 9 : 7; uint32_t *dw; - ILO_DEV_ASSERT(builder->dev, 7, 7.5); + ILO_DEV_ASSERT(builder->dev, 7, 8); ilo_builder_batch_pointer(builder, cmd_len, &dw); @@ -613,6 +613,10 @@ gen7_disable_3DSTATE_HS(struct ilo_builder *builder) dw[4] = 0; dw[5] = 0; dw[6] = 0; + if (ilo_dev_gen(builder->dev) >= ILO_GEN(8)) { + dw[7] = 0; + dw[8] = 0; + } } static inline void @@ -634,10 +638,10 @@ gen7_3DSTATE_TE(struct ilo_builder *builder) static inline void gen7_disable_3DSTATE_DS(struct ilo_builder *builder) { - const uint8_t cmd_len = 6; + const uint8_t cmd_len = (ilo_dev_gen(builder->dev) >= ILO_GEN(8)) ? 9 : 6; uint32_t *dw; - ILO_DEV_ASSERT(builder->dev, 7, 7.5); + ILO_DEV_ASSERT(builder->dev, 7, 8); ilo_builder_batch_pointer(builder, cmd_len, &dw); @@ -647,6 +651,11 @@ gen7_disable_3DSTATE_DS(struct ilo_builder *builder) dw[3] = 0; dw[4] = 0; dw[5] = 0; + if (ilo_dev_gen(builder->dev) >= ILO_GEN(8)) { + dw[6] = 0; + dw[7] = 0; + dw[8] = 0; + } } static inline void @@ -794,10 +803,10 @@ gen7_3DSTATE_GS(struct ilo_builder *builder, static inline void gen7_disable_3DSTATE_GS(struct ilo_builder *builder) { - const uint8_t cmd_len = 7; + const uint8_t cmd_len = (ilo_dev_gen(builder->dev) >= ILO_GEN(8)) ? 10 : 7; uint32_t *dw; - ILO_DEV_ASSERT(builder->dev, 7, 7.5); + ILO_DEV_ASSERT(builder->dev, 7, 8); ilo_builder_batch_pointer(builder, cmd_len, &dw); @@ -806,8 +815,15 @@ gen7_disable_3DSTATE_GS(struct ilo_builder *builder) dw[2] = 0; dw[3] = 0; dw[4] = 0; - dw[5] = GEN7_GS_DW5_STATISTICS; - dw[6] = 0; + + if (ilo_dev_gen(builder->dev) >= ILO_GEN(8)) { + dw[7] = GEN8_GS_DW7_STATISTICS; + dw[8] = 0; + dw[9] = 0; + } else { + dw[5] = GEN7_GS_DW5_STATISTICS; + dw[6] = 0; + } } static inline void |