[Mesa-dev] [PATCH] radv: use device name in cache creation like radeonsi.

Bas Nieuwenhuizen bas at basnieuwenhuizen.nl
Wed Oct 25 01:52:06 UTC 2017


Reviewed-by: Bas Nieuwenhuizen <bas at basnieuwenhuizen.nl>

On Wed, Oct 25, 2017 at 3:24 AM, Dave Airlie <airlied at gmail.com> wrote:
> From: Dave Airlie <airlied at redhat.com>
>
> Not sure how useful this is, but it makes it more consistent.
>
> Signed-off-by: Dave Airlie <airlied at redhat.com>
> ---
>  src/amd/vulkan/radv_device.c | 5 +++--
>  1 file changed, 3 insertions(+), 2 deletions(-)
>
> diff --git a/src/amd/vulkan/radv_device.c b/src/amd/vulkan/radv_device.c
> index c4e25222eaf..ebc74fbadef 100644
> --- a/src/amd/vulkan/radv_device.c
> +++ b/src/amd/vulkan/radv_device.c
> @@ -152,6 +152,8 @@ radv_physical_device_init(struct radv_physical_device *device,
>                 goto fail;
>         }
>
> +       device->name = get_chip_name(device->rad_info.family);
> +
>         if (radv_device_get_cache_uuid(device->rad_info.family, device->cache_uuid)) {
>                 radv_finish_wsi(device);
>                 device->ws->destroy(device->ws);
> @@ -170,10 +172,9 @@ radv_physical_device_init(struct radv_physical_device *device,
>          */
>         char buf[VK_UUID_SIZE + 1];
>         disk_cache_format_hex_id(buf, device->cache_uuid, VK_UUID_SIZE);
> -       device->disk_cache = disk_cache_create("radv", buf, shader_env_flags);
> +       device->disk_cache = disk_cache_create(device->name, buf, shader_env_flags);
>
>         fprintf(stderr, "WARNING: radv is not a conformant vulkan implementation, testing use only.\n");
> -       device->name = get_chip_name(device->rad_info.family);
>
>         radv_get_driver_uuid(&device->device_uuid);
>         radv_get_device_uuid(&device->rad_info, &device->device_uuid);
> --
> 2.14.2
>
> _______________________________________________
> mesa-dev mailing list
> mesa-dev at lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list