summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/include
diff options
context:
space:
mode:
authorSourab Gupta <sourabg@nvidia.com>2018-05-06 23:57:30 -0400
committermobile promotions <svcmobile_promotions@nvidia.com>2018-05-18 02:34:55 -0400
commit85d7b3c5cc2e081c8bc81f43cef08738a254fc32 (patch)
tree77fd23c1028f4a6a32fe1d9cf94e8376227cd45c /drivers/gpu/nvgpu/include
parent9352136ad34a1c2a485bea0185d34689d0ae4525 (diff)
gpu: nvgpu: handle clk arb event posting in OS specific code
The mechanism of posting events to userspace is OS specific. In linux this works through poll fd, wherein we can make use of nvgpu_cond variables to poll and trigger the corresponding wait_queue. The post event functionality on QNX doesn't work on poll though. It uses iofunc_notify_trigger to post the events to the calling process. As such QNX can't work with nvgpu_cond's. To overcome this issue, it is proposed to create OS specific interface function for posting clk arb events. Linux can call nvgpu_cond based implementation, which makes sense since these are already initialized and poll'ed in Linux specific code only. QNX can implement this interface to call iofunc_notify_* functions, as per its need. Jira VQRM-3741 Change-Id: I7d9f71dae2ae7f6a09cd56662003fd1b7e50324c Signed-off-by: Sourab Gupta <sourabg@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1709656 GVS: Gerrit_Virtual_Submit Reviewed-by: Alex Waterman <alexw@nvidia.com> Reviewed-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/include')
-rw-r--r--drivers/gpu/nvgpu/include/nvgpu/clk_arb.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/include/nvgpu/clk_arb.h b/drivers/gpu/nvgpu/include/nvgpu/clk_arb.h
index e91a0dad..0c9bbe06 100644
--- a/drivers/gpu/nvgpu/include/nvgpu/clk_arb.h
+++ b/drivers/gpu/nvgpu/include/nvgpu/clk_arb.h
@@ -349,6 +349,9 @@ int nvgpu_clk_notification_queue_alloc(struct gk20a *g,
349 349
350void nvgpu_clk_notification_queue_free(struct gk20a *g, 350void nvgpu_clk_notification_queue_free(struct gk20a *g,
351 struct nvgpu_clk_notification_queue *queue); 351 struct nvgpu_clk_notification_queue *queue);
352
353void nvgpu_clk_arb_event_post_event(struct nvgpu_clk_dev *dev);
354
352#ifdef CONFIG_DEBUG_FS 355#ifdef CONFIG_DEBUG_FS
353int nvgpu_clk_arb_debugfs_init(struct gk20a *g); 356int nvgpu_clk_arb_debugfs_init(struct gk20a *g);
354#endif 357#endif