<div dir="ltr"><div><div>Thanks!<br><br></div>Reviewed-by: Jason Ekstrand <<a href="mailto:jason@jlekstrand.net">jason@jlekstrand.net</a>><br></div>Cc: "13.0" <<a href="mailto:mesa-stable@lists.freedesktop.org">mesa-stable@lists.freedesktop.org</a>><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Mon, Nov 14, 2016 at 9:26 AM, Lionel Landwerlin <span dir="ltr"><<a href="mailto:llandwerlin@gmail.com" target="_blank">llandwerlin@gmail.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">A commit from the CTS suite on the 1.0-dev branch started using<br>
VK_REMAINING_MIP_LEVELS, we're not dealing with it properly for clears.<br>
<br>
Fixes:<br>
   dEQP-VK.api.image_clearing.<wbr>clear_color_image.*<br>
<br>
Signed-off-by: Lionel Landwerlin <<a href="mailto:lionel.g.landwerlin@intel.com">lionel.g.landwerlin@intel.com</a><wbr>><br>
---<br>
 src/intel/vulkan/anv_blorp.c | 4 ++--<br>
 1 file changed, 2 insertions(+), 2 deletions(-)<br>
<br>
diff --git a/src/intel/vulkan/anv_blorp.c b/src/intel/vulkan/anv_blorp.c<br>
index b78c21d..d59c1a7 100644<br>
--- a/src/intel/vulkan/anv_blorp.c<br>
+++ b/src/intel/vulkan/anv_blorp.c<br>
@@ -803,7 +803,7 @@ void anv_CmdClearColorImage(<br>
       unsigned base_layer = pRanges[r].baseArrayLayer;<br>
       unsigned layer_count = pRanges[r].layerCount;<br>
<br>
-      for (unsigned i = 0; i < pRanges[r].levelCount; i++) {<br>
+      for (unsigned i = 0; i < anv_get_levelCount(image, &pRanges[r]); i++) {<br>
          const unsigned level = pRanges[r].baseMipLevel + i;<br>
          const unsigned level_width = anv_minify(image->extent.<wbr>width, level);<br>
          const unsigned level_height = anv_minify(image->extent.<wbr>height, level);<br>
@@ -863,7 +863,7 @@ void anv_CmdClearDepthStencilImage(<br>
       unsigned base_layer = pRanges[r].baseArrayLayer;<br>
       unsigned layer_count = pRanges[r].layerCount;<br>
<br>
-      for (unsigned i = 0; i < pRanges[r].levelCount; i++) {<br>
+      for (unsigned i = 0; i < anv_get_levelCount(image, &pRanges[r]); i++) {<br>
          const unsigned level = pRanges[r].baseMipLevel + i;<br>
          const unsigned level_width = anv_minify(image->extent.<wbr>width, level);<br>
          const unsigned level_height = anv_minify(image->extent.<wbr>height, level);<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.10.2<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>