]>
Commit | Line | Data |
---|---|---|
2874c5fd | 1 | // SPDX-License-Identifier: GPL-2.0-or-later |
cef9dd85 | 2 | /* |
74421786 | 3 | * Touchscreen driver DMI based configuration code |
cef9dd85 HG |
4 | * |
5 | * Copyright (c) 2017 Red Hat Inc. | |
6 | * | |
cef9dd85 HG |
7 | * Red Hat authors: |
8 | * Hans de Goede <hdegoede@redhat.com> | |
9 | */ | |
10 | ||
11 | #include <linux/acpi.h> | |
12 | #include <linux/device.h> | |
13 | #include <linux/dmi.h> | |
14 | #include <linux/i2c.h> | |
15 | #include <linux/notifier.h> | |
16 | #include <linux/property.h> | |
17 | #include <linux/string.h> | |
18 | ||
74421786 | 19 | struct ts_dmi_data { |
cef9dd85 | 20 | const char *acpi_name; |
ae311158 | 21 | const struct property_entry *properties; |
cef9dd85 HG |
22 | }; |
23 | ||
6a655a0d HG |
24 | /* NOTE: Please keep all entries sorted alphabetically */ |
25 | ||
26 | static const struct property_entry chuwi_hi8_props[] = { | |
27 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1665), | |
28 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1140), | |
cef9dd85 | 29 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
6a655a0d HG |
30 | PROPERTY_ENTRY_BOOL("silead,home-button"), |
31 | PROPERTY_ENTRY_STRING("firmware-name", "gsl1680-chuwi-hi8.fw"), | |
cef9dd85 HG |
32 | { } |
33 | }; | |
34 | ||
74421786 | 35 | static const struct ts_dmi_data chuwi_hi8_data = { |
6a655a0d HG |
36 | .acpi_name = "MSSL0001:00", |
37 | .properties = chuwi_hi8_props, | |
cef9dd85 HG |
38 | }; |
39 | ||
bbb97d72 KR |
40 | static const struct property_entry chuwi_hi8_air_props[] = { |
41 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1728), | |
42 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1148), | |
43 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), | |
44 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3676-chuwi-hi8-air.fw"), | |
45 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
46 | { } | |
47 | }; | |
48 | ||
49 | static const struct ts_dmi_data chuwi_hi8_air_data = { | |
50 | .acpi_name = "MSSL1680:00", | |
51 | .properties = chuwi_hi8_air_props, | |
52 | }; | |
53 | ||
6a655a0d | 54 | static const struct property_entry chuwi_hi8_pro_props[] = { |
4104916d HG |
55 | PROPERTY_ENTRY_U32("touchscreen-min-x", 6), |
56 | PROPERTY_ENTRY_U32("touchscreen-min-y", 3), | |
6a655a0d HG |
57 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1728), |
58 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1148), | |
cef9dd85 | 59 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
6a655a0d | 60 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3680-chuwi-hi8-pro.fw"), |
4104916d | 61 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
6a655a0d | 62 | PROPERTY_ENTRY_BOOL("silead,home-button"), |
cef9dd85 HG |
63 | { } |
64 | }; | |
65 | ||
74421786 | 66 | static const struct ts_dmi_data chuwi_hi8_pro_data = { |
cef9dd85 | 67 | .acpi_name = "MSSL1680:00", |
6a655a0d | 68 | .properties = chuwi_hi8_pro_props, |
cef9dd85 HG |
69 | }; |
70 | ||
b98dc493 CO |
71 | static const struct property_entry chuwi_hi10_air_props[] = { |
72 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1981), | |
73 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1271), | |
74 | PROPERTY_ENTRY_U32("touchscreen-min-x", 99), | |
75 | PROPERTY_ENTRY_U32("touchscreen-min-y", 9), | |
76 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), | |
77 | PROPERTY_ENTRY_U32("touchscreen-fuzz-x", 5), | |
78 | PROPERTY_ENTRY_U32("touchscreen-fuzz-y", 4), | |
79 | PROPERTY_ENTRY_STRING("firmware-name", "gsl1680-chuwi-hi10-air.fw"), | |
80 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
81 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
82 | { } | |
83 | }; | |
84 | ||
85 | static const struct ts_dmi_data chuwi_hi10_air_data = { | |
86 | .acpi_name = "MSSL1680:00", | |
87 | .properties = chuwi_hi10_air_props, | |
88 | }; | |
89 | ||
6a655a0d | 90 | static const struct property_entry chuwi_vi8_props[] = { |
4104916d HG |
91 | PROPERTY_ENTRY_U32("touchscreen-min-x", 4), |
92 | PROPERTY_ENTRY_U32("touchscreen-min-y", 6), | |
6a655a0d HG |
93 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1724), |
94 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1140), | |
95 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), | |
96 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3676-chuwi-vi8.fw"), | |
828615f8 HG |
97 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
98 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
99 | { } | |
100 | }; | |
101 | ||
74421786 | 102 | static const struct ts_dmi_data chuwi_vi8_data = { |
6a655a0d HG |
103 | .acpi_name = "MSSL1680:00", |
104 | .properties = chuwi_vi8_props, | |
105 | }; | |
106 | ||
b4c86811 HG |
107 | static const struct property_entry chuwi_vi10_props[] = { |
108 | PROPERTY_ENTRY_U32("touchscreen-min-x", 0), | |
109 | PROPERTY_ENTRY_U32("touchscreen-min-y", 4), | |
110 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1858), | |
111 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1280), | |
112 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3680-chuwi-vi10.fw"), | |
113 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
114 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
115 | { } | |
116 | }; | |
117 | ||
74421786 | 118 | static const struct ts_dmi_data chuwi_vi10_data = { |
b4c86811 HG |
119 | .acpi_name = "MSSL0002:00", |
120 | .properties = chuwi_vi10_props, | |
121 | }; | |
122 | ||
c72d95e5 HG |
123 | static const struct property_entry connect_tablet9_props[] = { |
124 | PROPERTY_ENTRY_U32("touchscreen-min-x", 9), | |
4104916d | 125 | PROPERTY_ENTRY_U32("touchscreen-min-y", 10), |
c72d95e5 | 126 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1664), |
4104916d | 127 | PROPERTY_ENTRY_U32("touchscreen-size-y", 880), |
c72d95e5 HG |
128 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), |
129 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), | |
130 | PROPERTY_ENTRY_STRING("firmware-name", "gsl1680-connect-tablet9.fw"), | |
131 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
132 | { } | |
133 | }; | |
134 | ||
135 | static const struct ts_dmi_data connect_tablet9_data = { | |
136 | .acpi_name = "MSSL1680:00", | |
137 | .properties = connect_tablet9_props, | |
138 | }; | |
139 | ||
6a655a0d | 140 | static const struct property_entry cube_iwork8_air_props[] = { |
4104916d HG |
141 | PROPERTY_ENTRY_U32("touchscreen-min-x", 1), |
142 | PROPERTY_ENTRY_U32("touchscreen-min-y", 3), | |
143 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1664), | |
144 | PROPERTY_ENTRY_U32("touchscreen-size-y", 896), | |
6a655a0d HG |
145 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
146 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3670-cube-iwork8-air.fw"), | |
147 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
148 | { } | |
149 | }; | |
150 | ||
74421786 | 151 | static const struct ts_dmi_data cube_iwork8_air_data = { |
828615f8 | 152 | .acpi_name = "MSSL1680:00", |
6a655a0d | 153 | .properties = cube_iwork8_air_props, |
828615f8 HG |
154 | }; |
155 | ||
cda5915d | 156 | static const struct property_entry cube_knote_i1101_props[] = { |
157 | PROPERTY_ENTRY_U32("touchscreen-min-x", 20), | |
158 | PROPERTY_ENTRY_U32("touchscreen-min-y", 22), | |
159 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1961), | |
160 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1513), | |
161 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3692-cube-knote-i1101.fw"), | |
162 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
163 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
164 | { } | |
165 | }; | |
166 | ||
167 | static const struct ts_dmi_data cube_knote_i1101_data = { | |
168 | .acpi_name = "MSSL1680:00", | |
169 | .properties = cube_knote_i1101_props, | |
170 | }; | |
171 | ||
6b8e7d8f HG |
172 | static const struct property_entry dexp_ursus_7w_props[] = { |
173 | PROPERTY_ENTRY_U32("touchscreen-size-x", 890), | |
174 | PROPERTY_ENTRY_U32("touchscreen-size-y", 630), | |
175 | PROPERTY_ENTRY_STRING("firmware-name", "gsl1686-dexp-ursus-7w.fw"), | |
176 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
aaa40965 | 177 | PROPERTY_ENTRY_BOOL("silead,home-button"), |
6b8e7d8f HG |
178 | { } |
179 | }; | |
180 | ||
74421786 | 181 | static const struct ts_dmi_data dexp_ursus_7w_data = { |
6b8e7d8f HG |
182 | .acpi_name = "MSSL1680:00", |
183 | .properties = dexp_ursus_7w_props, | |
184 | }; | |
185 | ||
6a655a0d HG |
186 | static const struct property_entry digma_citi_e200_props[] = { |
187 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1980), | |
188 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1500), | |
189 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
5b7bb3a7 | 190 | PROPERTY_ENTRY_STRING("firmware-name", |
6a655a0d | 191 | "gsl1686-digma_citi_e200.fw"), |
5b7bb3a7 | 192 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
aaa40965 | 193 | PROPERTY_ENTRY_BOOL("silead,home-button"), |
5b7bb3a7 HG |
194 | { } |
195 | }; | |
196 | ||
74421786 | 197 | static const struct ts_dmi_data digma_citi_e200_data = { |
5b7bb3a7 | 198 | .acpi_name = "MSSL1680:00", |
6a655a0d | 199 | .properties = digma_citi_e200_props, |
5b7bb3a7 HG |
200 | }; |
201 | ||
d9ca30b8 HG |
202 | static const struct property_entry gp_electronic_t701_props[] = { |
203 | PROPERTY_ENTRY_U32("touchscreen-size-x", 960), | |
204 | PROPERTY_ENTRY_U32("touchscreen-size-y", 640), | |
5c24c05e HG |
205 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-x"), |
206 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
d9ca30b8 HG |
207 | PROPERTY_ENTRY_STRING("firmware-name", |
208 | "gsl1680-gp-electronic-t701.fw"), | |
209 | { } | |
210 | }; | |
211 | ||
74421786 | 212 | static const struct ts_dmi_data gp_electronic_t701_data = { |
d9ca30b8 HG |
213 | .acpi_name = "MSSL1680:00", |
214 | .properties = gp_electronic_t701_props, | |
215 | }; | |
216 | ||
6a655a0d | 217 | static const struct property_entry itworks_tw891_props[] = { |
4104916d HG |
218 | PROPERTY_ENTRY_U32("touchscreen-min-x", 1), |
219 | PROPERTY_ENTRY_U32("touchscreen-min-y", 5), | |
6a655a0d | 220 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1600), |
4104916d | 221 | PROPERTY_ENTRY_U32("touchscreen-size-y", 896), |
6a655a0d | 222 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), |
13fadfa7 | 223 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
6a655a0d | 224 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3670-itworks-tw891.fw"), |
4104916d | 225 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
13fadfa7 HG |
226 | { } |
227 | }; | |
228 | ||
74421786 | 229 | static const struct ts_dmi_data itworks_tw891_data = { |
13fadfa7 | 230 | .acpi_name = "MSSL1680:00", |
6a655a0d | 231 | .properties = itworks_tw891_props, |
13fadfa7 HG |
232 | }; |
233 | ||
6a655a0d HG |
234 | static const struct property_entry jumper_ezpad_6_pro_props[] = { |
235 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1980), | |
236 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1500), | |
237 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3692-jumper-ezpad-6-pro.fw"), | |
3cd33db8 HG |
238 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
239 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
240 | { } | |
241 | }; | |
242 | ||
74421786 | 243 | static const struct ts_dmi_data jumper_ezpad_6_pro_data = { |
3cd33db8 | 244 | .acpi_name = "MSSL1680:00", |
6a655a0d | 245 | .properties = jumper_ezpad_6_pro_props, |
3cd33db8 HG |
246 | }; |
247 | ||
504a4351 BR |
248 | static const struct property_entry jumper_ezpad_6_pro_b_props[] = { |
249 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1980), | |
250 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1500), | |
251 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3692-jumper-ezpad-6-pro-b.fw"), | |
252 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
253 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
254 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
255 | { } | |
256 | }; | |
257 | ||
258 | static const struct ts_dmi_data jumper_ezpad_6_pro_b_data = { | |
259 | .acpi_name = "MSSL1680:00", | |
260 | .properties = jumper_ezpad_6_pro_b_props, | |
261 | }; | |
262 | ||
6a655a0d | 263 | static const struct property_entry jumper_ezpad_mini3_props[] = { |
4104916d HG |
264 | PROPERTY_ENTRY_U32("touchscreen-min-x", 23), |
265 | PROPERTY_ENTRY_U32("touchscreen-min-y", 16), | |
6a655a0d | 266 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1700), |
4104916d | 267 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1138), |
f4d342cf | 268 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
6a655a0d HG |
269 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3676-jumper-ezpad-mini3.fw"), |
270 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
4edfc540 HG |
271 | { } |
272 | }; | |
273 | ||
74421786 | 274 | static const struct ts_dmi_data jumper_ezpad_mini3_data = { |
4edfc540 | 275 | .acpi_name = "MSSL1680:00", |
6a655a0d | 276 | .properties = jumper_ezpad_mini3_props, |
4edfc540 HG |
277 | }; |
278 | ||
e79e74a5 GL |
279 | static const struct property_entry myria_my8307_props[] = { |
280 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1720), | |
281 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1140), | |
282 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-x"), | |
283 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
284 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), | |
285 | PROPERTY_ENTRY_STRING("firmware-name", "gsl1680-myria-my8307.fw"), | |
286 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
287 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
288 | { } | |
289 | }; | |
290 | ||
291 | static const struct ts_dmi_data myria_my8307_data = { | |
292 | .acpi_name = "MSSL1680:00", | |
293 | .properties = myria_my8307_props, | |
294 | }; | |
295 | ||
6a655a0d | 296 | static const struct property_entry onda_obook_20_plus_props[] = { |
485f2a58 HG |
297 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1728), |
298 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1148), | |
6a655a0d HG |
299 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-x"), |
300 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
485f2a58 | 301 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
6a655a0d HG |
302 | PROPERTY_ENTRY_STRING("firmware-name", "gsl3676-onda-obook-20-plus.fw"), |
303 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
aaa40965 | 304 | PROPERTY_ENTRY_BOOL("silead,home-button"), |
485f2a58 HG |
305 | { } |
306 | }; | |
307 | ||
74421786 | 308 | static const struct ts_dmi_data onda_obook_20_plus_data = { |
485f2a58 | 309 | .acpi_name = "MSSL1680:00", |
6a655a0d | 310 | .properties = onda_obook_20_plus_props, |
485f2a58 HG |
311 | }; |
312 | ||
01b6b7e6 HG |
313 | static const struct property_entry onda_v80_plus_v3_props[] = { |
314 | PROPERTY_ENTRY_U32("touchscreen-min-x", 22), | |
315 | PROPERTY_ENTRY_U32("touchscreen-min-y", 15), | |
316 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1698), | |
317 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1140), | |
318 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), | |
319 | PROPERTY_ENTRY_STRING("firmware-name", | |
320 | "gsl3676-onda-v80-plus-v3.fw"), | |
321 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
322 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
323 | { } | |
324 | }; | |
325 | ||
326 | static const struct ts_dmi_data onda_v80_plus_v3_data = { | |
327 | .acpi_name = "MSSL1680:00", | |
328 | .properties = onda_v80_plus_v3_props, | |
329 | }; | |
330 | ||
ee08f578 JBB |
331 | static const struct property_entry onda_v820w_32g_props[] = { |
332 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1665), | |
333 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1140), | |
334 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), | |
335 | PROPERTY_ENTRY_STRING("firmware-name", | |
336 | "gsl1680-onda-v820w-32g.fw"), | |
337 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
338 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
339 | { } | |
340 | }; | |
341 | ||
342 | static const struct ts_dmi_data onda_v820w_32g_data = { | |
343 | .acpi_name = "MSSL1680:00", | |
344 | .properties = onda_v820w_32g_props, | |
345 | }; | |
346 | ||
6a655a0d HG |
347 | static const struct property_entry onda_v891w_v1_props[] = { |
348 | PROPERTY_ENTRY_U32("touchscreen-min-x", 46), | |
349 | PROPERTY_ENTRY_U32("touchscreen-min-y", 8), | |
350 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1676), | |
351 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1130), | |
3fcf2b2a | 352 | PROPERTY_ENTRY_STRING("firmware-name", |
6a655a0d | 353 | "gsl3680-onda-v891w-v1.fw"), |
3fcf2b2a ST |
354 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
355 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
356 | { } | |
357 | }; | |
358 | ||
74421786 | 359 | static const struct ts_dmi_data onda_v891w_v1_data = { |
3fcf2b2a | 360 | .acpi_name = "MSSL1680:00", |
6a655a0d | 361 | .properties = onda_v891w_v1_props, |
3fcf2b2a ST |
362 | }; |
363 | ||
c0d73088 | 364 | static const struct property_entry onda_v891w_v3_props[] = { |
365 | PROPERTY_ENTRY_U32("touchscreen-min-x", 35), | |
366 | PROPERTY_ENTRY_U32("touchscreen-min-y", 15), | |
367 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1625), | |
368 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1135), | |
369 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
370 | PROPERTY_ENTRY_STRING("firmware-name", | |
371 | "gsl3676-onda-v891w-v3.fw"), | |
372 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
373 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
374 | { } | |
375 | }; | |
376 | ||
377 | static const struct ts_dmi_data onda_v891w_v3_data = { | |
378 | .acpi_name = "MSSL1680:00", | |
379 | .properties = onda_v891w_v3_props, | |
380 | }; | |
381 | ||
6a655a0d HG |
382 | static const struct property_entry pipo_w2s_props[] = { |
383 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1660), | |
384 | PROPERTY_ENTRY_U32("touchscreen-size-y", 880), | |
170e9a53 | 385 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-x"), |
170e9a53 | 386 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
6a655a0d HG |
387 | PROPERTY_ENTRY_STRING("firmware-name", |
388 | "gsl1680-pipo-w2s.fw"), | |
170e9a53 NB |
389 | { } |
390 | }; | |
391 | ||
74421786 | 392 | static const struct ts_dmi_data pipo_w2s_data = { |
170e9a53 | 393 | .acpi_name = "MSSL1680:00", |
6a655a0d | 394 | .properties = pipo_w2s_props, |
170e9a53 NB |
395 | }; |
396 | ||
6a655a0d HG |
397 | static const struct property_entry pov_mobii_wintab_p800w_v20_props[] = { |
398 | PROPERTY_ENTRY_U32("touchscreen-min-x", 32), | |
399 | PROPERTY_ENTRY_U32("touchscreen-min-y", 16), | |
400 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1692), | |
401 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1146), | |
d2d541e8 | 402 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
6a655a0d HG |
403 | PROPERTY_ENTRY_STRING("firmware-name", |
404 | "gsl3680-pov-mobii-wintab-p800w-v20.fw"), | |
405 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
d2d541e8 | 406 | PROPERTY_ENTRY_BOOL("silead,home-button"), |
d2d541e8 MS |
407 | { } |
408 | }; | |
409 | ||
74421786 | 410 | static const struct ts_dmi_data pov_mobii_wintab_p800w_v20_data = { |
6a655a0d HG |
411 | .acpi_name = "MSSL1680:00", |
412 | .properties = pov_mobii_wintab_p800w_v20_props, | |
d2d541e8 MS |
413 | }; |
414 | ||
6a655a0d | 415 | static const struct property_entry pov_mobii_wintab_p800w_v21_props[] = { |
4104916d HG |
416 | PROPERTY_ENTRY_U32("touchscreen-min-x", 1), |
417 | PROPERTY_ENTRY_U32("touchscreen-min-y", 8), | |
418 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1794), | |
419 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1148), | |
f1905b98 | 420 | PROPERTY_ENTRY_BOOL("touchscreen-swapped-x-y"), |
6a655a0d HG |
421 | PROPERTY_ENTRY_STRING("firmware-name", |
422 | "gsl3692-pov-mobii-wintab-p800w.fw"), | |
4104916d | 423 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
f1905b98 HG |
424 | PROPERTY_ENTRY_BOOL("silead,home-button"), |
425 | { } | |
426 | }; | |
427 | ||
74421786 | 428 | static const struct ts_dmi_data pov_mobii_wintab_p800w_v21_data = { |
6a655a0d HG |
429 | .acpi_name = "MSSL1680:00", |
430 | .properties = pov_mobii_wintab_p800w_v21_props, | |
f1905b98 HG |
431 | }; |
432 | ||
8335ebc1 HG |
433 | static const struct property_entry pov_mobii_wintab_p1006w_v10_props[] = { |
434 | PROPERTY_ENTRY_U32("touchscreen-min-x", 1), | |
435 | PROPERTY_ENTRY_U32("touchscreen-min-y", 3), | |
436 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1984), | |
437 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1520), | |
438 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
439 | PROPERTY_ENTRY_STRING("firmware-name", | |
440 | "gsl3692-pov-mobii-wintab-p1006w-v10.fw"), | |
441 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
442 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
443 | { } | |
444 | }; | |
445 | ||
446 | static const struct ts_dmi_data pov_mobii_wintab_p1006w_v10_data = { | |
447 | .acpi_name = "MSSL1680:00", | |
448 | .properties = pov_mobii_wintab_p1006w_v10_props, | |
449 | }; | |
450 | ||
6a655a0d HG |
451 | static const struct property_entry teclast_x3_plus_props[] = { |
452 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1980), | |
453 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1500), | |
454 | PROPERTY_ENTRY_STRING("firmware-name", "gsl1680-teclast-x3-plus.fw"), | |
2aeb2c3a HG |
455 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
456 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
457 | { } | |
458 | }; | |
459 | ||
74421786 | 460 | static const struct ts_dmi_data teclast_x3_plus_data = { |
2aeb2c3a | 461 | .acpi_name = "MSSL1680:00", |
6a655a0d | 462 | .properties = teclast_x3_plus_props, |
2aeb2c3a HG |
463 | }; |
464 | ||
a346aa20 PC |
465 | static const struct property_entry teclast_x98plus2_props[] = { |
466 | PROPERTY_ENTRY_U32("touchscreen-size-x", 2048), | |
467 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1280), | |
468 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-x"), | |
469 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
470 | PROPERTY_ENTRY_STRING("firmware-name", | |
471 | "gsl1686-teclast_x98plus2.fw"), | |
472 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
473 | { } | |
474 | }; | |
475 | ||
74421786 | 476 | static const struct ts_dmi_data teclast_x98plus2_data = { |
a346aa20 PC |
477 | .acpi_name = "MSSL1680:00", |
478 | .properties = teclast_x98plus2_props, | |
479 | }; | |
480 | ||
cacad0b2 HG |
481 | static const struct property_entry trekstor_primebook_c11_props[] = { |
482 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1970), | |
483 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1530), | |
484 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
485 | PROPERTY_ENTRY_STRING("firmware-name", | |
486 | "gsl1680-trekstor-primebook-c11.fw"), | |
487 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
488 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
489 | { } | |
490 | }; | |
491 | ||
492 | static const struct ts_dmi_data trekstor_primebook_c11_data = { | |
493 | .acpi_name = "MSSL1680:00", | |
494 | .properties = trekstor_primebook_c11_props, | |
495 | }; | |
496 | ||
6a655a0d HG |
497 | static const struct property_entry trekstor_primebook_c13_props[] = { |
498 | PROPERTY_ENTRY_U32("touchscreen-size-x", 2624), | |
499 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1920), | |
500 | PROPERTY_ENTRY_STRING("firmware-name", | |
501 | "gsl1680-trekstor-primebook-c13.fw"), | |
c58a4f22 AP |
502 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
503 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
504 | { } | |
505 | }; | |
506 | ||
74421786 | 507 | static const struct ts_dmi_data trekstor_primebook_c13_data = { |
c58a4f22 | 508 | .acpi_name = "MSSL1680:00", |
6a655a0d | 509 | .properties = trekstor_primebook_c13_props, |
c58a4f22 AP |
510 | }; |
511 | ||
30394a8e MC |
512 | static const struct property_entry trekstor_primetab_t13b_props[] = { |
513 | PROPERTY_ENTRY_U32("touchscreen-size-x", 2500), | |
514 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1900), | |
515 | PROPERTY_ENTRY_STRING("firmware-name", | |
516 | "gsl1680-trekstor-primetab-t13b.fw"), | |
517 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
518 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
519 | PROPERTY_ENTRY_BOOL("touchscreen-inverted-y"), | |
520 | { } | |
521 | }; | |
522 | ||
523 | static const struct ts_dmi_data trekstor_primetab_t13b_data = { | |
524 | .acpi_name = "MSSL1680:00", | |
525 | .properties = trekstor_primetab_t13b_props, | |
526 | }; | |
527 | ||
6a655a0d HG |
528 | static const struct property_entry trekstor_surftab_twin_10_1_props[] = { |
529 | PROPERTY_ENTRY_U32("touchscreen-size-x", 1900), | |
530 | PROPERTY_ENTRY_U32("touchscreen-size-y", 1280), | |
531 | PROPERTY_ENTRY_U32("touchscreen-inverted-y", 1), | |
adf762dc | 532 | PROPERTY_ENTRY_STRING("firmware-name", |
6a655a0d HG |
533 | "gsl3670-surftab-twin-10-1-st10432-8.fw"), |
534 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), | |
535 | { } | |
536 | }; | |
537 | ||
74421786 | 538 | static const struct ts_dmi_data trekstor_surftab_twin_10_1_data = { |
6a655a0d HG |
539 | .acpi_name = "MSSL1680:00", |
540 | .properties = trekstor_surftab_twin_10_1_props, | |
541 | }; | |
542 | ||
543 | static const struct property_entry trekstor_surftab_wintron70_props[] = { | |
4104916d HG |
544 | PROPERTY_ENTRY_U32("touchscreen-min-x", 12), |
545 | PROPERTY_ENTRY_U32("touchscreen-min-y", 8), | |
6a655a0d HG |
546 | PROPERTY_ENTRY_U32("touchscreen-size-x", 884), |
547 | PROPERTY_ENTRY_U32("touchscreen-size-y", 632), | |
548 | PROPERTY_ENTRY_STRING("firmware-name", | |
549 | "gsl1686-surftab-wintron70-st70416-6.fw"), | |
adf762dc HG |
550 | PROPERTY_ENTRY_U32("silead,max-fingers", 10), |
551 | PROPERTY_ENTRY_BOOL("silead,home-button"), | |
552 | { } | |
553 | }; | |
554 | ||
74421786 | 555 | static const struct ts_dmi_data trekstor_surftab_wintron70_data = { |
adf762dc | 556 | .acpi_name = "MSSL1680:00", |
6a655a0d | 557 | .properties = trekstor_surftab_wintron70_props, |
adf762dc HG |
558 | }; |
559 | ||
6a655a0d | 560 | /* NOTE: Please keep this table sorted alphabetically */ |
74421786 | 561 | static const struct dmi_system_id touchscreen_dmi_table[] = { |
6a655a0d HG |
562 | { |
563 | /* Chuwi Hi8 */ | |
564 | .driver_data = (void *)&chuwi_hi8_data, | |
565 | .matches = { | |
566 | DMI_MATCH(DMI_SYS_VENDOR, "ilife"), | |
567 | DMI_MATCH(DMI_PRODUCT_NAME, "S806"), | |
568 | }, | |
569 | }, | |
570 | { | |
571 | /* Chuwi Hi8 (H1D_S806_206) */ | |
572 | .driver_data = (void *)&chuwi_hi8_data, | |
573 | .matches = { | |
574 | DMI_MATCH(DMI_SYS_VENDOR, "Insyde"), | |
575 | DMI_MATCH(DMI_PRODUCT_NAME, "BayTrail"), | |
576 | DMI_MATCH(DMI_BIOS_VERSION, "H1D_S806_206"), | |
577 | }, | |
578 | }, | |
bbb97d72 KR |
579 | { |
580 | /* Chuwi Hi8 Air (CWI543) */ | |
581 | .driver_data = (void *)&chuwi_hi8_air_data, | |
582 | .matches = { | |
583 | DMI_MATCH(DMI_BOARD_VENDOR, "Default string"), | |
584 | DMI_MATCH(DMI_BOARD_NAME, "Cherry Trail CR"), | |
585 | DMI_MATCH(DMI_PRODUCT_NAME, "Hi8 Air"), | |
586 | }, | |
587 | }, | |
6a655a0d HG |
588 | { |
589 | /* Chuwi Hi8 Pro (CWI513) */ | |
590 | .driver_data = (void *)&chuwi_hi8_pro_data, | |
591 | .matches = { | |
592 | DMI_MATCH(DMI_SYS_VENDOR, "Hampoo"), | |
593 | DMI_MATCH(DMI_PRODUCT_NAME, "X1D3_C806N"), | |
594 | }, | |
595 | }, | |
b98dc493 CO |
596 | { |
597 | /* Chuwi Hi10 Air */ | |
598 | .driver_data = (void *)&chuwi_hi10_air_data, | |
599 | .matches = { | |
600 | DMI_MATCH(DMI_BOARD_VENDOR, "Hampoo"), | |
601 | DMI_MATCH(DMI_PRODUCT_SKU, "P1W6_C109D_B"), | |
602 | }, | |
603 | }, | |
6a655a0d HG |
604 | { |
605 | /* Chuwi Vi8 (CWI506) */ | |
606 | .driver_data = (void *)&chuwi_vi8_data, | |
607 | .matches = { | |
608 | DMI_MATCH(DMI_SYS_VENDOR, "Insyde"), | |
609 | DMI_MATCH(DMI_PRODUCT_NAME, "i86"), | |
610 | DMI_MATCH(DMI_BIOS_VERSION, "CHUWI.D86JLBNR"), | |
611 | }, | |
612 | }, | |
b4c86811 HG |
613 | { |
614 | /* Chuwi Vi10 (CWI505) */ | |
615 | .driver_data = (void *)&chuwi_vi10_data, | |
616 | .matches = { | |
617 | DMI_MATCH(DMI_BOARD_VENDOR, "Hampoo"), | |
618 | DMI_MATCH(DMI_BOARD_NAME, "BYT-PF02"), | |
619 | DMI_MATCH(DMI_SYS_VENDOR, "ilife"), | |
620 | DMI_MATCH(DMI_PRODUCT_NAME, "S165"), | |
621 | }, | |
622 | }, | |
c72d95e5 HG |
623 | { |
624 | /* Connect Tablet 9 */ | |
625 | .driver_data = (void *)&connect_tablet9_data, | |
626 | .matches = { | |
627 | DMI_MATCH(DMI_SYS_VENDOR, "Connect"), | |
628 | DMI_MATCH(DMI_PRODUCT_NAME, "Tablet 9"), | |
629 | }, | |
630 | }, | |
cef9dd85 HG |
631 | { |
632 | /* CUBE iwork8 Air */ | |
633 | .driver_data = (void *)&cube_iwork8_air_data, | |
634 | .matches = { | |
635 | DMI_MATCH(DMI_SYS_VENDOR, "cube"), | |
636 | DMI_MATCH(DMI_PRODUCT_NAME, "i1-TF"), | |
637 | DMI_MATCH(DMI_BOARD_NAME, "Cherry Trail CR"), | |
638 | }, | |
639 | }, | |
cda5915d | 640 | { |
641 | /* Cube KNote i1101 */ | |
642 | .driver_data = (void *)&cube_knote_i1101_data, | |
643 | .matches = { | |
644 | DMI_MATCH(DMI_BOARD_VENDOR, "Hampoo"), | |
645 | DMI_MATCH(DMI_BOARD_NAME, "L1W6_I1101"), | |
646 | DMI_MATCH(DMI_SYS_VENDOR, "ALLDOCUBE"), | |
647 | DMI_MATCH(DMI_PRODUCT_NAME, "i1101"), | |
648 | }, | |
649 | }, | |
cef9dd85 | 650 | { |
6a655a0d HG |
651 | /* DEXP Ursus 7W */ |
652 | .driver_data = (void *)&dexp_ursus_7w_data, | |
cef9dd85 HG |
653 | .matches = { |
654 | DMI_MATCH(DMI_SYS_VENDOR, "Insyde"), | |
6a655a0d HG |
655 | DMI_MATCH(DMI_PRODUCT_NAME, "7W"), |
656 | }, | |
657 | }, | |
658 | { | |
659 | /* Digma Citi E200 */ | |
660 | .driver_data = (void *)&digma_citi_e200_data, | |
661 | .matches = { | |
662 | DMI_MATCH(DMI_SYS_VENDOR, "Digma"), | |
663 | DMI_MATCH(DMI_PRODUCT_NAME, "CITI E200"), | |
664 | DMI_MATCH(DMI_BOARD_NAME, "Cherry Trail CR"), | |
665 | }, | |
666 | }, | |
667 | { | |
668 | /* GP-electronic T701 */ | |
669 | .driver_data = (void *)&gp_electronic_t701_data, | |
670 | .matches = { | |
671 | DMI_MATCH(DMI_SYS_VENDOR, "Insyde"), | |
672 | DMI_MATCH(DMI_PRODUCT_NAME, "T701"), | |
673 | DMI_MATCH(DMI_BIOS_VERSION, "BYT70A.YNCHENG.WIN.007"), | |
674 | }, | |
675 | }, | |
676 | { | |
677 | /* I.T.Works TW701 (same hardware as the Trekstor ST70416-6) */ | |
678 | .driver_data = (void *)&trekstor_surftab_wintron70_data, | |
679 | .matches = { | |
680 | DMI_MATCH(DMI_SYS_VENDOR, "Insyde"), | |
681 | DMI_MATCH(DMI_PRODUCT_NAME, "i71c"), | |
682 | DMI_MATCH(DMI_BIOS_VERSION, "itWORKS.G.WI71C.JGBMRB"), | |
683 | }, | |
684 | }, | |
685 | { | |
686 | /* I.T.Works TW891 */ | |
687 | .driver_data = (void *)&itworks_tw891_data, | |
688 | .matches = { | |
689 | DMI_MATCH(DMI_SYS_VENDOR, "To be filled by O.E.M."), | |
690 | DMI_MATCH(DMI_PRODUCT_NAME, "TW891"), | |
cef9dd85 HG |
691 | }, |
692 | }, | |
828615f8 HG |
693 | { |
694 | /* Jumper EZpad 6 Pro */ | |
695 | .driver_data = (void *)&jumper_ezpad_6_pro_data, | |
696 | .matches = { | |
697 | DMI_MATCH(DMI_SYS_VENDOR, "Jumper"), | |
698 | DMI_MATCH(DMI_PRODUCT_NAME, "EZpad"), | |
699 | DMI_MATCH(DMI_BIOS_VERSION, "5.12"), | |
700 | /* Above matches are too generic, add bios-date match */ | |
701 | DMI_MATCH(DMI_BIOS_DATE, "08/18/2017"), | |
702 | }, | |
703 | }, | |
504a4351 BR |
704 | { |
705 | /* Jumper EZpad 6 Pro B */ | |
706 | .driver_data = (void *)&jumper_ezpad_6_pro_b_data, | |
707 | .matches = { | |
708 | DMI_MATCH(DMI_SYS_VENDOR, "Jumper"), | |
709 | DMI_MATCH(DMI_PRODUCT_NAME, "EZpad"), | |
710 | DMI_MATCH(DMI_BIOS_VERSION, "5.12"), | |
711 | /* Above matches are too generic, add bios-date match */ | |
712 | DMI_MATCH(DMI_BIOS_DATE, "04/24/2018"), | |
713 | }, | |
714 | }, | |
6b8e7d8f | 715 | { |
6a655a0d HG |
716 | /* Jumper EZpad mini3 */ |
717 | .driver_data = (void *)&jumper_ezpad_mini3_data, | |
6b8e7d8f HG |
718 | .matches = { |
719 | DMI_MATCH(DMI_SYS_VENDOR, "Insyde"), | |
6a655a0d HG |
720 | /* jumperx.T87.KFBNEEA02 with the version-nr dropped */ |
721 | DMI_MATCH(DMI_BIOS_VERSION, "jumperx.T87.KFBNEEA"), | |
6b8e7d8f HG |
722 | }, |
723 | }, | |
f25b6302 HG |
724 | { |
725 | /* Mediacom Flexbook Edge 11 (same hw as TS Primebook C11) */ | |
726 | .driver_data = (void *)&trekstor_primebook_c11_data, | |
727 | .matches = { | |
728 | DMI_MATCH(DMI_SYS_VENDOR, "MEDIACOM"), | |
729 | DMI_MATCH(DMI_PRODUCT_NAME, "FlexBook edge11 - M-FBE11"), | |
730 | }, | |
731 | }, | |
e79e74a5 GL |
732 | { |
733 | /* Myria MY8307 */ | |
734 | .driver_data = (void *)&myria_my8307_data, | |
735 | .matches = { | |
736 | DMI_MATCH(DMI_SYS_VENDOR, "Complet Electro Serv"), | |
737 | DMI_MATCH(DMI_PRODUCT_NAME, "MY8307"), | |
738 | }, | |
739 | }, | |
f4c12d4d | 740 | { |
6a655a0d HG |
741 | /* Onda oBook 20 Plus */ |
742 | .driver_data = (void *)&onda_obook_20_plus_data, | |
f4c12d4d | 743 | .matches = { |
6a655a0d HG |
744 | DMI_MATCH(DMI_SYS_VENDOR, "ONDA"), |
745 | DMI_MATCH(DMI_PRODUCT_NAME, "OBOOK 20 PLUS"), | |
f4c12d4d BÜ |
746 | }, |
747 | }, | |
01b6b7e6 HG |
748 | { |
749 | /* ONDA V80 plus v3 (P80PSBG9V3A01501) */ | |
750 | .driver_data = (void *)&onda_v80_plus_v3_data, | |
751 | .matches = { | |
752 | DMI_EXACT_MATCH(DMI_SYS_VENDOR, "ONDA"), | |
753 | DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "V80 PLUS") | |
754 | }, | |
755 | }, | |
ee08f578 JBB |
756 | { |
757 | /* ONDA V820w DualOS */ | |
758 | .driver_data = (void *)&onda_v820w_32g_data, | |
759 | .matches = { | |
760 | DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "ONDA"), | |
761 | DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "V820w DualOS") | |
762 | }, | |
763 | }, | |
5b7bb3a7 | 764 | { |
6a655a0d HG |
765 | /* ONDA V891w revision P891WBEBV1B00 aka v1 */ |
766 | .driver_data = (void *)&onda_v891w_v1_data, | |
5b7bb3a7 | 767 | .matches = { |
6a655a0d HG |
768 | DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "ONDA"), |
769 | DMI_EXACT_MATCH(DMI_BOARD_NAME, "ONDA Tablet"), | |
770 | DMI_EXACT_MATCH(DMI_BOARD_VERSION, "V001"), | |
5b7bb3a7 | 771 | /* Exact match, different versions need different fw */ |
6a655a0d | 772 | DMI_EXACT_MATCH(DMI_BIOS_VERSION, "ONDA.W89EBBN08"), |
5b7bb3a7 HG |
773 | }, |
774 | }, | |
c0d73088 | 775 | { |
776 | /* ONDA V891w Dual OS P891DCF2V1A01274 64GB */ | |
777 | .driver_data = (void *)&onda_v891w_v3_data, | |
778 | .matches = { | |
779 | DMI_MATCH(DMI_SYS_VENDOR, "Insyde"), | |
780 | DMI_MATCH(DMI_PRODUCT_NAME, "ONDA Tablet"), | |
781 | DMI_MATCH(DMI_BIOS_VERSION, "ONDA.D890HBBNR0A"), | |
782 | }, | |
783 | }, | |
4245c155 | 784 | { |
6a655a0d HG |
785 | /* Pipo W2S */ |
786 | .driver_data = (void *)&pipo_w2s_data, | |
4245c155 | 787 | .matches = { |
6a655a0d HG |
788 | DMI_MATCH(DMI_SYS_VENDOR, "PIPO"), |
789 | DMI_MATCH(DMI_PRODUCT_NAME, "W2S"), | |
4245c155 HG |
790 | }, |
791 | }, | |
c3a73ed8 HG |
792 | { |
793 | /* Ployer Momo7w (same hardware as the Trekstor ST70416-6) */ | |
d6b0d7d8 | 794 | .driver_data = (void *)&trekstor_surftab_wintron70_data, |
c3a73ed8 HG |
795 | .matches = { |
796 | DMI_MATCH(DMI_SYS_VENDOR, "Shenzhen PLOYER"), | |
797 | DMI_MATCH(DMI_PRODUCT_NAME, "MOMO7W"), | |
798 | /* Exact match, different versions need different fw */ | |
799 | DMI_MATCH(DMI_BIOS_VERSION, "MOMO.G.WI71C.MABMRBA02"), | |
800 | }, | |
801 | }, | |
f4d342cf | 802 | { |
3cd33db8 HG |
803 | /* Point of View mobii wintab p800w (v2.0) */ |
804 | .driver_data = (void *)&pov_mobii_wintab_p800w_v20_data, | |
805 | .matches = { | |
806 | DMI_MATCH(DMI_BOARD_VENDOR, "AMI Corporation"), | |
807 | DMI_MATCH(DMI_BOARD_NAME, "Aptio CRB"), | |
808 | DMI_MATCH(DMI_BIOS_VERSION, "3BAIR1014"), | |
809 | /* Above matches are too generic, add bios-date match */ | |
810 | DMI_MATCH(DMI_BIOS_DATE, "10/24/2014"), | |
811 | }, | |
812 | }, | |
813 | { | |
814 | /* Point of View mobii wintab p800w (v2.1) */ | |
815 | .driver_data = (void *)&pov_mobii_wintab_p800w_v21_data, | |
f4d342cf HG |
816 | .matches = { |
817 | DMI_MATCH(DMI_BOARD_VENDOR, "AMI Corporation"), | |
818 | DMI_MATCH(DMI_BOARD_NAME, "Aptio CRB"), | |
819 | DMI_MATCH(DMI_BIOS_VERSION, "3BAIR1013"), | |
820 | /* Above matches are too generic, add bios-date match */ | |
821 | DMI_MATCH(DMI_BIOS_DATE, "08/22/2014"), | |
822 | }, | |
823 | }, | |
8335ebc1 HG |
824 | { |
825 | /* Point of View mobii wintab p1006w (v1.0) */ | |
826 | .driver_data = (void *)&pov_mobii_wintab_p1006w_v10_data, | |
827 | .matches = { | |
828 | DMI_EXACT_MATCH(DMI_SYS_VENDOR, "Insyde"), | |
829 | DMI_EXACT_MATCH(DMI_PRODUCT_NAME, "BayTrail"), | |
830 | /* Note 105b is Foxcon's USB/PCI vendor id */ | |
831 | DMI_EXACT_MATCH(DMI_BOARD_VENDOR, "105B"), | |
832 | DMI_EXACT_MATCH(DMI_BOARD_NAME, "0E57"), | |
833 | }, | |
834 | }, | |
4edfc540 | 835 | { |
6a655a0d HG |
836 | /* Teclast X3 Plus */ |
837 | .driver_data = (void *)&teclast_x3_plus_data, | |
26ed9d1c | 838 | .matches = { |
6a655a0d HG |
839 | DMI_MATCH(DMI_SYS_VENDOR, "TECLAST"), |
840 | DMI_MATCH(DMI_PRODUCT_NAME, "X3 Plus"), | |
841 | DMI_MATCH(DMI_BOARD_NAME, "X3 Plus"), | |
26ed9d1c | 842 | }, |
843 | }, | |
f1905b98 | 844 | { |
6a655a0d HG |
845 | /* Teclast X98 Plus II */ |
846 | .driver_data = (void *)&teclast_x98plus2_data, | |
f1905b98 | 847 | .matches = { |
6a655a0d HG |
848 | DMI_MATCH(DMI_SYS_VENDOR, "TECLAST"), |
849 | DMI_MATCH(DMI_PRODUCT_NAME, "X98 Plus II"), | |
f1905b98 HG |
850 | }, |
851 | }, | |
cacad0b2 HG |
852 | { |
853 | /* Trekstor Primebook C11 */ | |
854 | .driver_data = (void *)&trekstor_primebook_c11_data, | |
855 | .matches = { | |
856 | DMI_MATCH(DMI_SYS_VENDOR, "TREKSTOR"), | |
857 | DMI_MATCH(DMI_PRODUCT_NAME, "Primebook C11"), | |
858 | }, | |
859 | }, | |
2aeb2c3a HG |
860 | { |
861 | /* Trekstor Primebook C13 */ | |
862 | .driver_data = (void *)&trekstor_primebook_c13_data, | |
863 | .matches = { | |
864 | DMI_MATCH(DMI_SYS_VENDOR, "TREKSTOR"), | |
865 | DMI_MATCH(DMI_PRODUCT_NAME, "Primebook C13"), | |
866 | }, | |
867 | }, | |
30394a8e MC |
868 | { |
869 | /* Trekstor Primetab T13B */ | |
870 | .driver_data = (void *)&trekstor_primetab_t13b_data, | |
871 | .matches = { | |
872 | DMI_MATCH(DMI_SYS_VENDOR, "TREKSTOR"), | |
873 | DMI_MATCH(DMI_PRODUCT_NAME, "Primetab T13B"), | |
874 | }, | |
875 | }, | |
a346aa20 | 876 | { |
6a655a0d HG |
877 | /* TrekStor SurfTab twin 10.1 ST10432-8 */ |
878 | .driver_data = (void *)&trekstor_surftab_twin_10_1_data, | |
a346aa20 | 879 | .matches = { |
6a655a0d HG |
880 | DMI_MATCH(DMI_SYS_VENDOR, "TrekStor"), |
881 | DMI_MATCH(DMI_PRODUCT_NAME, "SurfTab twin 10.1"), | |
a346aa20 PC |
882 | }, |
883 | }, | |
c58a4f22 | 884 | { |
6a655a0d HG |
885 | /* Trekstor Surftab Wintron 7.0 ST70416-6 */ |
886 | .driver_data = (void *)&trekstor_surftab_wintron70_data, | |
c58a4f22 | 887 | .matches = { |
6a655a0d HG |
888 | DMI_MATCH(DMI_SYS_VENDOR, "Insyde"), |
889 | DMI_MATCH(DMI_PRODUCT_NAME, "ST70416-6"), | |
890 | /* Exact match, different versions need different fw */ | |
891 | DMI_MATCH(DMI_BIOS_VERSION, "TREK.G.WI71C.JGBMRBA04"), | |
c58a4f22 AP |
892 | }, |
893 | }, | |
5488bfdf | 894 | { |
6a655a0d | 895 | /* Trekstor Surftab Wintron 7.0 ST70416-6, newer BIOS */ |
d6b0d7d8 | 896 | .driver_data = (void *)&trekstor_surftab_wintron70_data, |
5488bfdf | 897 | .matches = { |
6a655a0d HG |
898 | DMI_MATCH(DMI_SYS_VENDOR, "TrekStor"), |
899 | DMI_MATCH(DMI_PRODUCT_NAME, | |
900 | "SurfTab wintron 7.0 ST70416-6"), | |
901 | /* Exact match, different versions need different fw */ | |
902 | DMI_MATCH(DMI_BIOS_VERSION, "TREK.G.WI71C.JGBMRBA05"), | |
5488bfdf HG |
903 | }, |
904 | }, | |
24e2bb31 HG |
905 | { |
906 | /* Yours Y8W81, same case and touchscreen as Chuwi Vi8 */ | |
907 | .driver_data = (void *)&chuwi_vi8_data, | |
908 | .matches = { | |
909 | DMI_MATCH(DMI_SYS_VENDOR, "YOURS"), | |
910 | DMI_MATCH(DMI_PRODUCT_NAME, "Y8W81"), | |
911 | }, | |
912 | }, | |
cef9dd85 HG |
913 | { }, |
914 | }; | |
915 | ||
74421786 | 916 | static const struct ts_dmi_data *ts_data; |
f22265b6 | 917 | |
74421786 | 918 | static void ts_dmi_add_props(struct i2c_client *client) |
cef9dd85 | 919 | { |
e1053963 | 920 | struct device *dev = &client->dev; |
cef9dd85 HG |
921 | int error; |
922 | ||
cef9dd85 | 923 | if (has_acpi_companion(dev) && |
74421786 HG |
924 | !strncmp(ts_data->acpi_name, client->name, I2C_NAME_SIZE)) { |
925 | error = device_add_properties(dev, ts_data->properties); | |
cef9dd85 HG |
926 | if (error) |
927 | dev_err(dev, "failed to add properties: %d\n", error); | |
928 | } | |
929 | } | |
930 | ||
74421786 | 931 | static int ts_dmi_notifier_call(struct notifier_block *nb, |
cef9dd85 HG |
932 | unsigned long action, void *data) |
933 | { | |
934 | struct device *dev = data; | |
e1053963 | 935 | struct i2c_client *client; |
cef9dd85 HG |
936 | |
937 | switch (action) { | |
938 | case BUS_NOTIFY_ADD_DEVICE: | |
e1053963 DT |
939 | client = i2c_verify_client(dev); |
940 | if (client) | |
74421786 | 941 | ts_dmi_add_props(client); |
cef9dd85 HG |
942 | break; |
943 | ||
944 | default: | |
945 | break; | |
946 | } | |
947 | ||
948 | return 0; | |
949 | } | |
950 | ||
74421786 HG |
951 | static struct notifier_block ts_dmi_notifier = { |
952 | .notifier_call = ts_dmi_notifier_call, | |
cef9dd85 HG |
953 | }; |
954 | ||
74421786 | 955 | static int __init ts_dmi_init(void) |
cef9dd85 | 956 | { |
f22265b6 | 957 | const struct dmi_system_id *dmi_id; |
cef9dd85 HG |
958 | int error; |
959 | ||
74421786 | 960 | dmi_id = dmi_first_match(touchscreen_dmi_table); |
f22265b6 DT |
961 | if (!dmi_id) |
962 | return 0; /* Not an error */ | |
963 | ||
74421786 | 964 | ts_data = dmi_id->driver_data; |
f22265b6 | 965 | |
74421786 | 966 | error = bus_register_notifier(&i2c_bus_type, &ts_dmi_notifier); |
cef9dd85 HG |
967 | if (error) |
968 | pr_err("%s: failed to register i2c bus notifier: %d\n", | |
969 | __func__, error); | |
970 | ||
971 | return error; | |
972 | } | |
973 | ||
974 | /* | |
975 | * We are registering out notifier after i2c core is initialized and i2c bus | |
976 | * itself is ready (which happens at postcore initcall level), but before | |
977 | * ACPI starts enumerating devices (at subsys initcall level). | |
978 | */ | |
74421786 | 979 | arch_initcall(ts_dmi_init); |