mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-09 04:38:03 +02:00
intel: don't assume Linux minor dev node
Signed-off-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Cc: mesa-stable
Acked-by: Emma Anholt <emma@anholt.net>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24744>
(cherry picked from commit a851dc5e3c)
This commit is contained in:
parent
c0f9930089
commit
254ba0ecd3
5 changed files with 4 additions and 8 deletions
|
|
@ -850,7 +850,7 @@
|
|||
"description": "intel: don't assume Linux minor dev node",
|
||||
"nominated": true,
|
||||
"nomination_type": 0,
|
||||
"resolution": 0,
|
||||
"resolution": 1,
|
||||
"main_sha": null,
|
||||
"because_sha": null
|
||||
},
|
||||
|
|
|
|||
|
|
@ -111,10 +111,7 @@ void iris_utrace_init(struct iris_context *ice)
|
|||
else
|
||||
minor = 0;
|
||||
|
||||
/* We could be dealing with /dev/dri/card0 or /dev/dri/renderD128 so to get
|
||||
* a GPU ID we % 128 the minor number.
|
||||
*/
|
||||
intel_ds_device_init(&ice->ds, screen->devinfo, screen->fd, minor % 128,
|
||||
intel_ds_device_init(&ice->ds, screen->devinfo, screen->fd, minor,
|
||||
INTEL_DS_API_OPENGL);
|
||||
u_trace_pipe_context_init(&ice->ds.trace_context, &ice->ctx,
|
||||
iris_utrace_record_ts,
|
||||
|
|
|
|||
|
|
@ -543,7 +543,6 @@ intel_ds_device_init(struct intel_ds_device *device,
|
|||
{
|
||||
memset(device, 0, sizeof(*device));
|
||||
|
||||
assert(gpu_id < 128);
|
||||
device->gpu_id = gpu_id;
|
||||
device->gpu_clock_id = intel_pps_clock_id(gpu_id);
|
||||
device->fd = drm_fd;
|
||||
|
|
|
|||
|
|
@ -288,7 +288,7 @@ anv_device_utrace_init(struct anv_device *device)
|
|||
{
|
||||
anv_bo_pool_init(&device->utrace_bo_pool, device, "utrace");
|
||||
intel_ds_device_init(&device->ds, device->info, device->fd,
|
||||
device->physical->local_minor - 128,
|
||||
device->physical->local_minor,
|
||||
INTEL_DS_API_VULKAN);
|
||||
u_trace_context_init(&device->ds.trace_context,
|
||||
&device->ds,
|
||||
|
|
|
|||
|
|
@ -271,7 +271,7 @@ anv_device_utrace_init(struct anv_device *device)
|
|||
{
|
||||
anv_bo_pool_init(&device->utrace_bo_pool, device, "utrace");
|
||||
intel_ds_device_init(&device->ds, device->info, device->fd,
|
||||
device->physical->local_minor - 128,
|
||||
device->physical->local_minor,
|
||||
INTEL_DS_API_VULKAN);
|
||||
u_trace_context_init(&device->ds.trace_context,
|
||||
&device->ds,
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue