diff options
author | Terje Bergstrom <tbergstrom@nvidia.com> | 2014-10-27 05:06:59 -0400 |
---|---|---|
committer | Dan Willemsen <dwillemsen@nvidia.com> | 2015-03-18 15:11:54 -0400 |
commit | 2d5ff668cbc6a932df2c9cf79627d1d340e5c2c0 (patch) | |
tree | 1d9bc4b774a9c2cea339891eaef3af5b87ee354d /drivers/gpu/nvgpu/vgpu/ltc_vgpu.c | |
parent | 23a182aaa61d120c965f1bce09609cc14d4e14eb (diff) |
gpu: nvgpu: GR and LTC HAL to use const structs
Convert GR and LTC HALs to use const structs, and initialize them
with macros.
Bug 1567274
Change-Id: Ia3f24a5eccb27578d9cba69755f636818d11275c
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/590371
Diffstat (limited to 'drivers/gpu/nvgpu/vgpu/ltc_vgpu.c')
-rw-r--r-- | drivers/gpu/nvgpu/vgpu/ltc_vgpu.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/drivers/gpu/nvgpu/vgpu/ltc_vgpu.c b/drivers/gpu/nvgpu/vgpu/ltc_vgpu.c index ddff23b7..0a7d19c4 100644 --- a/drivers/gpu/nvgpu/vgpu/ltc_vgpu.c +++ b/drivers/gpu/nvgpu/vgpu/ltc_vgpu.c | |||
@@ -48,8 +48,12 @@ static int vgpu_ltc_init_comptags(struct gk20a *g, struct gr_gk20a *gr) | |||
48 | return 0; | 48 | return 0; |
49 | } | 49 | } |
50 | 50 | ||
51 | static const struct gpu_ltc_ops vgpu_ltc_ops = { | ||
52 | .determine_L2_size_bytes = vgpu_determine_L2_size_bytes, | ||
53 | .init_comptags = vgpu_ltc_init_comptags, | ||
54 | }; | ||
55 | |||
51 | void vgpu_init_ltc_ops(struct gpu_ops *gops) | 56 | void vgpu_init_ltc_ops(struct gpu_ops *gops) |
52 | { | 57 | { |
53 | gops->ltc.determine_L2_size_bytes = vgpu_determine_L2_size_bytes; | 58 | gops->ltc = &vgpu_ltc_ops; |
54 | gops->ltc.init_comptags = vgpu_ltc_init_comptags; | ||
55 | } | 59 | } |