mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 07:28:11 +02:00
intel: remove chipset_id
The chipset_id should be named after i915 ioctl that's called to get the device id. In user space this field holds pci device id in reality. We now have a pci_device_id queried from drm instead using the ioctl, so there is no much reason to keep the chipset_id for the same purpose. 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
ddfa3924b3
commit
f43c7185e0
7 changed files with 11 additions and 17 deletions
|
|
@ -731,7 +731,7 @@ crocus_screen_create(int fd, const struct pipe_screen_config *config)
|
|||
|
||||
if (!intel_get_device_info_from_fd(fd, &screen->devinfo))
|
||||
return NULL;
|
||||
screen->pci_id = screen->devinfo.chipset_id;
|
||||
screen->pci_id = screen->devinfo.pci_device_id;
|
||||
|
||||
if (screen->devinfo.ver > 8)
|
||||
return NULL;
|
||||
|
|
|
|||
|
|
@ -782,7 +782,7 @@ iris_screen_create(int fd, const struct pipe_screen_config *config)
|
|||
|
||||
if (!intel_get_device_info_from_fd(fd, &screen->devinfo))
|
||||
return NULL;
|
||||
screen->pci_id = screen->devinfo.chipset_id;
|
||||
screen->pci_id = screen->devinfo.pci_device_id;
|
||||
|
||||
p_atomic_set(&screen->refcount, 1);
|
||||
|
||||
|
|
|
|||
|
|
@ -1363,7 +1363,6 @@ intel_get_device_info_from_pci_id(int pci_id,
|
|||
|
||||
update_cs_workgroup_threads(devinfo);
|
||||
|
||||
devinfo->chipset_id = pci_id;
|
||||
return true;
|
||||
}
|
||||
|
||||
|
|
@ -1537,7 +1536,7 @@ fixup_chv_device_info(struct intel_device_info *devinfo)
|
|||
/* Braswell is even more annoying. Its marketing name isn't determinable
|
||||
* from the PCI ID and is also dependent on fusing.
|
||||
*/
|
||||
if (devinfo->chipset_id != 0x22B1)
|
||||
if (devinfo->pci_device_id != 0x22B1)
|
||||
return;
|
||||
|
||||
char *bsw_model;
|
||||
|
|
|
|||
|
|
@ -360,18 +360,13 @@ struct intel_device_info
|
|||
*/
|
||||
int simulator_id;
|
||||
|
||||
/**
|
||||
* holds the pci device id
|
||||
*/
|
||||
uint32_t chipset_id;
|
||||
|
||||
/**
|
||||
* holds the name of the device
|
||||
*/
|
||||
char name[INTEL_DEVICE_MAX_NAME_SIZE];
|
||||
|
||||
/**
|
||||
* no_hw is true when the chipset_id pci device id has been overridden
|
||||
* no_hw is true when the pci_device_id has been overridden
|
||||
*/
|
||||
bool no_hw;
|
||||
/** @} */
|
||||
|
|
|
|||
|
|
@ -123,7 +123,7 @@ ensure_device_info(int fd)
|
|||
if (device == 0) {
|
||||
fail_if(!intel_get_device_info_from_fd(fd, &devinfo),
|
||||
"failed to identify chipset.\n");
|
||||
device = devinfo.chipset_id;
|
||||
device = devinfo.pci_device_id;
|
||||
} else if (devinfo.ver == 0) {
|
||||
fail_if(!intel_get_device_info_from_pci_id(device, &devinfo),
|
||||
"failed to identify chipset.\n");
|
||||
|
|
|
|||
|
|
@ -562,8 +562,8 @@ anv_physical_device_init_uuids(struct anv_physical_device *device)
|
|||
*/
|
||||
_mesa_sha1_init(&sha1_ctx);
|
||||
_mesa_sha1_update(&sha1_ctx, build_id_data(note), build_id_len);
|
||||
_mesa_sha1_update(&sha1_ctx, &device->info.chipset_id,
|
||||
sizeof(device->info.chipset_id));
|
||||
_mesa_sha1_update(&sha1_ctx, &device->info.pci_device_id,
|
||||
sizeof(device->info.pci_device_id));
|
||||
_mesa_sha1_update(&sha1_ctx, &device->always_use_bindless,
|
||||
sizeof(device->always_use_bindless));
|
||||
_mesa_sha1_update(&sha1_ctx, &device->has_a64_buffer_access,
|
||||
|
|
@ -587,7 +587,7 @@ anv_physical_device_init_disk_cache(struct anv_physical_device *device)
|
|||
#ifdef ENABLE_SHADER_CACHE
|
||||
char renderer[10];
|
||||
ASSERTED int len = snprintf(renderer, sizeof(renderer), "anv_%04x",
|
||||
device->info.chipset_id);
|
||||
device->info.pci_device_id);
|
||||
assert(len == sizeof(renderer) - 2);
|
||||
|
||||
char timestamp[41];
|
||||
|
|
@ -1949,7 +1949,7 @@ void anv_GetPhysicalDeviceProperties(
|
|||
.apiVersion = ANV_API_VERSION,
|
||||
.driverVersion = vk_get_driver_version(),
|
||||
.vendorID = 0x8086,
|
||||
.deviceID = pdevice->info.chipset_id,
|
||||
.deviceID = pdevice->info.pci_device_id,
|
||||
.deviceType = pdevice->info.has_local_mem ?
|
||||
VK_PHYSICAL_DEVICE_TYPE_DISCRETE_GPU :
|
||||
VK_PHYSICAL_DEVICE_TYPE_INTEGRATED_GPU,
|
||||
|
|
|
|||
|
|
@ -521,7 +521,7 @@ anv_pipeline_cache_load(struct anv_pipeline_cache *cache,
|
|||
return;
|
||||
if (header.vendor_id != 0x8086)
|
||||
return;
|
||||
if (header.device_id != device->info.chipset_id)
|
||||
if (header.device_id != device->info.pci_device_id)
|
||||
return;
|
||||
if (memcmp(header.uuid, pdevice->pipeline_cache_uuid, VK_UUID_SIZE) != 0)
|
||||
return;
|
||||
|
|
@ -602,7 +602,7 @@ VkResult anv_GetPipelineCacheData(
|
|||
.header_size = sizeof(struct vk_pipeline_cache_header),
|
||||
.header_version = VK_PIPELINE_CACHE_HEADER_VERSION_ONE,
|
||||
.vendor_id = 0x8086,
|
||||
.device_id = device->info.chipset_id,
|
||||
.device_id = device->info.pci_device_id,
|
||||
};
|
||||
memcpy(header.uuid, device->physical->pipeline_cache_uuid, VK_UUID_SIZE);
|
||||
blob_write_bytes(&blob, &header, sizeof(header));
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue