mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-08 15:38:09 +02:00
ac: Don't negate strstr return values in ac_query_gpu_info
strstr returns a pointer to the needle sub-string within the haystack
string if the latter contains the former, or NULL otherwise. So this
essentially always set info->is_pro_graphics = true, since probably no
marketing name ever contains all of these sub-strings.
Fixes: b635dff256 "ac: fix detection of Pro graphics"
Reviewed-by: Pierre-Eric Pelloux-Prayer <pierre-eric.pelloux-prayer@amd.com>
Reviewed-by: Marek Olšák <marek.olsak@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7675>
This commit is contained in:
parent
9374a1ecfe
commit
493400cf1e
1 changed files with 3 additions and 3 deletions
|
|
@ -441,9 +441,9 @@ bool ac_query_gpu_info(int fd, void *dev_p,
|
|||
info->chip_external_rev = amdinfo->chip_external_rev;
|
||||
info->marketing_name = amdgpu_get_marketing_name(dev);
|
||||
info->is_pro_graphics = info->marketing_name &&
|
||||
(!strstr(info->marketing_name, "Pro") ||
|
||||
!strstr(info->marketing_name, "PRO") ||
|
||||
!strstr(info->marketing_name, "Frontier"));
|
||||
(strstr(info->marketing_name, "Pro") ||
|
||||
strstr(info->marketing_name, "PRO") ||
|
||||
strstr(info->marketing_name, "Frontier"));
|
||||
|
||||
/* Set which chips have dedicated VRAM. */
|
||||
info->has_dedicated_vram =
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue