etnaviv: Allow collecing both GPU and NPU specs

If the primary core is a GPU, but a separate NPU exists, collect
NPU specs in addition to GPU specs.

Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Reviewed-by: Christian Gmeiner <cgmeiner@igalia.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/28921>
This commit is contained in:
Philipp Zabel 2024-04-25 09:42:01 +02:00 committed by Marge Bot
parent a4653587cc
commit c2053c5363
1 changed files with 6 additions and 1 deletions

View File

@ -858,7 +858,12 @@ etna_get_specs(struct etna_screen *screen)
screen->specs.pixel_pipes = info->gpu.pixel_pipes;
screen->specs.num_constants = info->gpu.num_constants;
screen->specs.max_varyings = MIN2(info->gpu.max_varyings, ETNA_NUM_VARYINGS);
} else {
if (screen->npu)
info = etna_gpu_get_core_info(screen->npu);
}
if (info->type == ETNA_CORE_NPU) {
screen->specs.nn_core_count = info->npu.nn_core_count;
screen->specs.nn_mad_per_core = info->npu.nn_mad_per_core;
screen->specs.tp_core_count = info->npu.tp_core_count;