2 * Mesa 3-D graphics library
4 * Copyright (C) 2012-2015 LunarG, Inc.
6 * Permission is hereby granted, free of charge, to any person obtaining a
7 * copy of this software and associated documentation files (the "Software"),
8 * to deal in the Software without restriction, including without limitation
9 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
10 * and/or sell copies of the Software, and to permit persons to whom the
11 * Software is furnished to do so, subject to the following conditions:
13 * The above copyright notice and this permission notice shall be included
14 * in all copies or substantial portions of the Software.
16 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
17 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
18 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
19 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
20 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
21 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
22 * DEALINGS IN THE SOFTWARE.
25 * Chia-I Wu <olv@lunarg.com>
28 #include "intel_winsys.h"
30 #include "ilo_debug.h"
31 #include "ilo_image.h"
32 #include "ilo_state_zs.h"
35 zs_set_gen6_null_3DSTATE_DEPTH_BUFFER(struct ilo_state_zs
*zs
,
36 const struct ilo_dev
*dev
)
38 const enum gen_depth_format format
= GEN6_ZFORMAT_D32_FLOAT
;
41 ILO_DEV_ASSERT(dev
, 6, 8);
43 if (ilo_dev_gen(dev
) >= ILO_GEN(7)) {
44 dw1
= GEN6_SURFTYPE_NULL
<< GEN7_DEPTH_DW1_TYPE__SHIFT
|
45 format
<< GEN7_DEPTH_DW1_FORMAT__SHIFT
;
47 dw1
= GEN6_SURFTYPE_NULL
<< GEN6_DEPTH_DW1_TYPE__SHIFT
|
48 GEN6_TILING_Y
<< GEN6_DEPTH_DW1_TILING__SHIFT
|
49 format
<< GEN6_DEPTH_DW1_FORMAT__SHIFT
;
52 STATIC_ASSERT(ARRAY_SIZE(zs
->depth
) >= 5);
59 zs
->depth_format
= format
;
64 static enum gen_surface_type
65 get_gen6_surface_type(const struct ilo_dev
*dev
, const struct ilo_image
*img
)
67 ILO_DEV_ASSERT(dev
, 6, 8);
69 switch (img
->target
) {
71 case PIPE_TEXTURE_1D_ARRAY
:
72 return GEN6_SURFTYPE_1D
;
74 case PIPE_TEXTURE_CUBE
:
75 case PIPE_TEXTURE_RECT
:
76 case PIPE_TEXTURE_2D_ARRAY
:
77 case PIPE_TEXTURE_CUBE_ARRAY
:
78 return GEN6_SURFTYPE_2D
;
80 return GEN6_SURFTYPE_3D
;
82 assert(!"unknown texture target");
83 return GEN6_SURFTYPE_NULL
;
87 static enum gen_depth_format
88 get_gen6_depth_format(const struct ilo_dev
*dev
, const struct ilo_image
*img
)
90 ILO_DEV_ASSERT(dev
, 6, 8);
92 if (ilo_dev_gen(dev
) >= ILO_GEN(7)) {
93 switch (img
->format
) {
94 case PIPE_FORMAT_Z32_FLOAT
:
95 return GEN6_ZFORMAT_D32_FLOAT
;
96 case PIPE_FORMAT_Z24X8_UNORM
:
97 return GEN6_ZFORMAT_D24_UNORM_X8_UINT
;
98 case PIPE_FORMAT_Z16_UNORM
:
99 return GEN6_ZFORMAT_D16_UNORM
;
101 assert(!"unknown depth format");
102 return GEN6_ZFORMAT_D32_FLOAT
;
105 switch (img
->format
) {
106 case PIPE_FORMAT_Z32_FLOAT_S8X24_UINT
:
107 return GEN6_ZFORMAT_D32_FLOAT_S8X24_UINT
;
108 case PIPE_FORMAT_Z32_FLOAT
:
109 return GEN6_ZFORMAT_D32_FLOAT
;
110 case PIPE_FORMAT_Z24_UNORM_S8_UINT
:
111 return GEN6_ZFORMAT_D24_UNORM_S8_UINT
;
112 case PIPE_FORMAT_Z24X8_UNORM
:
113 return GEN6_ZFORMAT_D24_UNORM_X8_UINT
;
114 case PIPE_FORMAT_Z16_UNORM
:
115 return GEN6_ZFORMAT_D16_UNORM
;
117 assert(!"unknown depth format");
118 return GEN6_ZFORMAT_D32_FLOAT
;
124 zs_validate_gen6(const struct ilo_dev
*dev
,
125 const struct ilo_state_zs_info
*info
)
127 const struct ilo_image
*img
= (info
->z_img
) ? info
->z_img
: info
->s_img
;
129 ILO_DEV_ASSERT(dev
, 6, 8);
132 * From the Ivy Bridge PRM, volume 2 part 1, page 315:
134 * The stencil buffer has a format of S8_UINT, and shares Surface
135 * Type, Height, Width, and Depth, Minimum Array Element, Render
136 * Target View Extent, Depth Coordinate Offset X/Y, LOD, and Depth
137 * Buffer Object Control State fields of the depth buffer.
139 if (info
->z_img
== info
->s_img
) {
140 assert(info
->z_img
->target
== info
->s_img
->target
&&
141 info
->z_img
->width0
== info
->s_img
->width0
&&
142 info
->z_img
->height0
== info
->s_img
->height0
&&
143 info
->z_img
->depth0
== info
->s_img
->depth0
);
146 assert(info
->level
< img
->level_count
);
147 assert(img
->bo_stride
);
149 if (info
->hiz_enable
) {
150 assert(info
->z_img
&&
151 ilo_image_can_enable_aux(info
->z_img
, info
->level
));
154 if (info
->is_cube_map
) {
155 assert(get_gen6_surface_type(dev
, img
) == GEN6_SURFTYPE_2D
);
158 * From the Sandy Bridge PRM, volume 2 part 1, page 323:
160 * "For cube maps, Width must be set equal to Height."
162 assert(img
->width0
== img
->height0
);
166 assert(info
->z_img
->tiling
== GEN6_TILING_Y
);
168 assert(info
->s_img
->tiling
== GEN8_TILING_W
);
174 get_gen6_max_extent(const struct ilo_dev
*dev
,
175 const struct ilo_image
*img
,
176 uint16_t *max_w
, uint16_t *max_h
)
178 const uint16_t max_size
= (ilo_dev_gen(dev
) >= ILO_GEN(7)) ? 16384 : 8192;
180 ILO_DEV_ASSERT(dev
, 6, 8);
182 switch (get_gen6_surface_type(dev
, img
)) {
183 case GEN6_SURFTYPE_1D
:
187 case GEN6_SURFTYPE_2D
:
191 case GEN6_SURFTYPE_3D
:
196 assert(!"invalid surface type");
204 get_gen6_hiz_alignments(const struct ilo_dev
*dev
,
205 const struct ilo_image
*img
,
206 uint16_t *align_w
, uint16_t *align_h
)
208 ILO_DEV_ASSERT(dev
, 6, 8);
211 * From the Sandy Bridge PRM, volume 2 part 1, page 313:
213 * "A rectangle primitive representing the clear area is delivered. The
214 * primitive must adhere to the following restrictions on size:
216 * - If Number of Multisamples is NUMSAMPLES_1, the rectangle must be
217 * aligned to an 8x4 pixel block relative to the upper left corner
218 * of the depth buffer, and contain an integer number of these pixel
219 * blocks, and all 8x4 pixels must be lit.
220 * - If Number of Multisamples is NUMSAMPLES_4, the rectangle must be
221 * aligned to a 4x2 pixel block (8x4 sample block) relative to the
222 * upper left corner of the depth buffer, and contain an integer
223 * number of these pixel blocks, and all samples of the 4x2 pixels
225 * - If Number of Multisamples is NUMSAMPLES_8, the rectangle must be
226 * aligned to a 2x2 pixel block (8x4 sample block) relative to the
227 * upper left corner of the depth buffer, and contain an integer
228 * number of these pixel blocks, and all samples of the 2x2 pixels
231 * Experiments on Gen7.5 show that HiZ resolve also requires the rectangle
232 * to be aligned to 8x4 sample blocks. But to be on the safe side, we
233 * always require a level to be aligned when HiZ is enabled.
235 switch (img
->sample_count
) {
257 assert(!"unknown sample count");
265 zs_get_gen6_depth_extent(const struct ilo_dev
*dev
,
266 const struct ilo_state_zs_info
*info
,
267 uint16_t *width
, uint16_t *height
)
269 const struct ilo_image
*img
= (info
->z_img
) ? info
->z_img
: info
->s_img
;
270 uint16_t w
, h
, max_w
, max_h
;
272 ILO_DEV_ASSERT(dev
, 6, 8);
277 if (info
->hiz_enable
) {
278 uint16_t align_w
, align_h
;
280 get_gen6_hiz_alignments(dev
, info
->z_img
, &align_w
, &align_h
);
283 * We want to force 8x4 alignment, but we can do so only for level 0 and
284 * only when it is padded. ilo_image should know all these.
287 assert(w
% align_w
== 0 && h
% align_h
== 0);
289 w
= align(w
, align_w
);
290 h
= align(h
, align_h
);
293 get_gen6_max_extent(dev
, img
, &max_w
, &max_h
);
294 assert(w
&& h
&& w
<= max_w
&& h
<= max_h
);
303 zs_get_gen6_depth_slices(const struct ilo_dev
*dev
,
304 const struct ilo_state_zs_info
*info
,
305 uint16_t *depth
, uint16_t *min_array_elem
,
306 uint16_t *rt_view_extent
)
308 const struct ilo_image
*img
= (info
->z_img
) ? info
->z_img
: info
->s_img
;
309 uint16_t max_slice
, d
;
311 ILO_DEV_ASSERT(dev
, 6, 8);
314 * From the Sandy Bridge PRM, volume 2 part 1, page 325:
316 * "This field (Depth) specifies the total number of levels for a
317 * volume texture or the number of array elements allowed to be
318 * accessed starting at the Minimum Array Element for arrayed
319 * surfaces. If the volume texture is MIP-mapped, this field specifies
320 * the depth of the base MIP level."
322 switch (get_gen6_surface_type(dev
, img
)) {
323 case GEN6_SURFTYPE_1D
:
324 case GEN6_SURFTYPE_2D
:
325 max_slice
= (ilo_dev_gen(dev
) >= ILO_GEN(7)) ? 2048 : 512;
327 assert(img
->array_size
<= max_slice
);
328 max_slice
= img
->array_size
;
330 d
= info
->slice_count
;
331 if (info
->is_cube_map
) {
333 * Minumum Array Element and Depth must be 0; Render Target View
336 if (info
->slice_base
|| d
!= 6) {
337 ilo_warn("no cube array dpeth buffer\n");
344 case GEN6_SURFTYPE_3D
:
347 assert(img
->depth0
<= max_slice
);
348 max_slice
= u_minify(img
->depth0
, info
->level
);
353 assert(!"invalid surface type");
358 if (!info
->slice_count
||
359 info
->slice_base
+ info
->slice_count
> max_slice
) {
360 ilo_warn("invalid slice range\n");
368 * From the Sandy Bridge PRM, volume 2 part 1, page 325:
370 * "For 1D and 2D Surfaces:
371 * This field (Minimum Array Element) indicates the minimum array
372 * element that can be accessed as part of this surface. The delivered
373 * array index is added to this field before being used to address the
377 * This field indicates the minimum `R' coordinate on the LOD
378 * currently being rendered to. This field is added to the delivered
379 * array index before it is used to address the surface.
381 * For Other Surfaces:
382 * This field is ignored."
384 *min_array_elem
= info
->slice_base
;
387 * From the Sandy Bridge PRM, volume 2 part 1, page 326:
390 * This field (Render Target View Extent) indicates the extent of the
391 * accessible `R' coordinates minus 1 on the LOD currently being
394 * For 1D and 2D Surfaces:
395 * This field must be set to the same value as the Depth field.
397 * For Other Surfaces:
398 * This field is ignored."
400 *rt_view_extent
= info
->slice_count
- 1;
406 zs_set_gen6_3DSTATE_DEPTH_BUFFER(struct ilo_state_zs
*zs
,
407 const struct ilo_dev
*dev
,
408 const struct ilo_state_zs_info
*info
)
410 uint16_t width
, height
, depth
, array_base
, view_extent
;
411 enum gen_surface_type type
;
412 enum gen_depth_format format
;
413 uint32_t dw1
, dw2
, dw3
, dw4
;
415 ILO_DEV_ASSERT(dev
, 6, 6);
417 if (!zs_validate_gen6(dev
, info
) ||
418 !zs_get_gen6_depth_extent(dev
, info
, &width
, &height
) ||
419 !zs_get_gen6_depth_slices(dev
, info
, &depth
, &array_base
,
423 type
= (info
->is_cube_map
) ? GEN6_SURFTYPE_CUBE
:
424 (info
->z_img
) ? get_gen6_surface_type(dev
, info
->z_img
) :
425 get_gen6_surface_type(dev
, info
->s_img
);
427 format
= (info
->z_img
) ? get_gen6_depth_format(dev
, info
->z_img
) :
428 GEN6_ZFORMAT_D32_FLOAT
;
431 * From the Ironlake PRM, volume 2 part 1, page 330:
433 * "If this field (Separate Stencil Buffer Enable) is disabled, the
434 * Surface Format of the depth buffer cannot be D24_UNORM_X8_UINT."
436 * From the Sandy Bridge PRM, volume 2 part 1, page 321:
438 * "[DevSNB]: This field (Separate Stencil Buffer Enable) must be set
439 * to the same value (enabled or disabled) as Hierarchical Depth
442 if (!info
->hiz_enable
&& format
== GEN6_ZFORMAT_D24_UNORM_X8_UINT
)
443 format
= GEN6_ZFORMAT_D24_UNORM_S8_UINT
;
445 /* info->z_readonly and info->s_readonly are ignored on Gen6 */
446 dw1
= type
<< GEN6_DEPTH_DW1_TYPE__SHIFT
|
447 GEN6_TILING_Y
<< GEN6_DEPTH_DW1_TILING__SHIFT
|
448 format
<< GEN6_DEPTH_DW1_FORMAT__SHIFT
;
451 dw1
|= (info
->z_img
->bo_stride
- 1) << GEN6_DEPTH_DW1_PITCH__SHIFT
;
453 if (info
->hiz_enable
|| !info
->z_img
) {
454 dw1
|= GEN6_DEPTH_DW1_HIZ_ENABLE
|
455 GEN6_DEPTH_DW1_SEPARATE_STENCIL
;
459 dw3
= height
<< GEN6_DEPTH_DW3_HEIGHT__SHIFT
|
460 width
<< GEN6_DEPTH_DW3_WIDTH__SHIFT
|
461 info
->level
<< GEN6_DEPTH_DW3_LOD__SHIFT
|
462 GEN6_DEPTH_DW3_MIPLAYOUT_BELOW
;
463 dw4
= depth
<< GEN6_DEPTH_DW4_DEPTH__SHIFT
|
464 array_base
<< GEN6_DEPTH_DW4_MIN_ARRAY_ELEMENT__SHIFT
|
465 view_extent
<< GEN6_DEPTH_DW4_RT_VIEW_EXTENT__SHIFT
;
467 STATIC_ASSERT(ARRAY_SIZE(zs
->depth
) >= 5);
474 zs
->depth_format
= format
;
480 zs_set_gen7_3DSTATE_DEPTH_BUFFER(struct ilo_state_zs
*zs
,
481 const struct ilo_dev
*dev
,
482 const struct ilo_state_zs_info
*info
)
484 enum gen_surface_type type
;
485 enum gen_depth_format format
;
486 uint16_t width
, height
, depth
;
487 uint16_t array_base
, view_extent
;
488 uint32_t dw1
, dw2
, dw3
, dw4
, dw6
;
490 ILO_DEV_ASSERT(dev
, 7, 8);
492 if (!zs_validate_gen6(dev
, info
) ||
493 !zs_get_gen6_depth_extent(dev
, info
, &width
, &height
) ||
494 !zs_get_gen6_depth_slices(dev
, info
, &depth
, &array_base
,
498 type
= (info
->is_cube_map
) ? GEN6_SURFTYPE_CUBE
:
499 (info
->z_img
) ? get_gen6_surface_type(dev
, info
->z_img
) :
500 get_gen6_surface_type(dev
, info
->s_img
);
502 format
= (info
->z_img
) ? get_gen6_depth_format(dev
, info
->z_img
) :
503 GEN6_ZFORMAT_D32_FLOAT
;
505 dw1
= type
<< GEN7_DEPTH_DW1_TYPE__SHIFT
|
506 format
<< GEN7_DEPTH_DW1_FORMAT__SHIFT
;
509 if (!info
->z_readonly
)
510 dw1
|= GEN7_DEPTH_DW1_DEPTH_WRITE_ENABLE
;
511 if (info
->hiz_enable
)
512 dw1
|= GEN7_DEPTH_DW1_HIZ_ENABLE
;
514 dw1
|= (info
->z_img
->bo_stride
- 1) << GEN7_DEPTH_DW1_PITCH__SHIFT
;
517 if (info
->s_img
&& !info
->s_readonly
)
518 dw1
|= GEN7_DEPTH_DW1_STENCIL_WRITE_ENABLE
;
521 dw3
= height
<< GEN7_DEPTH_DW3_HEIGHT__SHIFT
|
522 width
<< GEN7_DEPTH_DW3_WIDTH__SHIFT
|
523 info
->level
<< GEN7_DEPTH_DW3_LOD__SHIFT
;
524 dw4
= depth
<< GEN7_DEPTH_DW4_DEPTH__SHIFT
|
525 array_base
<< GEN7_DEPTH_DW4_MIN_ARRAY_ELEMENT__SHIFT
;
526 dw6
= view_extent
<< GEN7_DEPTH_DW6_RT_VIEW_EXTENT__SHIFT
;
528 if (ilo_dev_gen(dev
) >= ILO_GEN(8) && info
->z_img
) {
529 assert(info
->z_img
->walk_layer_height
% 4 == 0);
530 /* note that DW is off-by-one for Gen8+ */
531 dw6
|= (info
->z_img
->walk_layer_height
/ 4) <<
532 GEN8_DEPTH_DW7_QPITCH__SHIFT
;
535 STATIC_ASSERT(ARRAY_SIZE(zs
->depth
) >= 5);
542 zs
->depth_format
= format
;
548 zs_set_gen6_null_3DSTATE_STENCIL_BUFFER(struct ilo_state_zs
*zs
,
549 const struct ilo_dev
*dev
)
551 ILO_DEV_ASSERT(dev
, 6, 8);
553 STATIC_ASSERT(ARRAY_SIZE(zs
->stencil
) >= 3);
556 if (ilo_dev_gen(dev
) >= ILO_GEN(8))
563 zs_set_gen6_3DSTATE_STENCIL_BUFFER(struct ilo_state_zs
*zs
,
564 const struct ilo_dev
*dev
,
565 const struct ilo_state_zs_info
*info
)
567 const struct ilo_image
*img
= info
->s_img
;
570 ILO_DEV_ASSERT(dev
, 6, 8);
572 assert(img
->bo_stride
);
575 * From the Sandy Bridge PRM, volume 2 part 1, page 329:
577 * "The pitch must be set to 2x the value computed based on width, as
578 * the stencil buffer is stored with two rows interleaved."
580 * For Gen7+, we still dobule the stride because we did not double the
581 * slice widths when initializing ilo_image.
583 dw1
= (img
->bo_stride
* 2 - 1) << GEN6_STENCIL_DW1_PITCH__SHIFT
;
585 if (ilo_dev_gen(dev
) >= ILO_GEN(7.5))
586 dw1
|= GEN75_STENCIL_DW1_STENCIL_BUFFER_ENABLE
;
589 /* offset to the level as Gen6 does not support mipmapped stencil */
590 if (ilo_dev_gen(dev
) == ILO_GEN(6)) {
593 ilo_image_get_slice_pos(img
, info
->level
, 0, &x
, &y
);
594 ilo_image_pos_to_mem(img
, x
, y
, &x
, &y
);
595 dw2
|= ilo_image_mem_to_raw(img
, x
, y
);
598 STATIC_ASSERT(ARRAY_SIZE(zs
->stencil
) >= 3);
599 zs
->stencil
[0] = dw1
;
600 zs
->stencil
[1] = dw2
;
602 if (ilo_dev_gen(dev
) >= ILO_GEN(8)) {
605 assert(img
->walk_layer_height
% 4 == 0);
606 dw4
= (img
->walk_layer_height
/ 4) << GEN8_STENCIL_DW4_QPITCH__SHIFT
;
608 zs
->stencil
[2] = dw4
;
615 zs_set_gen6_null_3DSTATE_HIER_DEPTH_BUFFER(struct ilo_state_zs
*zs
,
616 const struct ilo_dev
*dev
)
618 ILO_DEV_ASSERT(dev
, 6, 8);
620 STATIC_ASSERT(ARRAY_SIZE(zs
->hiz
) >= 3);
623 if (ilo_dev_gen(dev
) >= ILO_GEN(8))
630 zs_set_gen6_3DSTATE_HIER_DEPTH_BUFFER(struct ilo_state_zs
*zs
,
631 const struct ilo_dev
*dev
,
632 const struct ilo_state_zs_info
*info
)
634 const struct ilo_image
*img
= info
->z_img
;
637 ILO_DEV_ASSERT(dev
, 6, 8);
639 assert(img
->aux
.bo_stride
);
641 dw1
= (img
->aux
.bo_stride
- 1) << GEN6_HIZ_DW1_PITCH__SHIFT
;
644 /* offset to the level as Gen6 does not support mipmapped HiZ */
645 if (ilo_dev_gen(dev
) == ILO_GEN(6))
646 dw2
|= img
->aux
.walk_lod_offsets
[info
->level
];
648 STATIC_ASSERT(ARRAY_SIZE(zs
->hiz
) >= 3);
652 if (ilo_dev_gen(dev
) >= ILO_GEN(8)) {
655 assert(img
->aux
.walk_layer_height
% 4 == 0);
656 dw4
= (img
->aux
.walk_layer_height
/ 4) << GEN8_HIZ_DW4_QPITCH__SHIFT
;
665 ilo_state_zs_init(struct ilo_state_zs
*zs
, const struct ilo_dev
*dev
,
666 const struct ilo_state_zs_info
*info
)
670 assert(ilo_is_zeroed(zs
, sizeof(*zs
)));
672 if (info
->z_img
|| info
->s_img
) {
673 if (ilo_dev_gen(dev
) >= ILO_GEN(7))
674 ret
&= zs_set_gen7_3DSTATE_DEPTH_BUFFER(zs
, dev
, info
);
676 ret
&= zs_set_gen6_3DSTATE_DEPTH_BUFFER(zs
, dev
, info
);
678 ret
&= zs_set_gen6_null_3DSTATE_DEPTH_BUFFER(zs
, dev
);
682 ret
&= zs_set_gen6_3DSTATE_STENCIL_BUFFER(zs
, dev
, info
);
684 ret
&= zs_set_gen6_null_3DSTATE_STENCIL_BUFFER(zs
, dev
);
686 if (info
->z_img
&& info
->hiz_enable
)
687 ret
&= zs_set_gen6_3DSTATE_HIER_DEPTH_BUFFER(zs
, dev
, info
);
689 ret
&= zs_set_gen6_null_3DSTATE_HIER_DEPTH_BUFFER(zs
, dev
);
691 zs
->z_readonly
= info
->z_readonly
;
692 zs
->s_readonly
= info
->s_readonly
;
700 ilo_state_zs_init_for_null(struct ilo_state_zs
*zs
,
701 const struct ilo_dev
*dev
)
703 struct ilo_state_zs_info info
;
705 memset(&info
, 0, sizeof(info
));
707 return ilo_state_zs_init(zs
, dev
, &info
);
711 ilo_state_zs_disable_hiz(struct ilo_state_zs
*zs
,
712 const struct ilo_dev
*dev
)
714 ILO_DEV_ASSERT(dev
, 6, 8);
717 * Separate stencil must be disabled simultaneously on Gen6. We can make
718 * it work when there is no stencil buffer, but it is probably not worth
721 assert(ilo_dev_gen(dev
) >= ILO_GEN(7));
723 zs
->depth
[0] &= ~GEN7_DEPTH_DW1_HIZ_ENABLE
;
724 zs_set_gen6_null_3DSTATE_HIER_DEPTH_BUFFER(zs
, dev
);