[PATCH] drm/ttm: set max_active to recommened default
Christian König
christian.koenig at amd.com
Mon Nov 13 09:42:42 UTC 2023
Am 11.11.23 um 14:11 schrieb Rajneesh Bhardwaj:
> To maximize per cpu execution context for the work items, use the
> recommended settings i.e. WQ_DFL_ACTIVE(256). There is no apparent
> reason to throttle to 16 while process tear down.
Well big NAK to this. During process tear down it can be that hundreds
of BOs are released at the same time.
We really don't want to start a kernel thread for each of them just to
wait for it to be idle.
Regards,
Christian.
>
> Signed-off-by: Rajneesh Bhardwaj <rajneesh.bhardwaj at amd.com>
> ---
> drivers/gpu/drm/ttm/ttm_device.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/ttm/ttm_device.c b/drivers/gpu/drm/ttm/ttm_device.c
> index bc97e3dd40f0..5443c0f19213 100644
> --- a/drivers/gpu/drm/ttm/ttm_device.c
> +++ b/drivers/gpu/drm/ttm/ttm_device.c
> @@ -205,7 +205,7 @@ int ttm_device_init(struct ttm_device *bdev, struct ttm_device_funcs *funcs,
> return ret;
>
> bdev->wq = alloc_workqueue("ttm",
> - WQ_MEM_RECLAIM | WQ_HIGHPRI | WQ_UNBOUND, 16);
> + WQ_MEM_RECLAIM | WQ_HIGHPRI | WQ_UNBOUND, 0);
> if (!bdev->wq) {
> ttm_global_release();
> return -ENOMEM;
More information about the amd-gfx
mailing list