diff options
author | Marcin Ĺšlusarz <marcin.slusarz@intel.com> | 2022-05-06 16:37:27 +0200 |
---|---|---|
committer | Dylan Baker <dylan.c.baker@intel.com> | 2022-06-27 09:18:26 -0700 |
commit | 02923d768501d596171a3ecaef0946c41aed4423 (patch) | |
tree | c10402ad68061ddfb79778cfe23e93952cd50ee5 | |
parent | c7dce6945d1bef4fbe7bcb0bff650d88d9d00278 (diff) |
intel/common: allocate space for at least one task urb
Fixes: c93cbc77f78 ("intel/common: Add helper for URB allocation in Mesh pipeline")
Acked-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/16196>
(cherry picked from commit 3dc6a98d78c669b28ee600b9da7086febb859e8f)
-rw-r--r-- | .pick_status.json | 2 | ||||
-rw-r--r-- | src/intel/common/intel_urb_config.c | 5 |
2 files changed, 5 insertions, 2 deletions
diff --git a/.pick_status.json b/.pick_status.json index 35719bca391..8bb44c8b8d7 100644 --- a/.pick_status.json +++ b/.pick_status.json @@ -85,7 +85,7 @@ "description": "intel/common: allocate space for at least one task urb", "nominated": true, "nomination_type": 1, - "resolution": 0, + "resolution": 1, "main_sha": null, "because_sha": "c93cbc77f78ac4d6c479f657e6f92952fd357211" }, diff --git a/src/intel/common/intel_urb_config.c b/src/intel/common/intel_urb_config.c index 2f7d72cc31f..63dc04cb829 100644 --- a/src/intel/common/intel_urb_config.c +++ b/src/intel/common/intel_urb_config.c @@ -338,7 +338,10 @@ intel_get_mesh_urb_config(const struct intel_device_info *devinfo, task_urb_share = task_urb_share_percentage / 100.0f; } - const unsigned task_urb_kb = ALIGN(total_urb_kb * task_urb_share, 8); + const unsigned one_task_urb_kb = ALIGN(r.task_entry_size_64b * 64, 1024) / 1024; + + const unsigned task_urb_kb = ALIGN(MAX2(total_urb_kb * task_urb_share, one_task_urb_kb), 8); + const unsigned mesh_urb_kb = total_urb_kb - task_urb_kb; /* TODO(mesh): Could we avoid allocating URB for Mesh if rasterization is |