diff options
author | Terje Bergstrom <tbergstrom@nvidia.com> | 2018-08-27 16:58:41 -0400 |
---|---|---|
committer | mobile promotions <svcmobile_promotions@nvidia.com> | 2018-08-30 23:11:49 -0400 |
commit | 9c60230b5723d6a0dbb83bf85d499a671491245f (patch) | |
tree | 9478600a314fa29d41e6a7cfb7b96247231f730b /drivers/gpu/nvgpu | |
parent | 220c10fac4af01cbd54a5afb210c2023ac7ef0ed (diff) |
gpu: nvgpu: Sync kernel headers with generator tool
HW headers in nvgpu have gotten a bit out of date. Regenerate
headers and add the following registers:
* Add PTIMER timeout registers to all chips
* Add PD, SCC, SSYNC and MME interrupt registers to all chips
* Add HWW ESR INFO register to all chips
Change-Id: I34e09371083ac1568666b0cd487a106fad56aa12
Signed-off-by: Terje Bergstrom <tbergstrom@nvidia.com>
Reviewed-on: https://git-master.nvidia.com/r/1807709
Reviewed-by: svc-misra-checker <svc-misra-checker@nvidia.com>
GVS: Gerrit_Virtual_Submit
Reviewed-by: Seshendra Gadagottu <sgadagottu@nvidia.com>
Reviewed-by: mobile promotions <svcmobile_promotions@nvidia.com>
Tested-by: mobile promotions <svcmobile_promotions@nvidia.com>
Diffstat (limited to 'drivers/gpu/nvgpu')
7 files changed, 127 insertions, 7 deletions
diff --git a/drivers/gpu/nvgpu/include/nvgpu/hw/gk20a/hw_timer_gk20a.h b/drivers/gpu/nvgpu/include/nvgpu/hw/gk20a/hw_timer_gk20a.h index f0dbfc30..972d68af 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/hw/gk20a/hw_timer_gk20a.h +++ b/drivers/gpu/nvgpu/include/nvgpu/hw/gk20a/hw_timer_gk20a.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 2013-2017, NVIDIA CORPORATION. All rights reserved. | 2 | * Copyright (c) 2013-2018, NVIDIA CORPORATION. All rights reserved. |
3 | * | 3 | * |
4 | * Permission is hereby granted, free of charge, to any person obtaining a | 4 | * Permission is hereby granted, free of charge, to any person obtaining a |
5 | * copy of this software and associated documentation files (the "Software"), | 5 | * copy of this software and associated documentation files (the "Software"), |
@@ -98,15 +98,15 @@ static inline u32 timer_pri_timeout_save_0_r(void) | |||
98 | } | 98 | } |
99 | static inline u32 timer_pri_timeout_save_0_fecs_tgt_v(u32 r) | 99 | static inline u32 timer_pri_timeout_save_0_fecs_tgt_v(u32 r) |
100 | { | 100 | { |
101 | return (r >> 31) & 0x1; | 101 | return (r >> 31U) & 0x1U; |
102 | } | 102 | } |
103 | static inline u32 timer_pri_timeout_save_0_addr_v(u32 r) | 103 | static inline u32 timer_pri_timeout_save_0_addr_v(u32 r) |
104 | { | 104 | { |
105 | return (r >> 2) & 0x3fffff; | 105 | return (r >> 2U) & 0x3fffffU; |
106 | } | 106 | } |
107 | static inline u32 timer_pri_timeout_save_0_write_v(u32 r) | 107 | static inline u32 timer_pri_timeout_save_0_write_v(u32 r) |
108 | { | 108 | { |
109 | return (r >> 1) & 0x1; | 109 | return (r >> 1U) & 0x1U; |
110 | } | 110 | } |
111 | static inline u32 timer_pri_timeout_save_1_r(void) | 111 | static inline u32 timer_pri_timeout_save_1_r(void) |
112 | { | 112 | { |
diff --git a/drivers/gpu/nvgpu/include/nvgpu/hw/gm20b/hw_gr_gm20b.h b/drivers/gpu/nvgpu/include/nvgpu/hw/gm20b/hw_gr_gm20b.h index 30bce9f9..be05d031 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/hw/gm20b/hw_gr_gm20b.h +++ b/drivers/gpu/nvgpu/include/nvgpu/hw/gm20b/hw_gr_gm20b.h | |||
@@ -184,6 +184,22 @@ static inline u32 gr_exception_sked_m(void) | |||
184 | { | 184 | { |
185 | return 0x1U << 8U; | 185 | return 0x1U << 8U; |
186 | } | 186 | } |
187 | static inline u32 gr_exception_pd_m(void) | ||
188 | { | ||
189 | return 0x1U << 2U; | ||
190 | } | ||
191 | static inline u32 gr_exception_scc_m(void) | ||
192 | { | ||
193 | return 0x1U << 3U; | ||
194 | } | ||
195 | static inline u32 gr_exception_ssync_m(void) | ||
196 | { | ||
197 | return 0x1U << 5U; | ||
198 | } | ||
199 | static inline u32 gr_exception_mme_m(void) | ||
200 | { | ||
201 | return 0x1U << 7U; | ||
202 | } | ||
187 | static inline u32 gr_exception1_r(void) | 203 | static inline u32 gr_exception1_r(void) |
188 | { | 204 | { |
189 | return 0x00400118U; | 205 | return 0x00400118U; |
@@ -544,6 +560,10 @@ static inline u32 gr_fe_hww_esr_en_enable_f(void) | |||
544 | { | 560 | { |
545 | return 0x80000000U; | 561 | return 0x80000000U; |
546 | } | 562 | } |
563 | static inline u32 gr_fe_hww_esr_info_r(void) | ||
564 | { | ||
565 | return 0x004041b0U; | ||
566 | } | ||
547 | static inline u32 gr_fe_go_idle_timeout_r(void) | 567 | static inline u32 gr_fe_go_idle_timeout_r(void) |
548 | { | 568 | { |
549 | return 0x00404154U; | 569 | return 0x00404154U; |
@@ -596,6 +616,10 @@ static inline u32 gr_mme_hww_esr_en_enable_f(void) | |||
596 | { | 616 | { |
597 | return 0x80000000U; | 617 | return 0x80000000U; |
598 | } | 618 | } |
619 | static inline u32 gr_mme_hww_esr_info_r(void) | ||
620 | { | ||
621 | return 0x00404494U; | ||
622 | } | ||
599 | static inline u32 gr_memfmt_hww_esr_r(void) | 623 | static inline u32 gr_memfmt_hww_esr_r(void) |
600 | { | 624 | { |
601 | return 0x00404600U; | 625 | return 0x00404600U; |
diff --git a/drivers/gpu/nvgpu/include/nvgpu/hw/gm20b/hw_timer_gm20b.h b/drivers/gpu/nvgpu/include/nvgpu/hw/gm20b/hw_timer_gm20b.h index 38548645..f4093679 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/hw/gm20b/hw_timer_gm20b.h +++ b/drivers/gpu/nvgpu/include/nvgpu/hw/gm20b/hw_timer_gm20b.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 2016-2017, NVIDIA CORPORATION. All rights reserved. | 2 | * Copyright (c) 2016-2018, NVIDIA CORPORATION. All rights reserved. |
3 | * | 3 | * |
4 | * Permission is hereby granted, free of charge, to any person obtaining a | 4 | * Permission is hereby granted, free of charge, to any person obtaining a |
5 | * copy of this software and associated documentation files (the "Software"), | 5 | * copy of this software and associated documentation files (the "Software"), |
@@ -96,6 +96,18 @@ static inline u32 timer_pri_timeout_save_0_r(void) | |||
96 | { | 96 | { |
97 | return 0x00009084U; | 97 | return 0x00009084U; |
98 | } | 98 | } |
99 | static inline u32 timer_pri_timeout_save_0_fecs_tgt_v(u32 r) | ||
100 | { | ||
101 | return (r >> 31U) & 0x1U; | ||
102 | } | ||
103 | static inline u32 timer_pri_timeout_save_0_addr_v(u32 r) | ||
104 | { | ||
105 | return (r >> 2U) & 0x3fffffU; | ||
106 | } | ||
107 | static inline u32 timer_pri_timeout_save_0_write_v(u32 r) | ||
108 | { | ||
109 | return (r >> 1U) & 0x1U; | ||
110 | } | ||
99 | static inline u32 timer_pri_timeout_save_1_r(void) | 111 | static inline u32 timer_pri_timeout_save_1_r(void) |
100 | { | 112 | { |
101 | return 0x00009088U; | 113 | return 0x00009088U; |
diff --git a/drivers/gpu/nvgpu/include/nvgpu/hw/gp106/hw_gr_gp106.h b/drivers/gpu/nvgpu/include/nvgpu/hw/gp106/hw_gr_gp106.h index 7d3135f9..3ebed7ea 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/hw/gp106/hw_gr_gp106.h +++ b/drivers/gpu/nvgpu/include/nvgpu/hw/gp106/hw_gr_gp106.h | |||
@@ -180,6 +180,26 @@ static inline u32 gr_exception_ds_m(void) | |||
180 | { | 180 | { |
181 | return 0x1U << 4U; | 181 | return 0x1U << 4U; |
182 | } | 182 | } |
183 | static inline u32 gr_exception_sked_m(void) | ||
184 | { | ||
185 | return 0x1U << 8U; | ||
186 | } | ||
187 | static inline u32 gr_exception_pd_m(void) | ||
188 | { | ||
189 | return 0x1U << 2U; | ||
190 | } | ||
191 | static inline u32 gr_exception_scc_m(void) | ||
192 | { | ||
193 | return 0x1U << 3U; | ||
194 | } | ||
195 | static inline u32 gr_exception_ssync_m(void) | ||
196 | { | ||
197 | return 0x1U << 5U; | ||
198 | } | ||
199 | static inline u32 gr_exception_mme_m(void) | ||
200 | { | ||
201 | return 0x1U << 7U; | ||
202 | } | ||
183 | static inline u32 gr_exception1_r(void) | 203 | static inline u32 gr_exception1_r(void) |
184 | { | 204 | { |
185 | return 0x00400118U; | 205 | return 0x00400118U; |
@@ -672,6 +692,10 @@ static inline u32 gr_fe_hww_esr_en_enable_f(void) | |||
672 | { | 692 | { |
673 | return 0x80000000U; | 693 | return 0x80000000U; |
674 | } | 694 | } |
695 | static inline u32 gr_fe_hww_esr_info_r(void) | ||
696 | { | ||
697 | return 0x004041b0U; | ||
698 | } | ||
675 | static inline u32 gr_fe_go_idle_timeout_r(void) | 699 | static inline u32 gr_fe_go_idle_timeout_r(void) |
676 | { | 700 | { |
677 | return 0x00404154U; | 701 | return 0x00404154U; |
@@ -724,6 +748,10 @@ static inline u32 gr_mme_hww_esr_en_enable_f(void) | |||
724 | { | 748 | { |
725 | return 0x80000000U; | 749 | return 0x80000000U; |
726 | } | 750 | } |
751 | static inline u32 gr_mme_hww_esr_info_r(void) | ||
752 | { | ||
753 | return 0x00404494U; | ||
754 | } | ||
727 | static inline u32 gr_memfmt_hww_esr_r(void) | 755 | static inline u32 gr_memfmt_hww_esr_r(void) |
728 | { | 756 | { |
729 | return 0x00404600U; | 757 | return 0x00404600U; |
diff --git a/drivers/gpu/nvgpu/include/nvgpu/hw/gp106/hw_ram_gp106.h b/drivers/gpu/nvgpu/include/nvgpu/hw/gp106/hw_ram_gp106.h index 3ae3f3bb..1de8aa21 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/hw/gp106/hw_ram_gp106.h +++ b/drivers/gpu/nvgpu/include/nvgpu/hw/gp106/hw_ram_gp106.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 2016-2017, NVIDIA CORPORATION. All rights reserved. | 2 | * Copyright (c) 2016-2018, NVIDIA CORPORATION. All rights reserved. |
3 | * | 3 | * |
4 | * Permission is hereby granted, free of charge, to any person obtaining a | 4 | * Permission is hereby granted, free of charge, to any person obtaining a |
5 | * copy of this software and associated documentation files (the "Software"), | 5 | * copy of this software and associated documentation files (the "Software"), |
@@ -124,6 +124,26 @@ static inline u32 ram_in_page_dir_base_fault_replay_gcc_true_f(void) | |||
124 | { | 124 | { |
125 | return 0x20U; | 125 | return 0x20U; |
126 | } | 126 | } |
127 | static inline u32 ram_in_use_ver2_pt_format_f(u32 v) | ||
128 | { | ||
129 | return (v & 0x1U) << 10U; | ||
130 | } | ||
131 | static inline u32 ram_in_use_ver2_pt_format_m(void) | ||
132 | { | ||
133 | return 0x1U << 10U; | ||
134 | } | ||
135 | static inline u32 ram_in_use_ver2_pt_format_w(void) | ||
136 | { | ||
137 | return 128U; | ||
138 | } | ||
139 | static inline u32 ram_in_use_ver2_pt_format_true_f(void) | ||
140 | { | ||
141 | return 0x400U; | ||
142 | } | ||
143 | static inline u32 ram_in_use_ver2_pt_format_false_f(void) | ||
144 | { | ||
145 | return 0x0U; | ||
146 | } | ||
127 | static inline u32 ram_in_big_page_size_f(u32 v) | 147 | static inline u32 ram_in_big_page_size_f(u32 v) |
128 | { | 148 | { |
129 | return (v & 0x1U) << 11U; | 149 | return (v & 0x1U) << 11U; |
diff --git a/drivers/gpu/nvgpu/include/nvgpu/hw/gp10b/hw_gr_gp10b.h b/drivers/gpu/nvgpu/include/nvgpu/hw/gp10b/hw_gr_gp10b.h index 4ae70aab..efd8b555 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/hw/gp10b/hw_gr_gp10b.h +++ b/drivers/gpu/nvgpu/include/nvgpu/hw/gp10b/hw_gr_gp10b.h | |||
@@ -184,6 +184,22 @@ static inline u32 gr_exception_sked_m(void) | |||
184 | { | 184 | { |
185 | return 0x1U << 8U; | 185 | return 0x1U << 8U; |
186 | } | 186 | } |
187 | static inline u32 gr_exception_pd_m(void) | ||
188 | { | ||
189 | return 0x1U << 2U; | ||
190 | } | ||
191 | static inline u32 gr_exception_scc_m(void) | ||
192 | { | ||
193 | return 0x1U << 3U; | ||
194 | } | ||
195 | static inline u32 gr_exception_ssync_m(void) | ||
196 | { | ||
197 | return 0x1U << 5U; | ||
198 | } | ||
199 | static inline u32 gr_exception_mme_m(void) | ||
200 | { | ||
201 | return 0x1U << 7U; | ||
202 | } | ||
187 | static inline u32 gr_exception1_r(void) | 203 | static inline u32 gr_exception1_r(void) |
188 | { | 204 | { |
189 | return 0x00400118U; | 205 | return 0x00400118U; |
@@ -724,6 +740,10 @@ static inline u32 gr_fe_hww_esr_en_enable_f(void) | |||
724 | { | 740 | { |
725 | return 0x80000000U; | 741 | return 0x80000000U; |
726 | } | 742 | } |
743 | static inline u32 gr_fe_hww_esr_info_r(void) | ||
744 | { | ||
745 | return 0x004041b0U; | ||
746 | } | ||
727 | static inline u32 gr_fe_go_idle_timeout_r(void) | 747 | static inline u32 gr_fe_go_idle_timeout_r(void) |
728 | { | 748 | { |
729 | return 0x00404154U; | 749 | return 0x00404154U; |
@@ -776,6 +796,10 @@ static inline u32 gr_mme_hww_esr_en_enable_f(void) | |||
776 | { | 796 | { |
777 | return 0x80000000U; | 797 | return 0x80000000U; |
778 | } | 798 | } |
799 | static inline u32 gr_mme_hww_esr_info_r(void) | ||
800 | { | ||
801 | return 0x00404494U; | ||
802 | } | ||
779 | static inline u32 gr_memfmt_hww_esr_r(void) | 803 | static inline u32 gr_memfmt_hww_esr_r(void) |
780 | { | 804 | { |
781 | return 0x00404600U; | 805 | return 0x00404600U; |
diff --git a/drivers/gpu/nvgpu/include/nvgpu/hw/gp10b/hw_timer_gp10b.h b/drivers/gpu/nvgpu/include/nvgpu/hw/gp10b/hw_timer_gp10b.h index db752648..54facfc4 100644 --- a/drivers/gpu/nvgpu/include/nvgpu/hw/gp10b/hw_timer_gp10b.h +++ b/drivers/gpu/nvgpu/include/nvgpu/hw/gp10b/hw_timer_gp10b.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * Copyright (c) 2014-2017, NVIDIA CORPORATION. All rights reserved. | 2 | * Copyright (c) 2014-2018, NVIDIA CORPORATION. All rights reserved. |
3 | * | 3 | * |
4 | * Permission is hereby granted, free of charge, to any person obtaining a | 4 | * Permission is hereby granted, free of charge, to any person obtaining a |
5 | * copy of this software and associated documentation files (the "Software"), | 5 | * copy of this software and associated documentation files (the "Software"), |
@@ -96,6 +96,18 @@ static inline u32 timer_pri_timeout_save_0_r(void) | |||
96 | { | 96 | { |
97 | return 0x00009084U; | 97 | return 0x00009084U; |
98 | } | 98 | } |
99 | static inline u32 timer_pri_timeout_save_0_fecs_tgt_v(u32 r) | ||
100 | { | ||
101 | return (r >> 31U) & 0x1U; | ||
102 | } | ||
103 | static inline u32 timer_pri_timeout_save_0_addr_v(u32 r) | ||
104 | { | ||
105 | return (r >> 2U) & 0x3fffffU; | ||
106 | } | ||
107 | static inline u32 timer_pri_timeout_save_0_write_v(u32 r) | ||
108 | { | ||
109 | return (r >> 1U) & 0x1U; | ||
110 | } | ||
99 | static inline u32 timer_pri_timeout_save_1_r(void) | 111 | static inline u32 timer_pri_timeout_save_1_r(void) |
100 | { | 112 | { |
101 | return 0x00009088U; | 113 | return 0x00009088U; |