Skip to content

Commit cbc3fa8

Browse files
committed
Merge tag 'drm-misc-fixes-2025-07-16' of https://gitlab.freedesktop.org/drm/misc/kernel into drm-fixes
drm-misc-fixes for v6.16 final?: - nouveau ioctl validation fix. - panfrost scheduler bug. Signed-off-by: Dave Airlie <[email protected]> From: Maarten Lankhorst <[email protected]> Link: https://lore.kernel.org/r/[email protected]
2 parents 347e9f5 + cb345f9 commit cbc3fa8

File tree

2 files changed

+6
-7
lines changed

2 files changed

+6
-7
lines changed

drivers/gpu/drm/nouveau/nouveau_drm.c

Lines changed: 5 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1284,6 +1284,9 @@ nouveau_ioctls[] = {
12841284
DRM_IOCTL_DEF_DRV(NOUVEAU_EXEC, nouveau_exec_ioctl_exec, DRM_RENDER_ALLOW),
12851285
};
12861286

1287+
#define DRM_IOCTL_NOUVEAU_NVIF _IOC(_IOC_READ | _IOC_WRITE, DRM_IOCTL_BASE, \
1288+
DRM_COMMAND_BASE + DRM_NOUVEAU_NVIF, 0)
1289+
12871290
long
12881291
nouveau_drm_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
12891292
{
@@ -1297,14 +1300,10 @@ nouveau_drm_ioctl(struct file *file, unsigned int cmd, unsigned long arg)
12971300
return ret;
12981301
}
12991302

1300-
switch (_IOC_NR(cmd) - DRM_COMMAND_BASE) {
1301-
case DRM_NOUVEAU_NVIF:
1303+
if ((cmd & ~IOCSIZE_MASK) == DRM_IOCTL_NOUVEAU_NVIF)
13021304
ret = nouveau_abi16_ioctl(filp, (void __user *)arg, _IOC_SIZE(cmd));
1303-
break;
1304-
default:
1305+
else
13051306
ret = drm_ioctl(file, cmd, arg);
1306-
break;
1307-
}
13081307

13091308
pm_runtime_mark_last_busy(dev->dev);
13101309
pm_runtime_put_autosuspend(dev->dev);

drivers/gpu/drm/panfrost/panfrost_job.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -841,7 +841,6 @@ int panfrost_job_init(struct panfrost_device *pfdev)
841841
.num_rqs = DRM_SCHED_PRIORITY_COUNT,
842842
.credit_limit = 2,
843843
.timeout = msecs_to_jiffies(JOB_TIMEOUT_MS),
844-
.timeout_wq = pfdev->reset.wq,
845844
.name = "pan_js",
846845
.dev = pfdev->dev,
847846
};
@@ -879,6 +878,7 @@ int panfrost_job_init(struct panfrost_device *pfdev)
879878
pfdev->reset.wq = alloc_ordered_workqueue("panfrost-reset", 0);
880879
if (!pfdev->reset.wq)
881880
return -ENOMEM;
881+
args.timeout_wq = pfdev->reset.wq;
882882

883883
for (j = 0; j < NUM_JOB_SLOTS; j++) {
884884
js->queue[j].fence_context = dma_fence_context_alloc(1);

0 commit comments

Comments
 (0)