From d71d38087ded679f60714dae3a859523a19df04f Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Thu, 24 May 2018 15:25:41 -0700 Subject: 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 Reviewed-on: https://git-master.nvidia.com/r/1730893 Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/gv100/hal_gv100.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'drivers/gpu/nvgpu/gv100/hal_gv100.c') 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 @@ #include "common/bus/bus_gk20a.h" #include "common/clock_gating/gv100_gating_reglist.h" +#include "common/ptimer/ptimer_gk20a.h" #include "gk20a/gk20a.h" #include "gk20a/fifo_gk20a.h" @@ -99,7 +100,7 @@ #include "gv100/nvlink_gv100.h" #include "gv100/regops_gv100.h" -#include +#include #include #include #include @@ -790,11 +791,14 @@ static const struct gpu_ops gv100_ops = { .bus = { .init_hw = gk20a_bus_init_hw, .isr = gk20a_bus_isr, - .read_ptimer = gk20a_read_ptimer, - .get_timestamps_zipper = nvgpu_get_timestamps_zipper, .bar1_bind = NULL, .set_bar0_window = gk20a_bus_set_bar0_window, }, + .ptimer = { + .isr = gk20a_ptimer_isr, + .read_ptimer = gk20a_read_ptimer, + .get_timestamps_zipper = nvgpu_get_timestamps_zipper, + }, #if defined(CONFIG_GK20A_CYCLE_STATS) .css = { .enable_snapshot = gv11b_css_hw_enable_snapshot, @@ -878,6 +882,7 @@ int gv100_init_hal(struct gk20a *g) gops->debugger = gv100_ops.debugger; gops->dbg_session_ops = gv100_ops.dbg_session_ops; gops->bus = gv100_ops.bus; + gops->ptimer = gv100_ops.ptimer; #if defined(CONFIG_GK20A_CYCLE_STATS) gops->css = gv100_ops.css; #endif -- cgit v1.2.2