<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Tue, Jun 13, 2017 at 11:41 AM, Nanley Chery <span dir="ltr"><<a href="mailto:nanleychery@gmail.com" target="_blank">nanleychery@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Signed-off-by: Nanley Chery <<a href="mailto:nanley.g.chery@intel.com">nanley.g.chery@intel.com</a>><br>
---<br>
 src/intel/blorp/blorp_clear.c | 4 ++++<br>
 1 file changed, 4 insertions(+)<br>
<br>
diff --git a/src/intel/blorp/blorp_clear.<wbr>c b/src/intel/blorp/blorp_clear.<wbr>c<br>
index 3d5c41cc71..f43d05ad19 100644<br>
--- a/src/intel/blorp/blorp_clear.<wbr>c<br>
+++ b/src/intel/blorp/blorp_clear.<wbr>c<br>
@@ -308,6 +308,10 @@ blorp_fast_clear(struct blorp_batch *batch,<br>
                  uint32_t level, uint32_t start_layer, uint32_t num_layers,<br>
                  uint32_t x0, uint32_t y0, uint32_t x1, uint32_t y1)<br>
 {<br>
+   /* Multi-layer and multi-LOD fast clear is only available gen8+. */<br>
+   assert(ISL_DEV_GEN(batch-><wbr>blorp->isl_dev) >= 8 ||<br>
+          (level == 0 && start_layer + num_layers == 1));<br></blockquote><div><br></div><div>Alternatively, you could just add code to patch 1 which asserts that the level/layer is in-bounds for the auxiliary surface if one exists.<br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
+<br>
    struct blorp_params params;<br>
    blorp_params_init(&params);<br>
    params.num_layers = num_layers;<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.13.1<br>
<br>
______________________________<wbr>_________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="https://lists.freedesktop.org/mailman/listinfo/mesa-dev" rel="noreferrer" target="_blank">https://lists.freedesktop.org/<wbr>mailman/listinfo/mesa-dev</a><br>
</font></span></blockquote></div><br></div></div>