[PATCH] drm: support up to 128 drm devices

James Zhu James.Zhu at amd.com
Fri Jun 30 11:48:38 UTC 2023


From: Christian König <ckoenig.leichtzumerken at gmail.com>

This makes room for up to 128 DRM devices.

Signed-off-by: Christian König <christian.koenig at amd.com>
Signed-off-by: James Zhu <James.Zhu at amd.com>
---
 drivers/gpu/drm/drm_drv.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/drm_drv.c b/drivers/gpu/drm/drm_drv.c
index 73b845a75d52..0d55c64444f5 100644
--- a/drivers/gpu/drm/drm_drv.c
+++ b/drivers/gpu/drm/drm_drv.c
@@ -137,7 +137,7 @@ static int drm_minor_alloc(struct drm_device *dev, unsigned int type)
 		r = idr_alloc(&drm_minors_idr,
 			NULL,
 			64 * type,
-			64 * (type + 1),
+			64 * (type + 2),
 			GFP_NOWAIT);
 		spin_unlock_irqrestore(&drm_minor_lock, flags);
 	}
-- 
2.34.1



More information about the dri-devel mailing list