summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/gk20a.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gk20a.h')
-rw-r--r--drivers/gpu/nvgpu/gk20a/gk20a.h14
1 files changed, 8 insertions, 6 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.h b/drivers/gpu/nvgpu/gk20a/gk20a.h
index 38322c87..979b4cb0 100644
--- a/drivers/gpu/nvgpu/gk20a/gk20a.h
+++ b/drivers/gpu/nvgpu/gk20a/gk20a.h
@@ -687,14 +687,16 @@ enum {
687 KEPLER_DMA_COPY_A = 0xA0B5, /*not sure about this one*/ 687 KEPLER_DMA_COPY_A = 0xA0B5, /*not sure about this one*/
688}; 688};
689 689
690#if defined(CONFIG_GK20A_PMU) 690static inline int support_gk20a_pmu(struct platform_device *dev)
691static inline int support_gk20a_pmu(void)
692{ 691{
693 return 1; 692 if (IS_ENABLED(CONFIG_GK20A_PMU)) {
693 struct gk20a_platform *platform = gk20a_get_platform(dev);
694
695 /* we have not supported GPU PMU for virtualization now */
696 return !platform->virtual_dev;
697 } else
698 return 0;
694} 699}
695#else
696static inline int support_gk20a_pmu(void){return 0;}
697#endif
698 700
699void gk20a_create_sysfs(struct platform_device *dev); 701void gk20a_create_sysfs(struct platform_device *dev);
700 702