From a30924340f879db1f2857e066b919eeecf03c693 Mon Sep 17 00:00:00 2001 From: Terje Bergstrom Date: Fri, 14 Apr 2017 15:54:49 -0700 Subject: gpu: nvgpu: Add new flag support_pmu to gk20a Add new flag support_pmu to struct gk20a at probe time, and access it from gk20a instead of support_gk20a_pmu() which depends on struct device *. JIRA NVGPU-16 Change-Id: I721f1a532e949c98346086abdc2630a8df6eba7b Signed-off-by: Terje Bergstrom Reviewed-on: http://git-master/r/1463546 Reviewed-by: mobile promotions Tested-by: mobile promotions --- drivers/gpu/nvgpu/gk20a/gr_gk20a.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'drivers/gpu/nvgpu/gk20a/gr_gk20a.c') diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c index 57cd266d..ac03c1e5 100644 --- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c +++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c @@ -3231,7 +3231,7 @@ int gk20a_alloc_obj_ctx(struct channel_gk20a *c, u32 lockboost_mask; u32 lockboost; - if (support_gk20a_pmu(g->dev)) { + if (g->support_pmu) { err = gk20a_pmu_disable_elpg(g); if (err) { nvgpu_err(g, @@ -3281,7 +3281,7 @@ int gk20a_alloc_obj_ctx(struct channel_gk20a *c, args->flags |= NVGPU_ALLOC_OBJ_FLAGS_LOCKBOOST_ZERO; - if (support_gk20a_pmu(g->dev)) + if (g->support_pmu) gk20a_pmu_enable_elpg(g); } -- cgit v1.2.2