mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-23 09:57:08 +03:00
The semaphore wait and incr sizes are not 8 and 10 for gv11b onwards. Use the specific HAL API to retrieve their sizes and compute the priv cmdbuf queue based on them instead of the up-to-gp10b values. We haven't run out of space likely for several reasons: 1) userspace may not need both pre and post fences for absolutely each submitted job 2) submitted jobs may consist of more than one gpfifo entry, reducing the relative required sync capacity 3) the queue size is rounded up to the next power of two which leaves some margin for error in this calculation 4) the gpfifo size based num-in-flight guess has been twice as big as it needs to be (fixed in a next patch) Jira NVGPU-4548 Change-Id: I172b5c0d8bb7d2231cc45cbed5e1e8b60ce7c707 Signed-off-by: Konsta Hölttä <kholtta@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2323148 (cherry picked from commit 03fb194d105242c3eb20a9857a22743f5f64b9b9) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2328412 Reviewed-by: automaticguardword <automaticguardword@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Alex Waterman <alexw@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> GVS: Gerrit_Virtual_Submit Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>