summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gv100/hal_gv100.c
diff options
context:
space:
mode:
authorTerje Bergstrom <tbergstrom@nvidia.com>2018-05-24 18:25:41 -0400
committerTejal Kudav <tkudav@nvidia.com>2018-06-14 09:44:07 -0400
commitd71d38087ded679f60714dae3a859523a19df04f (patch)
tree61439d294705ef91ce08ae4c02d4921eec943283 /drivers/gpu/nvgpu/gv100/hal_gv100.c
parent5215d65c25b5e76c19d9d12b03c52f69e2d40227 (diff)
gpu: nvgpu: Separate timer from bus
Code touching timer registers was combined with bus code. They're two logically separate register spaces, so separate the code accordingly. JIRA NVGPU-588 Change-Id: I40e2925ff156669f41ddc1f2e7714f92a2da367b Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com> Reviewed-on: https://git-master.nvidia.com/r/1730893 Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com> Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gv100/hal_gv100.c')
-rw-r--r--drivers/gpu/nvgpu/gv100/hal_gv100.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/drivers/gpu/nvgpu/gv100/hal_gv100.c b/drivers/gpu/nvgpu/gv100/hal_gv100.c
index ac68bff3..dd3a5398 100644
--- a/drivers/gpu/nvgpu/gv100/hal_gv100.c
+++ b/drivers/gpu/nvgpu/gv100/hal_gv100.c
@@ -24,6 +24,7 @@
24 24
25#include "common/bus/bus_gk20a.h" 25#include "common/bus/bus_gk20a.h"
26#include "common/clock_gating/gv100_gating_reglist.h" 26#include "common/clock_gating/gv100_gating_reglist.h"
27#include "common/ptimer/ptimer_gk20a.h"
27 28
28#include "gk20a/gk20a.h" 29#include "gk20a/gk20a.h"
29#include "gk20a/fifo_gk20a.h" 30#include "gk20a/fifo_gk20a.h"
@@ -99,7 +100,7 @@
99#include "gv100/nvlink_gv100.h" 100#include "gv100/nvlink_gv100.h"
100#include "gv100/regops_gv100.h" 101#include "gv100/regops_gv100.h"
101 102
102#include <nvgpu/bus.h> 103#include <nvgpu/ptimer.h>
103#include <nvgpu/debug.h> 104#include <nvgpu/debug.h>
104#include <nvgpu/enabled.h> 105#include <nvgpu/enabled.h>
105#include <nvgpu/ctxsw_trace.h> 106#include <nvgpu/ctxsw_trace.h>
@@ -790,11 +791,14 @@ static const struct gpu_ops gv100_ops = {
790 .bus = { 791 .bus = {
791 .init_hw = gk20a_bus_init_hw, 792 .init_hw = gk20a_bus_init_hw,
792 .isr = gk20a_bus_isr, 793 .isr = gk20a_bus_isr,
793 .read_ptimer = gk20a_read_ptimer,
794 .get_timestamps_zipper = nvgpu_get_timestamps_zipper,
795 .bar1_bind = NULL, 794 .bar1_bind = NULL,
796 .set_bar0_window = gk20a_bus_set_bar0_window, 795 .set_bar0_window = gk20a_bus_set_bar0_window,
797 }, 796 },
797 .ptimer = {
798 .isr = gk20a_ptimer_isr,
799 .read_ptimer = gk20a_read_ptimer,
800 .get_timestamps_zipper = nvgpu_get_timestamps_zipper,
801 },
798#if defined(CONFIG_GK20A_CYCLE_STATS) 802#if defined(CONFIG_GK20A_CYCLE_STATS)
799 .css = { 803 .css = {
800 .enable_snapshot = gv11b_css_hw_enable_snapshot, 804 .enable_snapshot = gv11b_css_hw_enable_snapshot,
@@ -878,6 +882,7 @@ int gv100_init_hal(struct gk20a *g)
878 gops->debugger = gv100_ops.debugger; 882 gops->debugger = gv100_ops.debugger;
879 gops->dbg_session_ops = gv100_ops.dbg_session_ops; 883 gops->dbg_session_ops = gv100_ops.dbg_session_ops;
880 gops->bus = gv100_ops.bus; 884 gops->bus = gv100_ops.bus;
885 gops->ptimer = gv100_ops.ptimer;
881#if defined(CONFIG_GK20A_CYCLE_STATS) 886#if defined(CONFIG_GK20A_CYCLE_STATS)
882 gops->css = gv100_ops.css; 887 gops->css = gv100_ops.css;
883#endif 888#endif