1
2
3
4#ifndef __PANFROST_ISSUES_H__
5#define __PANFROST_ISSUES_H__
6
7#include <linux/bitops.h>
8
9#include "panfrost_device.h"
10
11
12
13
14
15enum panfrost_hw_issue {
16
17
18 HW_ISSUE_6367,
19
20
21 HW_ISSUE_6787,
22
23
24
25 HW_ISSUE_8186,
26
27
28 HW_ISSUE_8245,
29
30
31
32
33 HW_ISSUE_8316,
34
35
36
37 HW_ISSUE_8394,
38
39
40
41 HW_ISSUE_8401,
42
43
44
45 HW_ISSUE_8408,
46
47
48 HW_ISSUE_8443,
49
50
51 HW_ISSUE_8987,
52
53
54
55 HW_ISSUE_9435,
56
57
58 HW_ISSUE_9510,
59
60
61
62 HW_ISSUE_9630,
63
64
65
66 HW_ISSUE_10327,
67
68
69 HW_ISSUE_10649,
70
71
72 HW_ISSUE_10676,
73
74
75 HW_ISSUE_10797,
76
77
78 HW_ISSUE_10817,
79
80
81 HW_ISSUE_10883,
82
83
84
85 HW_ISSUE_10959,
86
87
88
89 HW_ISSUE_10969,
90
91
92 HW_ISSUE_11020,
93
94
95 HW_ISSUE_11024,
96
97
98 HW_ISSUE_11035,
99
100
101 HW_ISSUE_11056,
102
103
104
105
106 HW_ISSUE_T76X_3542,
107
108
109 HW_ISSUE_T76X_3953,
110
111
112
113
114
115 HW_ISSUE_TMIX_8463,
116
117
118 GPUCORE_1619,
119
120
121
122 HW_ISSUE_TMIX_8438,
123
124
125
126 HW_ISSUE_TGOX_R1_1234,
127
128 HW_ISSUE_END
129};
130
131#define hw_issues_all (\
132 BIT_ULL(HW_ISSUE_9435))
133
134#define hw_issues_t600 (\
135 BIT_ULL(HW_ISSUE_6367) | \
136 BIT_ULL(HW_ISSUE_6787) | \
137 BIT_ULL(HW_ISSUE_8408) | \
138 BIT_ULL(HW_ISSUE_9510) | \
139 BIT_ULL(HW_ISSUE_10649) | \
140 BIT_ULL(HW_ISSUE_10676) | \
141 BIT_ULL(HW_ISSUE_10883) | \
142 BIT_ULL(HW_ISSUE_11020) | \
143 BIT_ULL(HW_ISSUE_11035) | \
144 BIT_ULL(HW_ISSUE_11056) | \
145 BIT_ULL(HW_ISSUE_TMIX_8438))
146
147#define hw_issues_t600_r0p0_15dev0 (\
148 BIT_ULL(HW_ISSUE_8186) | \
149 BIT_ULL(HW_ISSUE_8245) | \
150 BIT_ULL(HW_ISSUE_8316) | \
151 BIT_ULL(HW_ISSUE_8394) | \
152 BIT_ULL(HW_ISSUE_8401) | \
153 BIT_ULL(HW_ISSUE_8443) | \
154 BIT_ULL(HW_ISSUE_8987) | \
155 BIT_ULL(HW_ISSUE_9630) | \
156 BIT_ULL(HW_ISSUE_10969) | \
157 BIT_ULL(GPUCORE_1619))
158
159#define hw_issues_t620 (\
160 BIT_ULL(HW_ISSUE_10649) | \
161 BIT_ULL(HW_ISSUE_10883) | \
162 BIT_ULL(HW_ISSUE_10959) | \
163 BIT_ULL(HW_ISSUE_11056) | \
164 BIT_ULL(HW_ISSUE_TMIX_8438))
165
166#define hw_issues_t620_r0p1 (\
167 BIT_ULL(HW_ISSUE_10327) | \
168 BIT_ULL(HW_ISSUE_10676) | \
169 BIT_ULL(HW_ISSUE_10817) | \
170 BIT_ULL(HW_ISSUE_11020) | \
171 BIT_ULL(HW_ISSUE_11024) | \
172 BIT_ULL(HW_ISSUE_11035))
173
174#define hw_issues_t620_r1p0 (\
175 BIT_ULL(HW_ISSUE_11020) | \
176 BIT_ULL(HW_ISSUE_11024))
177
178#define hw_issues_t720 (\
179 BIT_ULL(HW_ISSUE_10649) | \
180 BIT_ULL(HW_ISSUE_10797) | \
181 BIT_ULL(HW_ISSUE_10883) | \
182 BIT_ULL(HW_ISSUE_11056) | \
183 BIT_ULL(HW_ISSUE_TMIX_8438))
184
185#define hw_issues_t760 (\
186 BIT_ULL(HW_ISSUE_10883) | \
187 BIT_ULL(HW_ISSUE_T76X_3953) | \
188 BIT_ULL(HW_ISSUE_TMIX_8438))
189
190#define hw_issues_t760_r0p0 (\
191 BIT_ULL(HW_ISSUE_11020) | \
192 BIT_ULL(HW_ISSUE_11024) | \
193 BIT_ULL(HW_ISSUE_T76X_3542))
194
195#define hw_issues_t760_r0p1 (\
196 BIT_ULL(HW_ISSUE_11020) | \
197 BIT_ULL(HW_ISSUE_11024) | \
198 BIT_ULL(HW_ISSUE_T76X_3542))
199
200#define hw_issues_t760_r0p1_50rel0 (\
201 BIT_ULL(HW_ISSUE_T76X_3542))
202
203#define hw_issues_t760_r0p2 (\
204 BIT_ULL(HW_ISSUE_11020) | \
205 BIT_ULL(HW_ISSUE_11024) | \
206 BIT_ULL(HW_ISSUE_T76X_3542))
207
208#define hw_issues_t760_r0p3 (\
209 BIT_ULL(HW_ISSUE_T76X_3542))
210
211#define hw_issues_t820 (\
212 BIT_ULL(HW_ISSUE_10883) | \
213 BIT_ULL(HW_ISSUE_T76X_3953) | \
214 BIT_ULL(HW_ISSUE_TMIX_8438))
215
216#define hw_issues_t830 (\
217 BIT_ULL(HW_ISSUE_10883) | \
218 BIT_ULL(HW_ISSUE_T76X_3953) | \
219 BIT_ULL(HW_ISSUE_TMIX_8438))
220
221#define hw_issues_t860 (\
222 BIT_ULL(HW_ISSUE_10883) | \
223 BIT_ULL(HW_ISSUE_T76X_3953) | \
224 BIT_ULL(HW_ISSUE_TMIX_8438))
225
226#define hw_issues_t880 (\
227 BIT_ULL(HW_ISSUE_10883) | \
228 BIT_ULL(HW_ISSUE_T76X_3953) | \
229 BIT_ULL(HW_ISSUE_TMIX_8438))
230
231#define hw_issues_g31 0
232
233#define hw_issues_g31_r1p0 (\
234 BIT_ULL(HW_ISSUE_TGOX_R1_1234))
235
236#define hw_issues_g51 0
237
238#define hw_issues_g52 0
239
240#define hw_issues_g71 (\
241 BIT_ULL(HW_ISSUE_TMIX_8463) | \
242 BIT_ULL(HW_ISSUE_TMIX_8438))
243
244#define hw_issues_g71_r0p0_05dev0 (\
245 BIT_ULL(HW_ISSUE_T76X_3953))
246
247#define hw_issues_g72 0
248
249#define hw_issues_g76 0
250
251static inline bool panfrost_has_hw_issue(struct panfrost_device *pfdev,
252 enum panfrost_hw_issue issue)
253{
254 return test_bit(issue, pfdev->features.hw_issues);
255}
256
257#endif
258