summaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorDeepak Nibade <dnibade@nvidia.com>2015-10-29 05:50:50 -0400
committerTerje Bergstrom <tbergstrom@nvidia.com>2015-11-23 11:32:39 -0500
commitf50d0ffb15aef2cbf419b81cdbc3031097767bff (patch)
treee1a6b25699c735864c6048dd72568d2435e50f51 /include
parent67fe5f6d738a9b1ba2d8f5dd0726790d965c8883 (diff)
gpu: nvgpu: support skipping buffer refcounting in submit
In job submission path, we always take refcount on all the mapped buffers to safeguard against case where user space releases the buffer early But in case user space itself is doing proper buffer management, kernel need not take refcounts on all the buffers - which is also a overhead in submit path Hence, provide a new submit flag NVGPU_SUBMIT_GPFIFO_FLAGS_SKIP_BUFFER_REFCOUNTING to optionally skip taking refcounts on all the buffers Also, if we do not take refcounts, then no need to drop any refcounts in gk20a_channel_update() as well Bug 1698667 Bug 200141116 Change-Id: I81bb7a03240300b691c70bcec04ea1badd5934f4 Signed-off-by: Deepak Nibade <dnibade@nvidia.com> Reviewed-on: http://git-master/r/824718 (cherry picked from commit 8c8978fa303ec4e6db0233becdbdcbad4a248173) Reviewed-on: http://git-master/r/835801 Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com> Tested-by: Terje Bergstrom <tbergstrom@nvidia.com>
Diffstat (limited to 'include')
-rw-r--r--include/uapi/linux/nvgpu.h2
1 files changed, 2 insertions, 0 deletions
diff --git a/include/uapi/linux/nvgpu.h b/include/uapi/linux/nvgpu.h
index d2b5ceb8..025f2c9b 100644
--- a/include/uapi/linux/nvgpu.h
+++ b/include/uapi/linux/nvgpu.h
@@ -669,6 +669,8 @@ struct nvgpu_fence {
669#define NVGPU_SUBMIT_GPFIFO_FLAGS_SYNC_FENCE (1 << 3) 669#define NVGPU_SUBMIT_GPFIFO_FLAGS_SYNC_FENCE (1 << 3)
670/* suppress WFI before fence trigger */ 670/* suppress WFI before fence trigger */
671#define NVGPU_SUBMIT_GPFIFO_FLAGS_SUPPRESS_WFI (1 << 4) 671#define NVGPU_SUBMIT_GPFIFO_FLAGS_SUPPRESS_WFI (1 << 4)
672/* skip buffer refcounting during submit */
673#define NVGPU_SUBMIT_GPFIFO_FLAGS_SKIP_BUFFER_REFCOUNTING (1 << 5)
672 674
673struct nvgpu_submit_gpfifo_args { 675struct nvgpu_submit_gpfifo_args {
674 __u64 gpfifo; 676 __u64 gpfifo;