<div dir="ltr"><div>Fine by me. I even considered suggesting it yesterday.<br><br></div>Reviewed-by: Jason Ekstrand <<a href="mailto:jason@jlekstrand.net">jason@jlekstrand.net</a>><br></div><div class="gmail_extra"><br><div class="gmail_quote">On Wed, Feb 28, 2018 at 9:13 AM, Tapani Pälli <span dir="ltr"><<a href="mailto:tapani.palli@intel.com" target="_blank">tapani.palli@intel.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">anv_gem_set_context_param is to be used directly instead!<br>
<br>
Fixes: 6d8ab53303 "anv: implement VK_EXT_global_priority extension"<br>
Signed-off-by: Tapani Pälli <<a href="mailto:tapani.palli@intel.com">tapani.palli@intel.com</a>><br>
---<br>
src/intel/vulkan/anv_device.c | 5 +++--<br>
src/intel/vulkan/anv_gem.c | 9 ---------<br>
src/intel/vulkan/anv_private.h | 1 -<br>
3 files changed, 3 insertions(+), 12 deletions(-)<br>
<br>
diff --git a/src/intel/vulkan/anv_device.<wbr>c b/src/intel/vulkan/anv_device.<wbr>c<br>
index f314d7667d..56c0c5fa9f 100644<br>
--- a/src/intel/vulkan/anv_device.<wbr>c<br>
+++ b/src/intel/vulkan/anv_device.<wbr>c<br>
@@ -1433,8 +1433,9 @@ VkResult anv_CreateDevice(<br>
* is returned.<br>
*/<br>
if (physical_device->has_context_<wbr>priority) {<br>
- int err =<br>
- anv_gem_set_context_priority(<wbr>device, vk_priority_to_gen(priority));<br>
+ int err = anv_gem_set_context_param(<wbr>device->fd, device->context_id,<br>
+ I915_CONTEXT_PARAM_PRIORITY,<br>
+ vk_priority_to_gen(priority));<br>
if (err != 0 && priority > VK_QUEUE_GLOBAL_PRIORITY_<wbr>MEDIUM_EXT) {<br>
result = vk_error(VK_ERROR_NOT_<wbr>PERMITTED_EXT);<br>
goto fail_fd;<br>
diff --git a/src/intel/vulkan/anv_gem.c b/src/intel/vulkan/anv_gem.c<br>
index 93072c7d3b..2a8f8b14b7 100644<br>
--- a/src/intel/vulkan/anv_gem.c<br>
+++ b/src/intel/vulkan/anv_gem.c<br>
@@ -303,15 +303,6 @@ close_and_return:<br>
return swizzled;<br>
}<br>
<br>
-int<br>
-anv_gem_set_context_priority(<wbr>struct anv_device *device,<br>
- int priority)<br>
-{<br>
- return anv_gem_set_context_param(<wbr>device->fd, device->context_id,<br>
- I915_CONTEXT_PARAM_PRIORITY,<br>
- priority);<br>
-}<br>
-<br>
bool<br>
anv_gem_has_context_priority(<wbr>int fd)<br>
{<br>
diff --git a/src/intel/vulkan/anv_<wbr>private.h b/src/intel/vulkan/anv_<wbr>private.h<br>
index 3a4a80d869..a6863f5532 100644<br>
--- a/src/intel/vulkan/anv_<wbr>private.h<br>
+++ b/src/intel/vulkan/anv_<wbr>private.h<br>
@@ -925,7 +925,6 @@ int anv_gem_set_tiling(struct anv_device *device, uint32_t gem_handle,<br>
uint32_t stride, uint32_t tiling);<br>
int anv_gem_create_context(struct anv_device *device);<br>
bool anv_gem_has_context_priority(<wbr>int fd);<br>
-int anv_gem_set_context_priority(<wbr>struct anv_device *device, int priority);<br>
int anv_gem_destroy_context(struct anv_device *device, int context);<br>
int anv_gem_set_context_param(int fd, int context, uint32_t param,<br>
uint64_t value);<br>
<span class="HOEnZb"><font color="#888888">--<br>
2.13.6<br>
<br>
</font></span></blockquote></div><br></div>