mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 11:48:06 +02:00
panfrost,panvk: Enable shader_realtime_clock on panthor 1.6
shader_realtime_clock requires a newer kernel version in order to enable GLB_COUNTER_EN this change adds a check on this kernel functionality. Remove GL_EXT_shader_realtime_clock from extensions as this now depends on kernel version. Fixes:e9c2c324("panvk: enable VK_KHR_shader_clock") Signed-off-by: Ashley Smith <ashley.smith@collabora.com> Reviewed-by: Daniel Stone <daniels@collabora.com> (cherry picked from commit5681fabdc2) Conflicts: src/panfrost/ci/panfrost-g610-gles2-extensions.txt Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/39003>
This commit is contained in:
parent
c49e76b529
commit
3a0683435e
7 changed files with 14 additions and 4 deletions
|
|
@ -1194,7 +1194,7 @@
|
|||
"description": "panfrost,panvk: Enable shader_realtime_clock on panthor 1.6",
|
||||
"nominated": true,
|
||||
"nomination_type": 2,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": "e9c2c3240949196a5584ed1c54df4b9bb75dcbf3",
|
||||
"notes": null
|
||||
|
|
|
|||
|
|
@ -710,7 +710,8 @@ panfrost_init_screen_caps(struct panfrost_screen *screen)
|
|||
caps->shader_clock = dev->arch >= 6 &&
|
||||
dev->kmod.props.gpu_can_query_timestamp;
|
||||
caps->shader_realtime_clock = dev->arch >= 6 &&
|
||||
dev->kmod.props.gpu_can_query_timestamp;
|
||||
dev->kmod.props.gpu_can_query_timestamp &&
|
||||
dev->kmod.props.timestamp_device_coherent;
|
||||
|
||||
caps->vs_instanceid = true;
|
||||
caps->texture_multisample = true;
|
||||
|
|
|
|||
|
|
@ -45,7 +45,6 @@ GL_EXT_shader_framebuffer_fetch_non_coherent
|
|||
GL_EXT_shader_implicit_conversions
|
||||
GL_EXT_shader_integer_mix
|
||||
GL_EXT_shader_io_blocks
|
||||
GL_EXT_shader_realtime_clock
|
||||
GL_EXT_shadow_samplers
|
||||
GL_EXT_sRGB
|
||||
GL_EXT_sRGB_write_control
|
||||
|
|
|
|||
|
|
@ -205,6 +205,9 @@ struct pan_kmod_dev_props {
|
|||
/* Support cycle count and timestamp propagation as job requirement */
|
||||
bool gpu_can_query_timestamp;
|
||||
|
||||
/* Cycle counter and timestamp device coherent propogation is enabled */
|
||||
bool timestamp_device_coherent;
|
||||
|
||||
/* GPU Timestamp frequency */
|
||||
uint64_t timestamp_frequency;
|
||||
|
||||
|
|
|
|||
|
|
@ -211,6 +211,9 @@ panfrost_dev_query_props(const struct pan_kmod_dev *dev,
|
|||
fd, DRM_PANFROST_PARAM_SYSTEM_TIMESTAMP_FREQUENCY, true, 0);
|
||||
}
|
||||
|
||||
/* Device coherent timestamps are always enabled on panfrost */
|
||||
props->timestamp_device_coherent = true;
|
||||
|
||||
/* Support for priorities was added in panfrost 1.5, assumes default
|
||||
* priority as medium if the param doesn't exist. */
|
||||
uint64_t prios =
|
||||
|
|
|
|||
|
|
@ -286,6 +286,10 @@ panthor_dev_query_props(const struct pan_kmod_dev *dev,
|
|||
panthor_dev->props.group_priorities.allowed_mask),
|
||||
};
|
||||
|
||||
if (dev->driver.version.major > 1 || dev->driver.version.minor >= 6) {
|
||||
props->timestamp_device_coherent = true;
|
||||
}
|
||||
|
||||
static_assert(sizeof(props->texture_features) ==
|
||||
sizeof(panthor_dev->props.gpu.texture_features),
|
||||
"Mismatch in texture_features array size");
|
||||
|
|
|
|||
|
|
@ -486,7 +486,7 @@ panvk_per_arch(get_physical_device_features)(
|
|||
|
||||
/* VK_KHR_shader_clock */
|
||||
.shaderSubgroupClock = device->kmod.props.gpu_can_query_timestamp,
|
||||
.shaderDeviceClock = device->kmod.props.gpu_can_query_timestamp,
|
||||
.shaderDeviceClock = device->kmod.props.timestamp_device_coherent,
|
||||
|
||||
/* VK_KHR_shader_quad_control */
|
||||
.shaderQuadControl = true,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue