diff options
author | Terje Bergstrom <tbergstrom@nvidia.com> | 2017-03-17 14:09:44 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2017-03-23 11:44:07 -0400 |
commit | 4492c62ffe9398bd4457f6f1c2773e40afe909fb (patch) | |
tree | 5d792f81d97844278f4eca665a8b4778fa93dc35 /drivers/gpu/nvgpu/gk20a/gk20a.h | |
parent | 33f637585ecd617a9f4423f56e2aa6df0691ac64 (diff) |
gpu: nvgpu: Add bus HAL
Add bus HAL and move all bus related hardware sequencing to that file:
BAR1 binding, timer access, and interrupt handling.
Change-Id: Ibc5f5797dc338de10749b446a7bdbcae600fecb4
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: http://git-master/r/1323353
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gk20a.h')
-rw-r--r-- | drivers/gpu/nvgpu/gk20a/gk20a.h | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gk20a.h b/drivers/gpu/nvgpu/gk20a/gk20a.h index 7c836b3c..8d03cc9a 100644 --- a/drivers/gpu/nvgpu/gk20a/gk20a.h +++ b/drivers/gpu/nvgpu/gk20a/gk20a.h | |||
@@ -629,7 +629,6 @@ struct gpu_ops { | |||
629 | struct vm_gk20a *vm); | 629 | struct vm_gk20a *vm); |
630 | u64 (*get_iova_addr)(struct gk20a *g, struct scatterlist *sgl, | 630 | u64 (*get_iova_addr)(struct gk20a *g, struct scatterlist *sgl, |
631 | u32 flags); | 631 | u32 flags); |
632 | int (*bar1_bind)(struct gk20a *g, struct mem_desc *bar1_inst); | ||
633 | size_t (*get_vidmem_size)(struct gk20a *g); | 632 | size_t (*get_vidmem_size)(struct gk20a *g); |
634 | void (*init_inst_block)(struct mem_desc *inst_block, | 633 | void (*init_inst_block)(struct mem_desc *inst_block, |
635 | struct vm_gk20a *vm, u32 big_page_size); | 634 | struct vm_gk20a *vm, u32 big_page_size); |
@@ -773,7 +772,13 @@ struct gpu_ops { | |||
773 | 772 | ||
774 | int (*get_litter_value)(struct gk20a *g, int value); | 773 | int (*get_litter_value)(struct gk20a *g, int value); |
775 | int (*chip_init_gpu_characteristics)(struct gk20a *g); | 774 | int (*chip_init_gpu_characteristics)(struct gk20a *g); |
776 | int (*read_ptimer)(struct gk20a *g, u64 *value); | 775 | |
776 | struct { | ||
777 | void (*init_hw)(struct gk20a *g); | ||
778 | void (*isr)(struct gk20a *g); | ||
779 | int (*read_ptimer)(struct gk20a *g, u64 *value); | ||
780 | int (*bar1_bind)(struct gk20a *g, struct mem_desc *bar1_inst); | ||
781 | } bus; | ||
777 | 782 | ||
778 | int (*bios_init)(struct gk20a *g); | 783 | int (*bios_init)(struct gk20a *g); |
779 | 784 | ||
@@ -1417,8 +1422,6 @@ int gk20a_wait_for_idle(struct device *dev); | |||
1417 | 1422 | ||
1418 | int gk20a_init_gpu_characteristics(struct gk20a *g); | 1423 | int gk20a_init_gpu_characteristics(struct gk20a *g); |
1419 | 1424 | ||
1420 | void gk20a_pbus_isr(struct gk20a *g); | ||
1421 | |||
1422 | int gk20a_user_init(struct device *dev, const char *interface_name, | 1425 | int gk20a_user_init(struct device *dev, const char *interface_name, |
1423 | struct class *class); | 1426 | struct class *class); |
1424 | void gk20a_user_deinit(struct device *dev, struct class *class); | 1427 | void gk20a_user_deinit(struct device *dev, struct class *class); |
@@ -1435,7 +1438,6 @@ static inline u32 scale_ptimer(u32 timeout , u32 scale10x) | |||
1435 | return (timeout * 10) / scale10x; | 1438 | return (timeout * 10) / scale10x; |
1436 | } | 1439 | } |
1437 | 1440 | ||
1438 | int gk20a_read_ptimer(struct gk20a *g, u64 *value); | ||
1439 | extern struct class nvgpu_class; | 1441 | extern struct class nvgpu_class; |
1440 | 1442 | ||
1441 | #define INTERFACE_NAME "nvhost%s-gpu" | 1443 | #define INTERFACE_NAME "nvhost%s-gpu" |