intel: add swizzle flag into driver uuid
Suggested by Lionel Landwerlin, we add has_bit6_swizzle as another input when computing driver uuid. Also fix miscalculation of the length of driver tag. Signed-off-by: Jianxun Zhang <jianxun.zhang@linux.intel.com> Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com> Reviewed-by: Rohan Garg <rohan.garg@intel.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/13936>
This commit is contained in:
parent
f43c7185e0
commit
14a4600b62
|
@ -78,7 +78,9 @@ intel_uuid_compute_driver_id(uint8_t *uuid,
|
||||||
* UUID.
|
* UUID.
|
||||||
*/
|
*/
|
||||||
_mesa_sha1_init(&sha1_ctx);
|
_mesa_sha1_init(&sha1_ctx);
|
||||||
_mesa_sha1_update(&sha1_ctx, intelDriver, strlen(intelDriver) * sizeof(char));
|
_mesa_sha1_update(&sha1_ctx, intelDriver, strlen(intelDriver));
|
||||||
|
_mesa_sha1_update(&sha1_ctx, &devinfo->has_bit6_swizzle,
|
||||||
|
sizeof(devinfo->has_bit6_swizzle));
|
||||||
_mesa_sha1_final(&sha1_ctx, sha1);
|
_mesa_sha1_final(&sha1_ctx, sha1);
|
||||||
memcpy(uuid, sha1, size);
|
memcpy(uuid, sha1, size);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue