mirror of
git://nv-tegra.nvidia.com/linux-nvgpu.git
synced 2025-12-23 09:57:08 +03:00
Reduce the priv cmdbuf allocation size to match the actual space needed in the worst case when num_in_flight is not specified. Although synchronization may indeed take up to 2/3 of the gpfifo entries, the number of jobs is what matters and it will be the remaining 1/3. Each job uses up at most one wait and incr command from the pre and post fences, so half of the 2/3 will be only wait commands and the other half will be only incr commands. Jira NVGPU-4548 Change-Id: Ib3566a76b97d8f65538d961efb97408ef23ec281 Signed-off-by: Konsta Hölttä <kholtta@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2325233 (cherry picked from commit 515deae4f58fedc7d004988f0f85470a7a894ddf) Reviewed-on: https://git-master.nvidia.com/r/c/linux-nvgpu/+/2328413 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>