Merge lp:~binli/ubuntu/vivid/modemmanager/lp1441095 into lp:ubuntu/vivid/modemmanager
- Vivid (15.04)
- lp1441095
- Merge into vivid
Proposed by
Bin Li
Status: | Needs review |
---|---|
Proposed branch: | lp:~binli/ubuntu/vivid/modemmanager/lp1441095 |
Merge into: | lp:ubuntu/vivid/modemmanager |
Diff against target: |
8349 lines (+7593/-401) 33 files modified
.pc/applied-patches (+7/-0) .pc/dell-mbim-plugin.patch/plugins/Makefile.am (+561/-0) .pc/dell-mbim-plugin.patch/plugins/novatel/mm-plugin-novatel.c (+127/-0) .pc/mbm-common-library.patch/plugins/Makefile.am (+542/-0) .pc/new-sierra-legacy-plugin.patch/plugins/Makefile.am (+553/-0) .pc/new-sierra-legacy-plugin.patch/plugins/sierra/mm-plugin-sierra.c (+129/-0) .pc/novatel-common-library.patch/plugins/Makefile.am (+523/-0) .pc/novatel-custom-init.patch/plugins/Makefile.am (+521/-0) .pc/novatel-custom-init.patch/plugins/novatel/mm-plugin-novatel.c (+267/-0) .pc/sierra-common-library.patch/plugins/Makefile.am (+533/-0) .pc/sierra-custom-init.patch/plugins/sierra/mm-common-sierra.c (+308/-0) .pc/sierra-custom-init.patch/plugins/sierra/mm-common-sierra.h (+50/-0) .pc/sierra-custom-init.patch/plugins/sierra/mm-plugin-sierra.c (+343/-0) debian/changelog (+7/-0) debian/patches/dell-mbim-plugin.patch (+576/-0) debian/patches/mbm-common-library.patch (+50/-0) debian/patches/new-sierra-legacy-plugin.patch (+298/-0) debian/patches/novatel-common-library.patch (+51/-0) debian/patches/novatel-custom-init.patch (+396/-0) debian/patches/series (+7/-0) debian/patches/sierra-common-library.patch (+54/-0) debian/patches/sierra-custom-init.patch (+554/-0) plugins/Makefile.am (+66/-17) plugins/dell/mm-plugin-dell.c (+448/-0) plugins/dell/mm-plugin-dell.h (+46/-0) plugins/novatel/mm-common-novatel.c (+158/-0) plugins/novatel/mm-common-novatel.h (+31/-0) plugins/novatel/mm-plugin-novatel.c (+4/-146) plugins/sierra/mm-common-sierra.c (+217/-0) plugins/sierra/mm-common-sierra.h (+17/-0) plugins/sierra/mm-plugin-sierra-legacy.c (+99/-0) plugins/sierra/mm-plugin-sierra-legacy.h (+40/-0) plugins/sierra/mm-plugin-sierra.c (+10/-238) |
To merge this branch: | bzr merge lp:~binli/ubuntu/vivid/modemmanager/lp1441095 |
Related bugs: |
Reviewer | Review Type | Date Requested | Status |
---|---|---|---|
Mathieu Trudel-Lapierre | Pending | ||
Shih-Yuan Lee | Pending | ||
Sebastien Bacher | Pending | ||
Review via email: mp+273960@code.launchpad.net |
Commit message
Description of the change
Backport the patch from wily.
New hardware enablement: Support the new MBIM devices from Dell.
To post a comment you must log in.
Preview Diff
[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1 | === modified file '.pc/applied-patches' | |||
2 | --- .pc/applied-patches 2014-09-17 08:46:25 +0000 | |||
3 | +++ .pc/applied-patches 2015-10-09 10:06:57 +0000 | |||
4 | @@ -2,3 +2,10 @@ | |||
5 | 2 | arduino-blacklist.patch | 2 | arduino-blacklist.patch |
6 | 3 | linux-default-usb-id.patch | 3 | linux-default-usb-id.patch |
7 | 4 | lp1229748_bluegiga_blacklist.patch | 4 | lp1229748_bluegiga_blacklist.patch |
8 | 5 | novatel-custom-init.patch | ||
9 | 6 | novatel-common-library.patch | ||
10 | 7 | sierra-common-library.patch | ||
11 | 8 | mbm-common-library.patch | ||
12 | 9 | sierra-custom-init.patch | ||
13 | 10 | new-sierra-legacy-plugin.patch | ||
14 | 11 | dell-mbim-plugin.patch | ||
15 | 5 | 12 | ||
16 | === added directory '.pc/dell-mbim-plugin.patch' | |||
17 | === added directory '.pc/dell-mbim-plugin.patch/plugins' | |||
18 | === added file '.pc/dell-mbim-plugin.patch/plugins/Makefile.am' | |||
19 | --- .pc/dell-mbim-plugin.patch/plugins/Makefile.am 1970-01-01 00:00:00 +0000 | |||
20 | +++ .pc/dell-mbim-plugin.patch/plugins/Makefile.am 2015-10-09 10:06:57 +0000 | |||
21 | @@ -0,0 +1,561 @@ | |||
22 | 1 | |||
23 | 2 | include $(top_srcdir)/gtester.make | ||
24 | 3 | |||
25 | 4 | # Common CPPFLAGS and LDFLAGS | ||
26 | 5 | |||
27 | 6 | PLUGIN_COMMON_COMPILER_FLAGS = \ | ||
28 | 7 | $(MM_CFLAGS) \ | ||
29 | 8 | $(GUDEV_CFLAGS) \ | ||
30 | 9 | -I$(top_srcdir) \ | ||
31 | 10 | -I$(top_srcdir)/src \ | ||
32 | 11 | -I$(top_builddir)/src \ | ||
33 | 12 | -I$(top_srcdir)/include \ | ||
34 | 13 | -I$(top_builddir)/include \ | ||
35 | 14 | -I$(top_srcdir)/libmm-glib \ | ||
36 | 15 | -I$(top_srcdir)/libmm-glib/generated \ | ||
37 | 16 | -I$(top_builddir)/libmm-glib/generated | ||
38 | 17 | |||
39 | 18 | PLUGIN_COMMON_LINKER_FLAGS = \ | ||
40 | 19 | $(GUDEV_LIBS) \ | ||
41 | 20 | $(MM_LIBS) \ | ||
42 | 21 | -module \ | ||
43 | 22 | -avoid-version | ||
44 | 23 | |||
45 | 24 | if WITH_QMI | ||
46 | 25 | PLUGIN_COMMON_COMPILER_FLAGS += $(QMI_CFLAGS) | ||
47 | 26 | PLUGIN_COMMON_LINKER_FLAGS += $(QMI_LIBS) | ||
48 | 27 | endif | ||
49 | 28 | |||
50 | 29 | if WITH_MBIM | ||
51 | 30 | PLUGIN_COMMON_COMPILER_FLAGS += $(MBIM_CFLAGS) | ||
52 | 31 | PLUGIN_COMMON_LINKER_FLAGS += $(MBIM_LIBS) | ||
53 | 32 | endif | ||
54 | 33 | |||
55 | 34 | # UDev rules | ||
56 | 35 | udevrulesdir = $(UDEV_BASE_DIR)/rules.d | ||
57 | 36 | udevrules_DATA = | ||
58 | 37 | |||
59 | 38 | # Unit tests | ||
60 | 39 | noinst_PROGRAMS = | ||
61 | 40 | |||
62 | 41 | # Helper libs | ||
63 | 42 | noinst_LTLIBRARIES = | ||
64 | 43 | |||
65 | 44 | ######################################## | ||
66 | 45 | |||
67 | 46 | # Common service test support | ||
68 | 47 | |||
69 | 48 | noinst_LTLIBRARIES += libmm-test-common.la | ||
70 | 49 | |||
71 | 50 | libmm_test_common_la_SOURCES = \ | ||
72 | 51 | tests/test-fixture.h \ | ||
73 | 52 | tests/test-fixture.c \ | ||
74 | 53 | tests/test-port-context.h \ | ||
75 | 54 | tests/test-port-context.c | ||
76 | 55 | |||
77 | 56 | libmm_test_common_la_CPPFLAGS = \ | ||
78 | 57 | $(MM_CFLAGS) \ | ||
79 | 58 | -I$(top_srcdir)/include \ | ||
80 | 59 | -I$(top_builddir)/include \ | ||
81 | 60 | -I$(top_srcdir)/libmm-glib \ | ||
82 | 61 | -I$(top_srcdir)/libmm-glib/generated \ | ||
83 | 62 | -I$(top_builddir)/libmm-glib/generated \ | ||
84 | 63 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
85 | 64 | -DTEST_SERVICES=\""$(abs_top_builddir)/data/tests"\" | ||
86 | 65 | |||
87 | 66 | libmm_test_common_la_LIBADD = \ | ||
88 | 67 | ${top_builddir}/libmm-glib/generated/tests/libmm-test-generated.la \ | ||
89 | 68 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
90 | 69 | |||
91 | 70 | TEST_COMMON_COMPILER_FLAGS = \ | ||
92 | 71 | $(MM_CFLAGS) \ | ||
93 | 72 | -I$(top_srcdir)/plugins/tests \ | ||
94 | 73 | -I$(top_srcdir)/include \ | ||
95 | 74 | -I$(top_builddir)/include \ | ||
96 | 75 | -I$(top_srcdir)/libmm-glib \ | ||
97 | 76 | -I$(top_srcdir)/libmm-glib/generated \ | ||
98 | 77 | -I$(top_builddir)/libmm-glib/generated \ | ||
99 | 78 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
100 | 79 | -DCOMMON_GSM_PORT_CONF=\""$(abs_top_srcdir)/plugins/tests/gsm-port.conf"\" | ||
101 | 80 | |||
102 | 81 | TEST_COMMON_LIBADD_FLAGS = \ | ||
103 | 82 | $(builddir)/libmm-test-common.la \ | ||
104 | 83 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
105 | 84 | |||
106 | 85 | |||
107 | 86 | ######################################## | ||
108 | 87 | |||
109 | 88 | # Icera-specific support | ||
110 | 89 | noinst_LTLIBRARIES += libmm-utils-icera.la | ||
111 | 90 | libmm_utils_icera_la_SOURCES = \ | ||
112 | 91 | icera/mm-broadband-modem-icera.h \ | ||
113 | 92 | icera/mm-broadband-modem-icera.c \ | ||
114 | 93 | icera/mm-broadband-bearer-icera.h \ | ||
115 | 94 | icera/mm-broadband-bearer-icera.c \ | ||
116 | 95 | icera/mm-modem-helpers-icera.c \ | ||
117 | 96 | icera/mm-modem-helpers-icera.h | ||
118 | 97 | libmm_utils_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
119 | 98 | libmm_utils_icera_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
120 | 99 | |||
121 | 100 | ICERA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/icera | ||
122 | 101 | ICERA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-icera.la | ||
123 | 102 | |||
124 | 103 | noinst_PROGRAMS += test-modem-helpers-icera | ||
125 | 104 | test_modem_helpers_icera_SOURCES = \ | ||
126 | 105 | icera/mm-modem-helpers-icera.c \ | ||
127 | 106 | icera/mm-modem-helpers-icera.h \ | ||
128 | 107 | icera/tests/test-modem-helpers-icera.c | ||
129 | 108 | test_modem_helpers_icera_CPPFLAGS = \ | ||
130 | 109 | -I$(top_srcdir)/plugins/icera \ | ||
131 | 110 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
132 | 111 | test_modem_helpers_icera_LDADD = \ | ||
133 | 112 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
134 | 113 | $(top_builddir)/src/libmodem-helpers.la | ||
135 | 114 | test_modem_helpers_icera_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
136 | 115 | |||
137 | 116 | ######################################## | ||
138 | 117 | |||
139 | 118 | pkglib_LTLIBRARIES = \ | ||
140 | 119 | libmm-plugin-generic.la \ | ||
141 | 120 | libmm-plugin-nokia.la \ | ||
142 | 121 | libmm-plugin-nokia-icera.la \ | ||
143 | 122 | libmm-plugin-cinterion.la \ | ||
144 | 123 | libmm-plugin-iridium.la \ | ||
145 | 124 | libmm-plugin-gobi.la \ | ||
146 | 125 | libmm-plugin-motorola.la \ | ||
147 | 126 | libmm-plugin-novatel.la \ | ||
148 | 127 | libmm-plugin-novatel-lte.la \ | ||
149 | 128 | libmm-plugin-altair-lte.la \ | ||
150 | 129 | libmm-plugin-samsung.la \ | ||
151 | 130 | libmm-plugin-option.la \ | ||
152 | 131 | libmm-plugin-hso.la \ | ||
153 | 132 | libmm-plugin-anydata.la \ | ||
154 | 133 | libmm-plugin-linktop.la \ | ||
155 | 134 | libmm-plugin-simtech.la \ | ||
156 | 135 | libmm-plugin-wavecom.la \ | ||
157 | 136 | libmm-plugin-huawei.la \ | ||
158 | 137 | libmm-plugin-longcheer.la \ | ||
159 | 138 | libmm-plugin-x22x.la \ | ||
160 | 139 | libmm-plugin-pantech.la \ | ||
161 | 140 | libmm-plugin-zte.la \ | ||
162 | 141 | libmm-plugin-sierra.la \ | ||
163 | 142 | libmm-plugin-sierra-legacy.la \ | ||
164 | 143 | libmm-plugin-mbm.la \ | ||
165 | 144 | libmm-plugin-via.la \ | ||
166 | 145 | libmm-plugin-telit.la \ | ||
167 | 146 | libmm-plugin-mtk.la | ||
168 | 147 | |||
169 | 148 | # Generic | ||
170 | 149 | libmm_plugin_generic_la_SOURCES = \ | ||
171 | 150 | generic/mm-plugin-generic.c \ | ||
172 | 151 | generic/mm-plugin-generic.h | ||
173 | 152 | libmm_plugin_generic_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
174 | 153 | libmm_plugin_generic_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
175 | 154 | |||
176 | 155 | noinst_PROGRAMS += test-service-generic | ||
177 | 156 | test_service_generic_SOURCES = generic/tests/test-service-generic.c | ||
178 | 157 | test_service_generic_CPPFLAGS = $(TEST_COMMON_COMPILER_FLAGS) | ||
179 | 158 | test_service_generic_LDADD = $(TEST_COMMON_LIBADD_FLAGS) | ||
180 | 159 | test_service_generic_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
181 | 160 | |||
182 | 161 | ## Motorola | ||
183 | 162 | libmm_plugin_motorola_la_SOURCES = \ | ||
184 | 163 | motorola/mm-plugin-motorola.c \ | ||
185 | 164 | motorola/mm-plugin-motorola.h \ | ||
186 | 165 | motorola/mm-broadband-modem-motorola.c \ | ||
187 | 166 | motorola/mm-broadband-modem-motorola.h | ||
188 | 167 | libmm_plugin_motorola_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
189 | 168 | libmm_plugin_motorola_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
190 | 169 | |||
191 | 170 | # Gobi | ||
192 | 171 | libmm_plugin_gobi_la_SOURCES = \ | ||
193 | 172 | gobi/mm-plugin-gobi.c \ | ||
194 | 173 | gobi/mm-plugin-gobi.h \ | ||
195 | 174 | gobi/mm-broadband-modem-gobi.c \ | ||
196 | 175 | gobi/mm-broadband-modem-gobi.h | ||
197 | 176 | libmm_plugin_gobi_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
198 | 177 | libmm_plugin_gobi_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
199 | 178 | |||
200 | 179 | # Huawei | ||
201 | 180 | libmm_plugin_huawei_la_SOURCES = \ | ||
202 | 181 | huawei/mm-plugin-huawei.c \ | ||
203 | 182 | huawei/mm-plugin-huawei.h \ | ||
204 | 183 | huawei/mm-modem-helpers-huawei.c \ | ||
205 | 184 | huawei/mm-modem-helpers-huawei.h \ | ||
206 | 185 | huawei/mm-sim-huawei.c \ | ||
207 | 186 | huawei/mm-sim-huawei.h \ | ||
208 | 187 | huawei/mm-broadband-modem-huawei.c \ | ||
209 | 188 | huawei/mm-broadband-modem-huawei.h \ | ||
210 | 189 | huawei/mm-broadband-bearer-huawei.c \ | ||
211 | 190 | huawei/mm-broadband-bearer-huawei.h | ||
212 | 191 | libmm_plugin_huawei_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
213 | 192 | libmm_plugin_huawei_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
214 | 193 | |||
215 | 194 | udevrules_DATA += huawei/77-mm-huawei-net-port-types.rules | ||
216 | 195 | |||
217 | 196 | noinst_PROGRAMS += test-modem-helpers-huawei | ||
218 | 197 | test_modem_helpers_huawei_SOURCES = \ | ||
219 | 198 | huawei/mm-modem-helpers-huawei.c \ | ||
220 | 199 | huawei/mm-modem-helpers-huawei.h \ | ||
221 | 200 | huawei/tests/test-modem-helpers-huawei.c | ||
222 | 201 | test_modem_helpers_huawei_CPPFLAGS = \ | ||
223 | 202 | -I$(top_srcdir)/plugins/huawei \ | ||
224 | 203 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
225 | 204 | test_modem_helpers_huawei_LDADD = \ | ||
226 | 205 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
227 | 206 | $(top_builddir)/src/libmodem-helpers.la | ||
228 | 207 | test_modem_helpers_huawei_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
229 | 208 | |||
230 | 209 | # Common Mbm modem support library | ||
231 | 210 | noinst_LTLIBRARIES += libmm-utils-mbm.la | ||
232 | 211 | libmm_utils_mbm_la_SOURCES = \ | ||
233 | 212 | mbm/mm-broadband-modem-mbm.c \ | ||
234 | 213 | mbm/mm-broadband-modem-mbm.h \ | ||
235 | 214 | mbm/mm-broadband-bearer-mbm.c \ | ||
236 | 215 | mbm/mm-broadband-bearer-mbm.h \ | ||
237 | 216 | mbm/mm-modem-helpers-mbm.c \ | ||
238 | 217 | mbm/mm-modem-helpers-mbm.h \ | ||
239 | 218 | mbm/mm-sim-mbm.c \ | ||
240 | 219 | mbm/mm-sim-mbm.h | ||
241 | 220 | libmm_utils_mbm_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
242 | 221 | libmm_utils_mbm_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
243 | 222 | |||
244 | 223 | MBM_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/mbm | ||
245 | 224 | MBM_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-mbm.la | ||
246 | 225 | |||
247 | 226 | # MBM | ||
248 | 227 | libmm_plugin_mbm_la_SOURCES = \ | ||
249 | 228 | mbm/mm-plugin-mbm.c \ | ||
250 | 229 | mbm/mm-plugin-mbm.h | ||
251 | 230 | libmm_plugin_mbm_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(MBM_COMMON_COMPILER_FLAGS) | ||
252 | 231 | libmm_plugin_mbm_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
253 | 232 | libmm_plugin_mbm_la_LIBADD = $(MBM_COMMON_LIBADD_FLAGS) | ||
254 | 233 | |||
255 | 234 | udevrules_DATA += mbm/77-mm-ericsson-mbm.rules | ||
256 | 235 | |||
257 | 236 | noinst_PROGRAMS += test-modem-helpers-mbm | ||
258 | 237 | test_modem_helpers_mbm_SOURCES = \ | ||
259 | 238 | mbm/mm-modem-helpers-mbm.c \ | ||
260 | 239 | mbm/mm-modem-helpers-mbm.h \ | ||
261 | 240 | mbm/tests/test-modem-helpers-mbm.c | ||
262 | 241 | test_modem_helpers_mbm_CPPFLAGS = \ | ||
263 | 242 | -I$(top_srcdir)/plugins/mbm \ | ||
264 | 243 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
265 | 244 | test_modem_helpers_mbm_LDADD = \ | ||
266 | 245 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
267 | 246 | $(top_builddir)/src/libmodem-helpers.la | ||
268 | 247 | test_modem_helpers_mbm_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
269 | 248 | |||
270 | 249 | # Option | ||
271 | 250 | libmm_plugin_option_la_SOURCES = \ | ||
272 | 251 | option/mm-plugin-option.c \ | ||
273 | 252 | option/mm-plugin-option.h \ | ||
274 | 253 | option/mm-broadband-modem-option.c \ | ||
275 | 254 | option/mm-broadband-modem-option.h | ||
276 | 255 | libmm_plugin_option_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
277 | 256 | libmm_plugin_option_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
278 | 257 | |||
279 | 258 | # HSO | ||
280 | 259 | libmm_plugin_hso_la_SOURCES = \ | ||
281 | 260 | option/mm-plugin-hso.c \ | ||
282 | 261 | option/mm-plugin-hso.h \ | ||
283 | 262 | option/mm-broadband-modem-option.c \ | ||
284 | 263 | option/mm-broadband-modem-option.h \ | ||
285 | 264 | option/mm-broadband-bearer-hso.c \ | ||
286 | 265 | option/mm-broadband-bearer-hso.h \ | ||
287 | 266 | option/mm-broadband-modem-hso.c \ | ||
288 | 267 | option/mm-broadband-modem-hso.h | ||
289 | 268 | libmm_plugin_hso_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
290 | 269 | libmm_plugin_hso_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
291 | 270 | |||
292 | 271 | # Common Sierra modem support library | ||
293 | 272 | noinst_LTLIBRARIES += libmm-utils-sierra.la | ||
294 | 273 | libmm_utils_sierra_la_SOURCES = \ | ||
295 | 274 | sierra/mm-common-sierra.c \ | ||
296 | 275 | sierra/mm-common-sierra.h \ | ||
297 | 276 | sierra/mm-sim-sierra.c \ | ||
298 | 277 | sierra/mm-sim-sierra.h \ | ||
299 | 278 | sierra/mm-broadband-bearer-sierra.c \ | ||
300 | 279 | sierra/mm-broadband-bearer-sierra.h \ | ||
301 | 280 | sierra/mm-broadband-modem-sierra.c \ | ||
302 | 281 | sierra/mm-broadband-modem-sierra.h | ||
303 | 282 | libmm_utils_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
304 | 283 | libmm_utils_sierra_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
305 | 284 | |||
306 | 285 | SIERRA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/sierra | ||
307 | 286 | SIERRA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-sierra.la | ||
308 | 287 | |||
309 | 288 | # Sierra (new QMI or MBIM modems) | ||
310 | 289 | libmm_plugin_sierra_la_SOURCES = \ | ||
311 | 290 | sierra/mm-plugin-sierra.c \ | ||
312 | 291 | sierra/mm-plugin-sierra.h | ||
313 | 292 | libmm_plugin_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
314 | 293 | libmm_plugin_sierra_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
315 | 294 | |||
316 | 295 | # Sierra (legacy) | ||
317 | 296 | libmm_plugin_sierra_legacy_la_SOURCES = \ | ||
318 | 297 | sierra/mm-plugin-sierra-legacy.c \ | ||
319 | 298 | sierra/mm-plugin-sierra-legacy.h \ | ||
320 | 299 | sierra/mm-broadband-modem-sierra-icera.c \ | ||
321 | 300 | sierra/mm-broadband-modem-sierra-icera.h | ||
322 | 301 | libmm_plugin_sierra_legacy_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) $(SIERRA_COMMON_COMPILER_FLAGS) | ||
323 | 302 | libmm_plugin_sierra_legacy_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
324 | 303 | libmm_plugin_sierra_legacy_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) $(SIERRA_COMMON_LIBADD_FLAGS) | ||
325 | 304 | |||
326 | 305 | # Wavecom (Sierra Airlink) | ||
327 | 306 | libmm_plugin_wavecom_la_SOURCES = \ | ||
328 | 307 | wavecom/mm-plugin-wavecom.c \ | ||
329 | 308 | wavecom/mm-plugin-wavecom.h \ | ||
330 | 309 | wavecom/mm-broadband-modem-wavecom.c \ | ||
331 | 310 | wavecom/mm-broadband-modem-wavecom.h | ||
332 | 311 | libmm_plugin_wavecom_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
333 | 312 | libmm_plugin_wavecom_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
334 | 313 | |||
335 | 314 | # Nokia | ||
336 | 315 | libmm_plugin_nokia_la_SOURCES = \ | ||
337 | 316 | nokia/mm-plugin-nokia.c \ | ||
338 | 317 | nokia/mm-plugin-nokia.h \ | ||
339 | 318 | nokia/mm-sim-nokia.c \ | ||
340 | 319 | nokia/mm-sim-nokia.h \ | ||
341 | 320 | nokia/mm-broadband-modem-nokia.c \ | ||
342 | 321 | nokia/mm-broadband-modem-nokia.h | ||
343 | 322 | libmm_plugin_nokia_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
344 | 323 | libmm_plugin_nokia_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
345 | 324 | |||
346 | 325 | # Nokia (Icera) | ||
347 | 326 | libmm_plugin_nokia_icera_la_SOURCES = \ | ||
348 | 327 | nokia/mm-plugin-nokia-icera.c \ | ||
349 | 328 | nokia/mm-plugin-nokia-icera.h | ||
350 | 329 | libmm_plugin_nokia_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
351 | 330 | libmm_plugin_nokia_icera_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
352 | 331 | libmm_plugin_nokia_icera_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
353 | 332 | udevrules_DATA += nokia/77-mm-nokia-port-types.rules | ||
354 | 333 | |||
355 | 334 | # Zte | ||
356 | 335 | libmm_plugin_zte_la_SOURCES = \ | ||
357 | 336 | zte/mm-plugin-zte.c \ | ||
358 | 337 | zte/mm-plugin-zte.h \ | ||
359 | 338 | zte/mm-common-zte.h \ | ||
360 | 339 | zte/mm-common-zte.c \ | ||
361 | 340 | zte/mm-broadband-modem-zte.h \ | ||
362 | 341 | zte/mm-broadband-modem-zte.c \ | ||
363 | 342 | zte/mm-broadband-modem-zte-icera.h \ | ||
364 | 343 | zte/mm-broadband-modem-zte-icera.c | ||
365 | 344 | libmm_plugin_zte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
366 | 345 | libmm_plugin_zte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
367 | 346 | libmm_plugin_zte_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
368 | 347 | udevrules_DATA += zte/77-mm-zte-port-types.rules | ||
369 | 348 | |||
370 | 349 | # Longcheer (and rebranded dongles) | ||
371 | 350 | libmm_plugin_longcheer_la_SOURCES = \ | ||
372 | 351 | longcheer/mm-plugin-longcheer.c \ | ||
373 | 352 | longcheer/mm-plugin-longcheer.h \ | ||
374 | 353 | longcheer/mm-broadband-modem-longcheer.h \ | ||
375 | 354 | longcheer/mm-broadband-modem-longcheer.c | ||
376 | 355 | libmm_plugin_longcheer_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
377 | 356 | libmm_plugin_longcheer_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
378 | 357 | udevrules_DATA += longcheer/77-mm-longcheer-port-types.rules | ||
379 | 358 | |||
380 | 359 | # AnyData CDMA | ||
381 | 360 | libmm_plugin_anydata_la_SOURCES = \ | ||
382 | 361 | anydata/mm-plugin-anydata.c \ | ||
383 | 362 | anydata/mm-plugin-anydata.h \ | ||
384 | 363 | anydata/mm-broadband-modem-anydata.h \ | ||
385 | 364 | anydata/mm-broadband-modem-anydata.c | ||
386 | 365 | libmm_plugin_anydata_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
387 | 366 | libmm_plugin_anydata_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
388 | 367 | |||
389 | 368 | # Linktop CDMA | ||
390 | 369 | libmm_plugin_linktop_la_SOURCES = \ | ||
391 | 370 | linktop/mm-plugin-linktop.c \ | ||
392 | 371 | linktop/mm-plugin-linktop.h \ | ||
393 | 372 | linktop/mm-broadband-modem-linktop.h \ | ||
394 | 373 | linktop/mm-broadband-modem-linktop.c | ||
395 | 374 | libmm_plugin_linktop_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
396 | 375 | libmm_plugin_linktop_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
397 | 376 | |||
398 | 377 | # SimTech | ||
399 | 378 | libmm_plugin_simtech_la_SOURCES = \ | ||
400 | 379 | simtech/mm-plugin-simtech.c \ | ||
401 | 380 | simtech/mm-plugin-simtech.h \ | ||
402 | 381 | simtech/mm-broadband-modem-simtech.h \ | ||
403 | 382 | simtech/mm-broadband-modem-simtech.c | ||
404 | 383 | libmm_plugin_simtech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
405 | 384 | libmm_plugin_simtech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
406 | 385 | udevrules_DATA += simtech/77-mm-simtech-port-types.rules | ||
407 | 386 | |||
408 | 387 | # Alcatel/TCT/JRD x220D and possibly others | ||
409 | 388 | libmm_plugin_x22x_la_SOURCES = \ | ||
410 | 389 | x22x/mm-plugin-x22x.c \ | ||
411 | 390 | x22x/mm-plugin-x22x.h \ | ||
412 | 391 | x22x/mm-broadband-modem-x22x.h \ | ||
413 | 392 | x22x/mm-broadband-modem-x22x.c | ||
414 | 393 | libmm_plugin_x22x_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
415 | 394 | libmm_plugin_x22x_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
416 | 395 | udevrules_DATA += x22x/77-mm-x22x-port-types.rules | ||
417 | 396 | |||
418 | 397 | # Pantech | ||
419 | 398 | libmm_plugin_pantech_la_SOURCES = \ | ||
420 | 399 | pantech/mm-plugin-pantech.c \ | ||
421 | 400 | pantech/mm-plugin-pantech.h \ | ||
422 | 401 | pantech/mm-sim-pantech.c \ | ||
423 | 402 | pantech/mm-sim-pantech.h \ | ||
424 | 403 | pantech/mm-broadband-modem-pantech.c \ | ||
425 | 404 | pantech/mm-broadband-modem-pantech.h | ||
426 | 405 | libmm_plugin_pantech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
427 | 406 | libmm_plugin_pantech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
428 | 407 | |||
429 | 408 | # Samsung modem | ||
430 | 409 | libmm_plugin_samsung_la_SOURCES = \ | ||
431 | 410 | samsung/mm-plugin-samsung.c \ | ||
432 | 411 | samsung/mm-plugin-samsung.h \ | ||
433 | 412 | samsung/mm-broadband-modem-samsung.c \ | ||
434 | 413 | samsung/mm-broadband-modem-samsung.h | ||
435 | 414 | libmm_plugin_samsung_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
436 | 415 | libmm_plugin_samsung_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
437 | 416 | libmm_plugin_samsung_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
438 | 417 | |||
439 | 418 | # Cinterion (previously Siemens) modem | ||
440 | 419 | libmm_plugin_cinterion_la_SOURCES = \ | ||
441 | 420 | cinterion/mm-plugin-cinterion.c \ | ||
442 | 421 | cinterion/mm-plugin-cinterion.h \ | ||
443 | 422 | cinterion/mm-modem-helpers-cinterion.c \ | ||
444 | 423 | cinterion/mm-modem-helpers-cinterion.h \ | ||
445 | 424 | cinterion/mm-common-cinterion.c \ | ||
446 | 425 | cinterion/mm-common-cinterion.h \ | ||
447 | 426 | cinterion/mm-broadband-modem-cinterion.c \ | ||
448 | 427 | cinterion/mm-broadband-modem-cinterion.h | ||
449 | 428 | |||
450 | 429 | if WITH_QMI | ||
451 | 430 | libmm_plugin_cinterion_la_SOURCES += \ | ||
452 | 431 | cinterion/mm-broadband-modem-qmi-cinterion.c \ | ||
453 | 432 | cinterion/mm-broadband-modem-qmi-cinterion.h | ||
454 | 433 | endif | ||
455 | 434 | |||
456 | 435 | libmm_plugin_cinterion_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
457 | 436 | libmm_plugin_cinterion_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
458 | 437 | |||
459 | 438 | udevrules_DATA += cinterion/77-mm-cinterion-port-types.rules | ||
460 | 439 | |||
461 | 440 | noinst_PROGRAMS += test-modem-helpers-cinterion | ||
462 | 441 | test_modem_helpers_cinterion_SOURCES = \ | ||
463 | 442 | cinterion/mm-modem-helpers-cinterion.c \ | ||
464 | 443 | cinterion/mm-modem-helpers-cinterion.h \ | ||
465 | 444 | cinterion/tests/test-modem-helpers-cinterion.c | ||
466 | 445 | test_modem_helpers_cinterion_CPPFLAGS = \ | ||
467 | 446 | -I$(top_srcdir)/plugins/cinterion \ | ||
468 | 447 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
469 | 448 | test_modem_helpers_cinterion_LDADD = \ | ||
470 | 449 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
471 | 450 | $(top_builddir)/src/libmodem-helpers.la | ||
472 | 451 | test_modem_helpers_cinterion_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
473 | 452 | |||
474 | 453 | # Iridium modem | ||
475 | 454 | libmm_plugin_iridium_la_SOURCES = \ | ||
476 | 455 | iridium/mm-plugin-iridium.c \ | ||
477 | 456 | iridium/mm-plugin-iridium.h \ | ||
478 | 457 | iridium/mm-broadband-modem-iridium.c \ | ||
479 | 458 | iridium/mm-broadband-modem-iridium.h \ | ||
480 | 459 | iridium/mm-bearer-iridium.c \ | ||
481 | 460 | iridium/mm-bearer-iridium.h \ | ||
482 | 461 | iridium/mm-sim-iridium.c \ | ||
483 | 462 | iridium/mm-sim-iridium.h | ||
484 | 463 | libmm_plugin_iridium_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
485 | 464 | libmm_plugin_iridium_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
486 | 465 | |||
487 | 466 | # Common Novatel modem support library | ||
488 | 467 | noinst_LTLIBRARIES += libmm-utils-novatel.la | ||
489 | 468 | libmm_utils_novatel_la_SOURCES = \ | ||
490 | 469 | novatel/mm-common-novatel.c \ | ||
491 | 470 | novatel/mm-common-novatel.h \ | ||
492 | 471 | novatel/mm-broadband-modem-novatel.c \ | ||
493 | 472 | novatel/mm-broadband-modem-novatel.h | ||
494 | 473 | libmm_utils_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
495 | 474 | libmm_utils_novatel_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
496 | 475 | |||
497 | 476 | NOVATEL_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/novatel | ||
498 | 477 | NOVATEL_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-novatel.la | ||
499 | 478 | |||
500 | 479 | # Novatel LTE modem | ||
501 | 480 | libmm_plugin_novatel_lte_la_SOURCES = \ | ||
502 | 481 | novatel/mm-plugin-novatel-lte.c \ | ||
503 | 482 | novatel/mm-plugin-novatel-lte.h \ | ||
504 | 483 | novatel/mm-broadband-modem-novatel-lte.c \ | ||
505 | 484 | novatel/mm-broadband-modem-novatel-lte.h \ | ||
506 | 485 | novatel/mm-broadband-bearer-novatel-lte.c \ | ||
507 | 486 | novatel/mm-broadband-bearer-novatel-lte.h \ | ||
508 | 487 | novatel/mm-sim-novatel-lte.c \ | ||
509 | 488 | novatel/mm-sim-novatel-lte.h | ||
510 | 489 | libmm_plugin_novatel_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
511 | 490 | libmm_plugin_novatel_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
512 | 491 | |||
513 | 492 | # Novatel non-LTE modem | ||
514 | 493 | libmm_plugin_novatel_la_SOURCES = \ | ||
515 | 494 | novatel/mm-plugin-novatel.c \ | ||
516 | 495 | novatel/mm-plugin-novatel.h | ||
517 | 496 | libmm_plugin_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(NOVATEL_COMMON_COMPILER_FLAGS) | ||
518 | 497 | libmm_plugin_novatel_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
519 | 498 | libmm_plugin_novatel_la_LIBADD = $(NOVATEL_COMMON_LIBADD_FLAGS) | ||
520 | 499 | |||
521 | 500 | # Altair LTE modem | ||
522 | 501 | libmm_plugin_altair_lte_la_SOURCES = \ | ||
523 | 502 | altair/mm-modem-helpers-altair-lte.c \ | ||
524 | 503 | altair/mm-modem-helpers-altair-lte.h \ | ||
525 | 504 | altair/mm-plugin-altair-lte.c \ | ||
526 | 505 | altair/mm-plugin-altair-lte.h \ | ||
527 | 506 | altair/mm-broadband-modem-altair-lte.c \ | ||
528 | 507 | altair/mm-broadband-modem-altair-lte.h \ | ||
529 | 508 | altair/mm-broadband-bearer-altair-lte.c \ | ||
530 | 509 | altair/mm-broadband-bearer-altair-lte.h | ||
531 | 510 | libmm_plugin_altair_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
532 | 511 | libmm_plugin_altair_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
533 | 512 | |||
534 | 513 | noinst_PROGRAMS += test-modem-helpers-altair-lte | ||
535 | 514 | test_modem_helpers_altair_lte_SOURCES = \ | ||
536 | 515 | altair/mm-modem-helpers-altair-lte.c \ | ||
537 | 516 | altair/mm-modem-helpers-altair-lte.h \ | ||
538 | 517 | altair/tests/test-modem-helpers-altair-lte.c | ||
539 | 518 | test_modem_helpers_altair_lte_CPPFLAGS = \ | ||
540 | 519 | -I$(top_srcdir)/plugins/altair \ | ||
541 | 520 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
542 | 521 | test_modem_helpers_altair_lte_LDADD = $(top_builddir)/libmm-glib/libmm-glib.la | ||
543 | 522 | test_modem_helpers_altair_lte_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
544 | 523 | |||
545 | 524 | |||
546 | 525 | # VIA modem | ||
547 | 526 | libmm_plugin_via_la_SOURCES = \ | ||
548 | 527 | via/mm-plugin-via.c \ | ||
549 | 528 | via/mm-plugin-via.h \ | ||
550 | 529 | via/mm-broadband-modem-via.c \ | ||
551 | 530 | via/mm-broadband-modem-via.h | ||
552 | 531 | libmm_plugin_via_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
553 | 532 | libmm_plugin_via_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
554 | 533 | |||
555 | 534 | # Telit modem | ||
556 | 535 | libmm_plugin_telit_la_SOURCES = \ | ||
557 | 536 | telit/mm-plugin-telit.c \ | ||
558 | 537 | telit/mm-plugin-telit.h \ | ||
559 | 538 | telit/mm-broadband-modem-telit.c \ | ||
560 | 539 | telit/mm-broadband-modem-telit.h | ||
561 | 540 | libmm_plugin_telit_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
562 | 541 | libmm_plugin_telit_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
563 | 542 | udevrules_DATA += telit/77-mm-telit-port-types.rules | ||
564 | 543 | |||
565 | 544 | # MTK | ||
566 | 545 | libmm_plugin_mtk_la_SOURCES = \ | ||
567 | 546 | mtk/mm-plugin-mtk.c \ | ||
568 | 547 | mtk/mm-plugin-mtk.h \ | ||
569 | 548 | mtk/mm-broadband-modem-mtk.h \ | ||
570 | 549 | mtk/mm-broadband-modem-mtk.c | ||
571 | 550 | libmm_plugin_mtk_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
572 | 551 | libmm_plugin_mtk_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
573 | 552 | udevrules_DATA += mtk/77-mm-mtk-port-types.rules | ||
574 | 553 | |||
575 | 554 | |||
576 | 555 | # Additional files to include in the distribution | ||
577 | 556 | EXTRA_DIST += \ | ||
578 | 557 | $(udevrules_DATA) \ | ||
579 | 558 | tests/gsm-port.conf | ||
580 | 559 | |||
581 | 560 | # Unit tests | ||
582 | 561 | TEST_PROGS += $(noinst_PROGRAMS) | ||
583 | 0 | 562 | ||
584 | === added directory '.pc/dell-mbim-plugin.patch/plugins/dell' | |||
585 | === added file '.pc/dell-mbim-plugin.patch/plugins/dell/mm-plugin-dell.c' | |||
586 | === added file '.pc/dell-mbim-plugin.patch/plugins/dell/mm-plugin-dell.h' | |||
587 | === added directory '.pc/dell-mbim-plugin.patch/plugins/novatel' | |||
588 | === added file '.pc/dell-mbim-plugin.patch/plugins/novatel/mm-plugin-novatel.c' | |||
589 | --- .pc/dell-mbim-plugin.patch/plugins/novatel/mm-plugin-novatel.c 1970-01-01 00:00:00 +0000 | |||
590 | +++ .pc/dell-mbim-plugin.patch/plugins/novatel/mm-plugin-novatel.c 2015-10-09 10:06:57 +0000 | |||
591 | @@ -0,0 +1,127 @@ | |||
592 | 1 | /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ | ||
593 | 2 | |||
594 | 3 | /* | ||
595 | 4 | * This program is free software; you can redistribute it and/or | ||
596 | 5 | * modify it under the terms of the GNU General Public License as | ||
597 | 6 | * published by the Free Software Foundation; either version 2 of the | ||
598 | 7 | * License, or (at your option) any later version. | ||
599 | 8 | * | ||
600 | 9 | * This program is distributed in the hope that it will be useful, | ||
601 | 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
602 | 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
603 | 12 | * General Public License for more details. | ||
604 | 13 | * | ||
605 | 14 | * You should have received a copy of the GNU General Public | ||
606 | 15 | * License along with this program; if not, write to the | ||
607 | 16 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330, | ||
608 | 17 | * Boston, MA 02111-1307, USA. | ||
609 | 18 | * | ||
610 | 19 | * Copyright (C) 2008 - 2009 Novell, Inc. | ||
611 | 20 | * Copyright (C) 2009 - 2012 Red Hat, Inc. | ||
612 | 21 | * Copyright (C) 2012 Aleksander Morgado <aleksander@gnu.org> | ||
613 | 22 | */ | ||
614 | 23 | |||
615 | 24 | #include <string.h> | ||
616 | 25 | #include <gmodule.h> | ||
617 | 26 | |||
618 | 27 | #define _LIBMM_INSIDE_MM | ||
619 | 28 | #include <libmm-glib.h> | ||
620 | 29 | |||
621 | 30 | #include "mm-plugin-novatel.h" | ||
622 | 31 | #include "mm-common-novatel.h" | ||
623 | 32 | #include "mm-private-boxed-types.h" | ||
624 | 33 | #include "mm-broadband-modem-novatel.h" | ||
625 | 34 | #include "mm-log.h" | ||
626 | 35 | |||
627 | 36 | #if defined WITH_QMI | ||
628 | 37 | #include "mm-broadband-modem-qmi.h" | ||
629 | 38 | #endif | ||
630 | 39 | |||
631 | 40 | G_DEFINE_TYPE (MMPluginNovatel, mm_plugin_novatel, MM_TYPE_PLUGIN) | ||
632 | 41 | |||
633 | 42 | int mm_plugin_major_version = MM_PLUGIN_MAJOR_VERSION; | ||
634 | 43 | int mm_plugin_minor_version = MM_PLUGIN_MINOR_VERSION; | ||
635 | 44 | |||
636 | 45 | /*****************************************************************************/ | ||
637 | 46 | /* Custom commands for AT probing */ | ||
638 | 47 | |||
639 | 48 | /* We need to explicitly flip secondary ports to AT mode. | ||
640 | 49 | * We also use this command also for checking AT support in the current port. | ||
641 | 50 | */ | ||
642 | 51 | static const MMPortProbeAtCommand custom_at_probe[] = { | ||
643 | 52 | { "$NWDMAT=1", 3, mm_port_probe_response_processor_is_at }, | ||
644 | 53 | { "$NWDMAT=1", 3, mm_port_probe_response_processor_is_at }, | ||
645 | 54 | { "$NWDMAT=1", 3, mm_port_probe_response_processor_is_at }, | ||
646 | 55 | { NULL } | ||
647 | 56 | }; | ||
648 | 57 | |||
649 | 58 | /*****************************************************************************/ | ||
650 | 59 | |||
651 | 60 | static MMBaseModem * | ||
652 | 61 | create_modem (MMPlugin *self, | ||
653 | 62 | const gchar *sysfs_path, | ||
654 | 63 | const gchar **drivers, | ||
655 | 64 | guint16 vendor, | ||
656 | 65 | guint16 product, | ||
657 | 66 | GList *probes, | ||
658 | 67 | GError **error) | ||
659 | 68 | { | ||
660 | 69 | #if defined WITH_QMI | ||
661 | 70 | if (mm_port_probe_list_has_qmi_port (probes)) { | ||
662 | 71 | mm_dbg ("QMI-powered Novatel modem found..."); | ||
663 | 72 | return MM_BASE_MODEM (mm_broadband_modem_qmi_new (sysfs_path, | ||
664 | 73 | drivers, | ||
665 | 74 | mm_plugin_get_name (self), | ||
666 | 75 | vendor, | ||
667 | 76 | product)); | ||
668 | 77 | } | ||
669 | 78 | #endif | ||
670 | 79 | |||
671 | 80 | return MM_BASE_MODEM (mm_broadband_modem_novatel_new (sysfs_path, | ||
672 | 81 | drivers, | ||
673 | 82 | mm_plugin_get_name (self), | ||
674 | 83 | vendor, | ||
675 | 84 | product)); | ||
676 | 85 | } | ||
677 | 86 | |||
678 | 87 | /*****************************************************************************/ | ||
679 | 88 | |||
680 | 89 | G_MODULE_EXPORT MMPlugin * | ||
681 | 90 | mm_plugin_create (void) | ||
682 | 91 | { | ||
683 | 92 | static const gchar *subsystems[] = { "tty", "net", "usb", NULL }; | ||
684 | 93 | static const guint16 vendors[] = { 0x1410, /* Novatel */ | ||
685 | 94 | 0x413c, /* Dell */ | ||
686 | 95 | 0 }; | ||
687 | 96 | static const mm_uint16_pair forbidden_products[] = { { 0x1410, 0x9010 }, /* Novatel E362 */ | ||
688 | 97 | { 0, 0 } }; | ||
689 | 98 | static const MMAsyncMethod custom_init = { | ||
690 | 99 | .async = G_CALLBACK (mm_common_novatel_custom_init), | ||
691 | 100 | .finish = G_CALLBACK (mm_common_novatel_custom_init_finish), | ||
692 | 101 | }; | ||
693 | 102 | |||
694 | 103 | return MM_PLUGIN ( | ||
695 | 104 | g_object_new (MM_TYPE_PLUGIN_NOVATEL, | ||
696 | 105 | MM_PLUGIN_NAME, "Novatel", | ||
697 | 106 | MM_PLUGIN_ALLOWED_SUBSYSTEMS, subsystems, | ||
698 | 107 | MM_PLUGIN_ALLOWED_VENDOR_IDS, vendors, | ||
699 | 108 | MM_PLUGIN_FORBIDDEN_PRODUCT_IDS, forbidden_products, | ||
700 | 109 | MM_PLUGIN_ALLOWED_AT, TRUE, | ||
701 | 110 | MM_PLUGIN_CUSTOM_INIT, &custom_init, | ||
702 | 111 | MM_PLUGIN_ALLOWED_QCDM, TRUE, | ||
703 | 112 | MM_PLUGIN_ALLOWED_QMI, TRUE, | ||
704 | 113 | NULL)); | ||
705 | 114 | } | ||
706 | 115 | |||
707 | 116 | static void | ||
708 | 117 | mm_plugin_novatel_init (MMPluginNovatel *self) | ||
709 | 118 | { | ||
710 | 119 | } | ||
711 | 120 | |||
712 | 121 | static void | ||
713 | 122 | mm_plugin_novatel_class_init (MMPluginNovatelClass *klass) | ||
714 | 123 | { | ||
715 | 124 | MMPluginClass *plugin_class = MM_PLUGIN_CLASS (klass); | ||
716 | 125 | |||
717 | 126 | plugin_class->create_modem = create_modem; | ||
718 | 127 | } | ||
719 | 0 | 128 | ||
720 | === added directory '.pc/mbm-common-library.patch' | |||
721 | === added directory '.pc/mbm-common-library.patch/plugins' | |||
722 | === added file '.pc/mbm-common-library.patch/plugins/Makefile.am' | |||
723 | --- .pc/mbm-common-library.patch/plugins/Makefile.am 1970-01-01 00:00:00 +0000 | |||
724 | +++ .pc/mbm-common-library.patch/plugins/Makefile.am 2015-10-09 10:06:57 +0000 | |||
725 | @@ -0,0 +1,542 @@ | |||
726 | 1 | |||
727 | 2 | include $(top_srcdir)/gtester.make | ||
728 | 3 | |||
729 | 4 | # Common CPPFLAGS and LDFLAGS | ||
730 | 5 | |||
731 | 6 | PLUGIN_COMMON_COMPILER_FLAGS = \ | ||
732 | 7 | $(MM_CFLAGS) \ | ||
733 | 8 | $(GUDEV_CFLAGS) \ | ||
734 | 9 | -I$(top_srcdir) \ | ||
735 | 10 | -I$(top_srcdir)/src \ | ||
736 | 11 | -I$(top_builddir)/src \ | ||
737 | 12 | -I$(top_srcdir)/include \ | ||
738 | 13 | -I$(top_builddir)/include \ | ||
739 | 14 | -I$(top_srcdir)/libmm-glib \ | ||
740 | 15 | -I$(top_srcdir)/libmm-glib/generated \ | ||
741 | 16 | -I$(top_builddir)/libmm-glib/generated | ||
742 | 17 | |||
743 | 18 | PLUGIN_COMMON_LINKER_FLAGS = \ | ||
744 | 19 | $(GUDEV_LIBS) \ | ||
745 | 20 | $(MM_LIBS) \ | ||
746 | 21 | -module \ | ||
747 | 22 | -avoid-version | ||
748 | 23 | |||
749 | 24 | if WITH_QMI | ||
750 | 25 | PLUGIN_COMMON_COMPILER_FLAGS += $(QMI_CFLAGS) | ||
751 | 26 | PLUGIN_COMMON_LINKER_FLAGS += $(QMI_LIBS) | ||
752 | 27 | endif | ||
753 | 28 | |||
754 | 29 | if WITH_MBIM | ||
755 | 30 | PLUGIN_COMMON_COMPILER_FLAGS += $(MBIM_CFLAGS) | ||
756 | 31 | PLUGIN_COMMON_LINKER_FLAGS += $(MBIM_LIBS) | ||
757 | 32 | endif | ||
758 | 33 | |||
759 | 34 | # UDev rules | ||
760 | 35 | udevrulesdir = $(UDEV_BASE_DIR)/rules.d | ||
761 | 36 | udevrules_DATA = | ||
762 | 37 | |||
763 | 38 | # Unit tests | ||
764 | 39 | noinst_PROGRAMS = | ||
765 | 40 | |||
766 | 41 | # Helper libs | ||
767 | 42 | noinst_LTLIBRARIES = | ||
768 | 43 | |||
769 | 44 | ######################################## | ||
770 | 45 | |||
771 | 46 | # Common service test support | ||
772 | 47 | |||
773 | 48 | noinst_LTLIBRARIES += libmm-test-common.la | ||
774 | 49 | |||
775 | 50 | libmm_test_common_la_SOURCES = \ | ||
776 | 51 | tests/test-fixture.h \ | ||
777 | 52 | tests/test-fixture.c \ | ||
778 | 53 | tests/test-port-context.h \ | ||
779 | 54 | tests/test-port-context.c | ||
780 | 55 | |||
781 | 56 | libmm_test_common_la_CPPFLAGS = \ | ||
782 | 57 | $(MM_CFLAGS) \ | ||
783 | 58 | -I$(top_srcdir)/include \ | ||
784 | 59 | -I$(top_builddir)/include \ | ||
785 | 60 | -I$(top_srcdir)/libmm-glib \ | ||
786 | 61 | -I$(top_srcdir)/libmm-glib/generated \ | ||
787 | 62 | -I$(top_builddir)/libmm-glib/generated \ | ||
788 | 63 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
789 | 64 | -DTEST_SERVICES=\""$(abs_top_builddir)/data/tests"\" | ||
790 | 65 | |||
791 | 66 | libmm_test_common_la_LIBADD = \ | ||
792 | 67 | ${top_builddir}/libmm-glib/generated/tests/libmm-test-generated.la \ | ||
793 | 68 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
794 | 69 | |||
795 | 70 | TEST_COMMON_COMPILER_FLAGS = \ | ||
796 | 71 | $(MM_CFLAGS) \ | ||
797 | 72 | -I$(top_srcdir)/plugins/tests \ | ||
798 | 73 | -I$(top_srcdir)/include \ | ||
799 | 74 | -I$(top_builddir)/include \ | ||
800 | 75 | -I$(top_srcdir)/libmm-glib \ | ||
801 | 76 | -I$(top_srcdir)/libmm-glib/generated \ | ||
802 | 77 | -I$(top_builddir)/libmm-glib/generated \ | ||
803 | 78 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
804 | 79 | -DCOMMON_GSM_PORT_CONF=\""$(abs_top_srcdir)/plugins/tests/gsm-port.conf"\" | ||
805 | 80 | |||
806 | 81 | TEST_COMMON_LIBADD_FLAGS = \ | ||
807 | 82 | $(builddir)/libmm-test-common.la \ | ||
808 | 83 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
809 | 84 | |||
810 | 85 | |||
811 | 86 | ######################################## | ||
812 | 87 | |||
813 | 88 | # Icera-specific support | ||
814 | 89 | noinst_LTLIBRARIES += libmm-utils-icera.la | ||
815 | 90 | libmm_utils_icera_la_SOURCES = \ | ||
816 | 91 | icera/mm-broadband-modem-icera.h \ | ||
817 | 92 | icera/mm-broadband-modem-icera.c \ | ||
818 | 93 | icera/mm-broadband-bearer-icera.h \ | ||
819 | 94 | icera/mm-broadband-bearer-icera.c \ | ||
820 | 95 | icera/mm-modem-helpers-icera.c \ | ||
821 | 96 | icera/mm-modem-helpers-icera.h | ||
822 | 97 | libmm_utils_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
823 | 98 | libmm_utils_icera_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
824 | 99 | |||
825 | 100 | ICERA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/icera | ||
826 | 101 | ICERA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-icera.la | ||
827 | 102 | |||
828 | 103 | noinst_PROGRAMS += test-modem-helpers-icera | ||
829 | 104 | test_modem_helpers_icera_SOURCES = \ | ||
830 | 105 | icera/mm-modem-helpers-icera.c \ | ||
831 | 106 | icera/mm-modem-helpers-icera.h \ | ||
832 | 107 | icera/tests/test-modem-helpers-icera.c | ||
833 | 108 | test_modem_helpers_icera_CPPFLAGS = \ | ||
834 | 109 | -I$(top_srcdir)/plugins/icera \ | ||
835 | 110 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
836 | 111 | test_modem_helpers_icera_LDADD = \ | ||
837 | 112 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
838 | 113 | $(top_builddir)/src/libmodem-helpers.la | ||
839 | 114 | test_modem_helpers_icera_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
840 | 115 | |||
841 | 116 | ######################################## | ||
842 | 117 | |||
843 | 118 | pkglib_LTLIBRARIES = \ | ||
844 | 119 | libmm-plugin-generic.la \ | ||
845 | 120 | libmm-plugin-nokia.la \ | ||
846 | 121 | libmm-plugin-nokia-icera.la \ | ||
847 | 122 | libmm-plugin-cinterion.la \ | ||
848 | 123 | libmm-plugin-iridium.la \ | ||
849 | 124 | libmm-plugin-gobi.la \ | ||
850 | 125 | libmm-plugin-motorola.la \ | ||
851 | 126 | libmm-plugin-novatel.la \ | ||
852 | 127 | libmm-plugin-novatel-lte.la \ | ||
853 | 128 | libmm-plugin-altair-lte.la \ | ||
854 | 129 | libmm-plugin-samsung.la \ | ||
855 | 130 | libmm-plugin-option.la \ | ||
856 | 131 | libmm-plugin-hso.la \ | ||
857 | 132 | libmm-plugin-anydata.la \ | ||
858 | 133 | libmm-plugin-linktop.la \ | ||
859 | 134 | libmm-plugin-simtech.la \ | ||
860 | 135 | libmm-plugin-wavecom.la \ | ||
861 | 136 | libmm-plugin-huawei.la \ | ||
862 | 137 | libmm-plugin-longcheer.la \ | ||
863 | 138 | libmm-plugin-x22x.la \ | ||
864 | 139 | libmm-plugin-pantech.la \ | ||
865 | 140 | libmm-plugin-zte.la \ | ||
866 | 141 | libmm-plugin-sierra.la \ | ||
867 | 142 | libmm-plugin-mbm.la \ | ||
868 | 143 | libmm-plugin-via.la \ | ||
869 | 144 | libmm-plugin-telit.la \ | ||
870 | 145 | libmm-plugin-mtk.la | ||
871 | 146 | |||
872 | 147 | # Generic | ||
873 | 148 | libmm_plugin_generic_la_SOURCES = \ | ||
874 | 149 | generic/mm-plugin-generic.c \ | ||
875 | 150 | generic/mm-plugin-generic.h | ||
876 | 151 | libmm_plugin_generic_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
877 | 152 | libmm_plugin_generic_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
878 | 153 | |||
879 | 154 | noinst_PROGRAMS += test-service-generic | ||
880 | 155 | test_service_generic_SOURCES = generic/tests/test-service-generic.c | ||
881 | 156 | test_service_generic_CPPFLAGS = $(TEST_COMMON_COMPILER_FLAGS) | ||
882 | 157 | test_service_generic_LDADD = $(TEST_COMMON_LIBADD_FLAGS) | ||
883 | 158 | test_service_generic_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
884 | 159 | |||
885 | 160 | ## Motorola | ||
886 | 161 | libmm_plugin_motorola_la_SOURCES = \ | ||
887 | 162 | motorola/mm-plugin-motorola.c \ | ||
888 | 163 | motorola/mm-plugin-motorola.h \ | ||
889 | 164 | motorola/mm-broadband-modem-motorola.c \ | ||
890 | 165 | motorola/mm-broadband-modem-motorola.h | ||
891 | 166 | libmm_plugin_motorola_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
892 | 167 | libmm_plugin_motorola_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
893 | 168 | |||
894 | 169 | # Gobi | ||
895 | 170 | libmm_plugin_gobi_la_SOURCES = \ | ||
896 | 171 | gobi/mm-plugin-gobi.c \ | ||
897 | 172 | gobi/mm-plugin-gobi.h \ | ||
898 | 173 | gobi/mm-broadband-modem-gobi.c \ | ||
899 | 174 | gobi/mm-broadband-modem-gobi.h | ||
900 | 175 | libmm_plugin_gobi_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
901 | 176 | libmm_plugin_gobi_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
902 | 177 | |||
903 | 178 | # Huawei | ||
904 | 179 | libmm_plugin_huawei_la_SOURCES = \ | ||
905 | 180 | huawei/mm-plugin-huawei.c \ | ||
906 | 181 | huawei/mm-plugin-huawei.h \ | ||
907 | 182 | huawei/mm-modem-helpers-huawei.c \ | ||
908 | 183 | huawei/mm-modem-helpers-huawei.h \ | ||
909 | 184 | huawei/mm-sim-huawei.c \ | ||
910 | 185 | huawei/mm-sim-huawei.h \ | ||
911 | 186 | huawei/mm-broadband-modem-huawei.c \ | ||
912 | 187 | huawei/mm-broadband-modem-huawei.h \ | ||
913 | 188 | huawei/mm-broadband-bearer-huawei.c \ | ||
914 | 189 | huawei/mm-broadband-bearer-huawei.h | ||
915 | 190 | libmm_plugin_huawei_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
916 | 191 | libmm_plugin_huawei_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
917 | 192 | |||
918 | 193 | udevrules_DATA += huawei/77-mm-huawei-net-port-types.rules | ||
919 | 194 | |||
920 | 195 | noinst_PROGRAMS += test-modem-helpers-huawei | ||
921 | 196 | test_modem_helpers_huawei_SOURCES = \ | ||
922 | 197 | huawei/mm-modem-helpers-huawei.c \ | ||
923 | 198 | huawei/mm-modem-helpers-huawei.h \ | ||
924 | 199 | huawei/tests/test-modem-helpers-huawei.c | ||
925 | 200 | test_modem_helpers_huawei_CPPFLAGS = \ | ||
926 | 201 | -I$(top_srcdir)/plugins/huawei \ | ||
927 | 202 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
928 | 203 | test_modem_helpers_huawei_LDADD = \ | ||
929 | 204 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
930 | 205 | $(top_builddir)/src/libmodem-helpers.la | ||
931 | 206 | test_modem_helpers_huawei_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
932 | 207 | |||
933 | 208 | # MBM | ||
934 | 209 | libmm_plugin_mbm_la_SOURCES = \ | ||
935 | 210 | mbm/mm-plugin-mbm.c \ | ||
936 | 211 | mbm/mm-plugin-mbm.h \ | ||
937 | 212 | mbm/mm-broadband-modem-mbm.c \ | ||
938 | 213 | mbm/mm-broadband-modem-mbm.h \ | ||
939 | 214 | mbm/mm-broadband-bearer-mbm.c \ | ||
940 | 215 | mbm/mm-broadband-bearer-mbm.h \ | ||
941 | 216 | mbm/mm-modem-helpers-mbm.c \ | ||
942 | 217 | mbm/mm-modem-helpers-mbm.h \ | ||
943 | 218 | mbm/mm-sim-mbm.c \ | ||
944 | 219 | mbm/mm-sim-mbm.h | ||
945 | 220 | libmm_plugin_mbm_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
946 | 221 | libmm_plugin_mbm_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
947 | 222 | udevrules_DATA += mbm/77-mm-ericsson-mbm.rules | ||
948 | 223 | |||
949 | 224 | noinst_PROGRAMS += test-modem-helpers-mbm | ||
950 | 225 | test_modem_helpers_mbm_SOURCES = \ | ||
951 | 226 | mbm/mm-modem-helpers-mbm.c \ | ||
952 | 227 | mbm/mm-modem-helpers-mbm.h \ | ||
953 | 228 | mbm/tests/test-modem-helpers-mbm.c | ||
954 | 229 | test_modem_helpers_mbm_CPPFLAGS = \ | ||
955 | 230 | -I$(top_srcdir)/plugins/mbm \ | ||
956 | 231 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
957 | 232 | test_modem_helpers_mbm_LDADD = \ | ||
958 | 233 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
959 | 234 | $(top_builddir)/src/libmodem-helpers.la | ||
960 | 235 | test_modem_helpers_mbm_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
961 | 236 | |||
962 | 237 | # Option | ||
963 | 238 | libmm_plugin_option_la_SOURCES = \ | ||
964 | 239 | option/mm-plugin-option.c \ | ||
965 | 240 | option/mm-plugin-option.h \ | ||
966 | 241 | option/mm-broadband-modem-option.c \ | ||
967 | 242 | option/mm-broadband-modem-option.h | ||
968 | 243 | libmm_plugin_option_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
969 | 244 | libmm_plugin_option_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
970 | 245 | |||
971 | 246 | # HSO | ||
972 | 247 | libmm_plugin_hso_la_SOURCES = \ | ||
973 | 248 | option/mm-plugin-hso.c \ | ||
974 | 249 | option/mm-plugin-hso.h \ | ||
975 | 250 | option/mm-broadband-modem-option.c \ | ||
976 | 251 | option/mm-broadband-modem-option.h \ | ||
977 | 252 | option/mm-broadband-bearer-hso.c \ | ||
978 | 253 | option/mm-broadband-bearer-hso.h \ | ||
979 | 254 | option/mm-broadband-modem-hso.c \ | ||
980 | 255 | option/mm-broadband-modem-hso.h | ||
981 | 256 | libmm_plugin_hso_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
982 | 257 | libmm_plugin_hso_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
983 | 258 | |||
984 | 259 | # Common Sierra modem support library | ||
985 | 260 | noinst_LTLIBRARIES += libmm-utils-sierra.la | ||
986 | 261 | libmm_utils_sierra_la_SOURCES = \ | ||
987 | 262 | sierra/mm-common-sierra.c \ | ||
988 | 263 | sierra/mm-common-sierra.h \ | ||
989 | 264 | sierra/mm-sim-sierra.c \ | ||
990 | 265 | sierra/mm-sim-sierra.h \ | ||
991 | 266 | sierra/mm-broadband-bearer-sierra.c \ | ||
992 | 267 | sierra/mm-broadband-bearer-sierra.h \ | ||
993 | 268 | sierra/mm-broadband-modem-sierra.c \ | ||
994 | 269 | sierra/mm-broadband-modem-sierra.h | ||
995 | 270 | libmm_utils_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
996 | 271 | libmm_utils_sierra_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
997 | 272 | |||
998 | 273 | SIERRA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/sierra | ||
999 | 274 | SIERRA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-sierra.la | ||
1000 | 275 | |||
1001 | 276 | # Sierra | ||
1002 | 277 | libmm_plugin_sierra_la_SOURCES = \ | ||
1003 | 278 | sierra/mm-plugin-sierra.c \ | ||
1004 | 279 | sierra/mm-plugin-sierra.h \ | ||
1005 | 280 | sierra/mm-broadband-modem-sierra-icera.c \ | ||
1006 | 281 | sierra/mm-broadband-modem-sierra-icera.h | ||
1007 | 282 | libmm_plugin_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) $(SIERRA_COMMON_COMPILER_FLAGS) | ||
1008 | 283 | libmm_plugin_sierra_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1009 | 284 | libmm_plugin_sierra_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) $(SIERRA_COMMON_LIBADD_FLAGS) | ||
1010 | 285 | |||
1011 | 286 | # Wavecom (Sierra Airlink) | ||
1012 | 287 | libmm_plugin_wavecom_la_SOURCES = \ | ||
1013 | 288 | wavecom/mm-plugin-wavecom.c \ | ||
1014 | 289 | wavecom/mm-plugin-wavecom.h \ | ||
1015 | 290 | wavecom/mm-broadband-modem-wavecom.c \ | ||
1016 | 291 | wavecom/mm-broadband-modem-wavecom.h | ||
1017 | 292 | libmm_plugin_wavecom_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1018 | 293 | libmm_plugin_wavecom_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1019 | 294 | |||
1020 | 295 | # Nokia | ||
1021 | 296 | libmm_plugin_nokia_la_SOURCES = \ | ||
1022 | 297 | nokia/mm-plugin-nokia.c \ | ||
1023 | 298 | nokia/mm-plugin-nokia.h \ | ||
1024 | 299 | nokia/mm-sim-nokia.c \ | ||
1025 | 300 | nokia/mm-sim-nokia.h \ | ||
1026 | 301 | nokia/mm-broadband-modem-nokia.c \ | ||
1027 | 302 | nokia/mm-broadband-modem-nokia.h | ||
1028 | 303 | libmm_plugin_nokia_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1029 | 304 | libmm_plugin_nokia_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1030 | 305 | |||
1031 | 306 | # Nokia (Icera) | ||
1032 | 307 | libmm_plugin_nokia_icera_la_SOURCES = \ | ||
1033 | 308 | nokia/mm-plugin-nokia-icera.c \ | ||
1034 | 309 | nokia/mm-plugin-nokia-icera.h | ||
1035 | 310 | libmm_plugin_nokia_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
1036 | 311 | libmm_plugin_nokia_icera_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1037 | 312 | libmm_plugin_nokia_icera_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
1038 | 313 | udevrules_DATA += nokia/77-mm-nokia-port-types.rules | ||
1039 | 314 | |||
1040 | 315 | # Zte | ||
1041 | 316 | libmm_plugin_zte_la_SOURCES = \ | ||
1042 | 317 | zte/mm-plugin-zte.c \ | ||
1043 | 318 | zte/mm-plugin-zte.h \ | ||
1044 | 319 | zte/mm-common-zte.h \ | ||
1045 | 320 | zte/mm-common-zte.c \ | ||
1046 | 321 | zte/mm-broadband-modem-zte.h \ | ||
1047 | 322 | zte/mm-broadband-modem-zte.c \ | ||
1048 | 323 | zte/mm-broadband-modem-zte-icera.h \ | ||
1049 | 324 | zte/mm-broadband-modem-zte-icera.c | ||
1050 | 325 | libmm_plugin_zte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
1051 | 326 | libmm_plugin_zte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1052 | 327 | libmm_plugin_zte_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
1053 | 328 | udevrules_DATA += zte/77-mm-zte-port-types.rules | ||
1054 | 329 | |||
1055 | 330 | # Longcheer (and rebranded dongles) | ||
1056 | 331 | libmm_plugin_longcheer_la_SOURCES = \ | ||
1057 | 332 | longcheer/mm-plugin-longcheer.c \ | ||
1058 | 333 | longcheer/mm-plugin-longcheer.h \ | ||
1059 | 334 | longcheer/mm-broadband-modem-longcheer.h \ | ||
1060 | 335 | longcheer/mm-broadband-modem-longcheer.c | ||
1061 | 336 | libmm_plugin_longcheer_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1062 | 337 | libmm_plugin_longcheer_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1063 | 338 | udevrules_DATA += longcheer/77-mm-longcheer-port-types.rules | ||
1064 | 339 | |||
1065 | 340 | # AnyData CDMA | ||
1066 | 341 | libmm_plugin_anydata_la_SOURCES = \ | ||
1067 | 342 | anydata/mm-plugin-anydata.c \ | ||
1068 | 343 | anydata/mm-plugin-anydata.h \ | ||
1069 | 344 | anydata/mm-broadband-modem-anydata.h \ | ||
1070 | 345 | anydata/mm-broadband-modem-anydata.c | ||
1071 | 346 | libmm_plugin_anydata_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1072 | 347 | libmm_plugin_anydata_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1073 | 348 | |||
1074 | 349 | # Linktop CDMA | ||
1075 | 350 | libmm_plugin_linktop_la_SOURCES = \ | ||
1076 | 351 | linktop/mm-plugin-linktop.c \ | ||
1077 | 352 | linktop/mm-plugin-linktop.h \ | ||
1078 | 353 | linktop/mm-broadband-modem-linktop.h \ | ||
1079 | 354 | linktop/mm-broadband-modem-linktop.c | ||
1080 | 355 | libmm_plugin_linktop_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1081 | 356 | libmm_plugin_linktop_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1082 | 357 | |||
1083 | 358 | # SimTech | ||
1084 | 359 | libmm_plugin_simtech_la_SOURCES = \ | ||
1085 | 360 | simtech/mm-plugin-simtech.c \ | ||
1086 | 361 | simtech/mm-plugin-simtech.h \ | ||
1087 | 362 | simtech/mm-broadband-modem-simtech.h \ | ||
1088 | 363 | simtech/mm-broadband-modem-simtech.c | ||
1089 | 364 | libmm_plugin_simtech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1090 | 365 | libmm_plugin_simtech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1091 | 366 | udevrules_DATA += simtech/77-mm-simtech-port-types.rules | ||
1092 | 367 | |||
1093 | 368 | # Alcatel/TCT/JRD x220D and possibly others | ||
1094 | 369 | libmm_plugin_x22x_la_SOURCES = \ | ||
1095 | 370 | x22x/mm-plugin-x22x.c \ | ||
1096 | 371 | x22x/mm-plugin-x22x.h \ | ||
1097 | 372 | x22x/mm-broadband-modem-x22x.h \ | ||
1098 | 373 | x22x/mm-broadband-modem-x22x.c | ||
1099 | 374 | libmm_plugin_x22x_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1100 | 375 | libmm_plugin_x22x_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1101 | 376 | udevrules_DATA += x22x/77-mm-x22x-port-types.rules | ||
1102 | 377 | |||
1103 | 378 | # Pantech | ||
1104 | 379 | libmm_plugin_pantech_la_SOURCES = \ | ||
1105 | 380 | pantech/mm-plugin-pantech.c \ | ||
1106 | 381 | pantech/mm-plugin-pantech.h \ | ||
1107 | 382 | pantech/mm-sim-pantech.c \ | ||
1108 | 383 | pantech/mm-sim-pantech.h \ | ||
1109 | 384 | pantech/mm-broadband-modem-pantech.c \ | ||
1110 | 385 | pantech/mm-broadband-modem-pantech.h | ||
1111 | 386 | libmm_plugin_pantech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1112 | 387 | libmm_plugin_pantech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1113 | 388 | |||
1114 | 389 | # Samsung modem | ||
1115 | 390 | libmm_plugin_samsung_la_SOURCES = \ | ||
1116 | 391 | samsung/mm-plugin-samsung.c \ | ||
1117 | 392 | samsung/mm-plugin-samsung.h \ | ||
1118 | 393 | samsung/mm-broadband-modem-samsung.c \ | ||
1119 | 394 | samsung/mm-broadband-modem-samsung.h | ||
1120 | 395 | libmm_plugin_samsung_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
1121 | 396 | libmm_plugin_samsung_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1122 | 397 | libmm_plugin_samsung_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
1123 | 398 | |||
1124 | 399 | # Cinterion (previously Siemens) modem | ||
1125 | 400 | libmm_plugin_cinterion_la_SOURCES = \ | ||
1126 | 401 | cinterion/mm-plugin-cinterion.c \ | ||
1127 | 402 | cinterion/mm-plugin-cinterion.h \ | ||
1128 | 403 | cinterion/mm-modem-helpers-cinterion.c \ | ||
1129 | 404 | cinterion/mm-modem-helpers-cinterion.h \ | ||
1130 | 405 | cinterion/mm-common-cinterion.c \ | ||
1131 | 406 | cinterion/mm-common-cinterion.h \ | ||
1132 | 407 | cinterion/mm-broadband-modem-cinterion.c \ | ||
1133 | 408 | cinterion/mm-broadband-modem-cinterion.h | ||
1134 | 409 | |||
1135 | 410 | if WITH_QMI | ||
1136 | 411 | libmm_plugin_cinterion_la_SOURCES += \ | ||
1137 | 412 | cinterion/mm-broadband-modem-qmi-cinterion.c \ | ||
1138 | 413 | cinterion/mm-broadband-modem-qmi-cinterion.h | ||
1139 | 414 | endif | ||
1140 | 415 | |||
1141 | 416 | libmm_plugin_cinterion_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1142 | 417 | libmm_plugin_cinterion_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1143 | 418 | |||
1144 | 419 | udevrules_DATA += cinterion/77-mm-cinterion-port-types.rules | ||
1145 | 420 | |||
1146 | 421 | noinst_PROGRAMS += test-modem-helpers-cinterion | ||
1147 | 422 | test_modem_helpers_cinterion_SOURCES = \ | ||
1148 | 423 | cinterion/mm-modem-helpers-cinterion.c \ | ||
1149 | 424 | cinterion/mm-modem-helpers-cinterion.h \ | ||
1150 | 425 | cinterion/tests/test-modem-helpers-cinterion.c | ||
1151 | 426 | test_modem_helpers_cinterion_CPPFLAGS = \ | ||
1152 | 427 | -I$(top_srcdir)/plugins/cinterion \ | ||
1153 | 428 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1154 | 429 | test_modem_helpers_cinterion_LDADD = \ | ||
1155 | 430 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
1156 | 431 | $(top_builddir)/src/libmodem-helpers.la | ||
1157 | 432 | test_modem_helpers_cinterion_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1158 | 433 | |||
1159 | 434 | # Iridium modem | ||
1160 | 435 | libmm_plugin_iridium_la_SOURCES = \ | ||
1161 | 436 | iridium/mm-plugin-iridium.c \ | ||
1162 | 437 | iridium/mm-plugin-iridium.h \ | ||
1163 | 438 | iridium/mm-broadband-modem-iridium.c \ | ||
1164 | 439 | iridium/mm-broadband-modem-iridium.h \ | ||
1165 | 440 | iridium/mm-bearer-iridium.c \ | ||
1166 | 441 | iridium/mm-bearer-iridium.h \ | ||
1167 | 442 | iridium/mm-sim-iridium.c \ | ||
1168 | 443 | iridium/mm-sim-iridium.h | ||
1169 | 444 | libmm_plugin_iridium_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1170 | 445 | libmm_plugin_iridium_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1171 | 446 | |||
1172 | 447 | # Common Novatel modem support library | ||
1173 | 448 | noinst_LTLIBRARIES += libmm-utils-novatel.la | ||
1174 | 449 | libmm_utils_novatel_la_SOURCES = \ | ||
1175 | 450 | novatel/mm-common-novatel.c \ | ||
1176 | 451 | novatel/mm-common-novatel.h \ | ||
1177 | 452 | novatel/mm-broadband-modem-novatel.c \ | ||
1178 | 453 | novatel/mm-broadband-modem-novatel.h | ||
1179 | 454 | libmm_utils_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1180 | 455 | libmm_utils_novatel_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
1181 | 456 | |||
1182 | 457 | NOVATEL_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/novatel | ||
1183 | 458 | NOVATEL_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-novatel.la | ||
1184 | 459 | |||
1185 | 460 | # Novatel LTE modem | ||
1186 | 461 | libmm_plugin_novatel_lte_la_SOURCES = \ | ||
1187 | 462 | novatel/mm-plugin-novatel-lte.c \ | ||
1188 | 463 | novatel/mm-plugin-novatel-lte.h \ | ||
1189 | 464 | novatel/mm-broadband-modem-novatel-lte.c \ | ||
1190 | 465 | novatel/mm-broadband-modem-novatel-lte.h \ | ||
1191 | 466 | novatel/mm-broadband-bearer-novatel-lte.c \ | ||
1192 | 467 | novatel/mm-broadband-bearer-novatel-lte.h \ | ||
1193 | 468 | novatel/mm-sim-novatel-lte.c \ | ||
1194 | 469 | novatel/mm-sim-novatel-lte.h | ||
1195 | 470 | libmm_plugin_novatel_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1196 | 471 | libmm_plugin_novatel_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1197 | 472 | |||
1198 | 473 | # Novatel non-LTE modem | ||
1199 | 474 | libmm_plugin_novatel_la_SOURCES = \ | ||
1200 | 475 | novatel/mm-plugin-novatel.c \ | ||
1201 | 476 | novatel/mm-plugin-novatel.h | ||
1202 | 477 | libmm_plugin_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(NOVATEL_COMMON_COMPILER_FLAGS) | ||
1203 | 478 | libmm_plugin_novatel_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1204 | 479 | libmm_plugin_novatel_la_LIBADD = $(NOVATEL_COMMON_LIBADD_FLAGS) | ||
1205 | 480 | |||
1206 | 481 | # Altair LTE modem | ||
1207 | 482 | libmm_plugin_altair_lte_la_SOURCES = \ | ||
1208 | 483 | altair/mm-modem-helpers-altair-lte.c \ | ||
1209 | 484 | altair/mm-modem-helpers-altair-lte.h \ | ||
1210 | 485 | altair/mm-plugin-altair-lte.c \ | ||
1211 | 486 | altair/mm-plugin-altair-lte.h \ | ||
1212 | 487 | altair/mm-broadband-modem-altair-lte.c \ | ||
1213 | 488 | altair/mm-broadband-modem-altair-lte.h \ | ||
1214 | 489 | altair/mm-broadband-bearer-altair-lte.c \ | ||
1215 | 490 | altair/mm-broadband-bearer-altair-lte.h | ||
1216 | 491 | libmm_plugin_altair_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1217 | 492 | libmm_plugin_altair_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1218 | 493 | |||
1219 | 494 | noinst_PROGRAMS += test-modem-helpers-altair-lte | ||
1220 | 495 | test_modem_helpers_altair_lte_SOURCES = \ | ||
1221 | 496 | altair/mm-modem-helpers-altair-lte.c \ | ||
1222 | 497 | altair/mm-modem-helpers-altair-lte.h \ | ||
1223 | 498 | altair/tests/test-modem-helpers-altair-lte.c | ||
1224 | 499 | test_modem_helpers_altair_lte_CPPFLAGS = \ | ||
1225 | 500 | -I$(top_srcdir)/plugins/altair \ | ||
1226 | 501 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1227 | 502 | test_modem_helpers_altair_lte_LDADD = $(top_builddir)/libmm-glib/libmm-glib.la | ||
1228 | 503 | test_modem_helpers_altair_lte_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1229 | 504 | |||
1230 | 505 | |||
1231 | 506 | # VIA modem | ||
1232 | 507 | libmm_plugin_via_la_SOURCES = \ | ||
1233 | 508 | via/mm-plugin-via.c \ | ||
1234 | 509 | via/mm-plugin-via.h \ | ||
1235 | 510 | via/mm-broadband-modem-via.c \ | ||
1236 | 511 | via/mm-broadband-modem-via.h | ||
1237 | 512 | libmm_plugin_via_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1238 | 513 | libmm_plugin_via_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1239 | 514 | |||
1240 | 515 | # Telit modem | ||
1241 | 516 | libmm_plugin_telit_la_SOURCES = \ | ||
1242 | 517 | telit/mm-plugin-telit.c \ | ||
1243 | 518 | telit/mm-plugin-telit.h \ | ||
1244 | 519 | telit/mm-broadband-modem-telit.c \ | ||
1245 | 520 | telit/mm-broadband-modem-telit.h | ||
1246 | 521 | libmm_plugin_telit_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1247 | 522 | libmm_plugin_telit_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1248 | 523 | udevrules_DATA += telit/77-mm-telit-port-types.rules | ||
1249 | 524 | |||
1250 | 525 | # MTK | ||
1251 | 526 | libmm_plugin_mtk_la_SOURCES = \ | ||
1252 | 527 | mtk/mm-plugin-mtk.c \ | ||
1253 | 528 | mtk/mm-plugin-mtk.h \ | ||
1254 | 529 | mtk/mm-broadband-modem-mtk.h \ | ||
1255 | 530 | mtk/mm-broadband-modem-mtk.c | ||
1256 | 531 | libmm_plugin_mtk_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1257 | 532 | libmm_plugin_mtk_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1258 | 533 | udevrules_DATA += mtk/77-mm-mtk-port-types.rules | ||
1259 | 534 | |||
1260 | 535 | |||
1261 | 536 | # Additional files to include in the distribution | ||
1262 | 537 | EXTRA_DIST += \ | ||
1263 | 538 | $(udevrules_DATA) \ | ||
1264 | 539 | tests/gsm-port.conf | ||
1265 | 540 | |||
1266 | 541 | # Unit tests | ||
1267 | 542 | TEST_PROGS += $(noinst_PROGRAMS) | ||
1268 | 0 | 543 | ||
1269 | === added directory '.pc/new-sierra-legacy-plugin.patch' | |||
1270 | === added directory '.pc/new-sierra-legacy-plugin.patch/plugins' | |||
1271 | === added file '.pc/new-sierra-legacy-plugin.patch/plugins/Makefile.am' | |||
1272 | --- .pc/new-sierra-legacy-plugin.patch/plugins/Makefile.am 1970-01-01 00:00:00 +0000 | |||
1273 | +++ .pc/new-sierra-legacy-plugin.patch/plugins/Makefile.am 2015-10-09 10:06:57 +0000 | |||
1274 | @@ -0,0 +1,553 @@ | |||
1275 | 1 | |||
1276 | 2 | include $(top_srcdir)/gtester.make | ||
1277 | 3 | |||
1278 | 4 | # Common CPPFLAGS and LDFLAGS | ||
1279 | 5 | |||
1280 | 6 | PLUGIN_COMMON_COMPILER_FLAGS = \ | ||
1281 | 7 | $(MM_CFLAGS) \ | ||
1282 | 8 | $(GUDEV_CFLAGS) \ | ||
1283 | 9 | -I$(top_srcdir) \ | ||
1284 | 10 | -I$(top_srcdir)/src \ | ||
1285 | 11 | -I$(top_builddir)/src \ | ||
1286 | 12 | -I$(top_srcdir)/include \ | ||
1287 | 13 | -I$(top_builddir)/include \ | ||
1288 | 14 | -I$(top_srcdir)/libmm-glib \ | ||
1289 | 15 | -I$(top_srcdir)/libmm-glib/generated \ | ||
1290 | 16 | -I$(top_builddir)/libmm-glib/generated | ||
1291 | 17 | |||
1292 | 18 | PLUGIN_COMMON_LINKER_FLAGS = \ | ||
1293 | 19 | $(GUDEV_LIBS) \ | ||
1294 | 20 | $(MM_LIBS) \ | ||
1295 | 21 | -module \ | ||
1296 | 22 | -avoid-version | ||
1297 | 23 | |||
1298 | 24 | if WITH_QMI | ||
1299 | 25 | PLUGIN_COMMON_COMPILER_FLAGS += $(QMI_CFLAGS) | ||
1300 | 26 | PLUGIN_COMMON_LINKER_FLAGS += $(QMI_LIBS) | ||
1301 | 27 | endif | ||
1302 | 28 | |||
1303 | 29 | if WITH_MBIM | ||
1304 | 30 | PLUGIN_COMMON_COMPILER_FLAGS += $(MBIM_CFLAGS) | ||
1305 | 31 | PLUGIN_COMMON_LINKER_FLAGS += $(MBIM_LIBS) | ||
1306 | 32 | endif | ||
1307 | 33 | |||
1308 | 34 | # UDev rules | ||
1309 | 35 | udevrulesdir = $(UDEV_BASE_DIR)/rules.d | ||
1310 | 36 | udevrules_DATA = | ||
1311 | 37 | |||
1312 | 38 | # Unit tests | ||
1313 | 39 | noinst_PROGRAMS = | ||
1314 | 40 | |||
1315 | 41 | # Helper libs | ||
1316 | 42 | noinst_LTLIBRARIES = | ||
1317 | 43 | |||
1318 | 44 | ######################################## | ||
1319 | 45 | |||
1320 | 46 | # Common service test support | ||
1321 | 47 | |||
1322 | 48 | noinst_LTLIBRARIES += libmm-test-common.la | ||
1323 | 49 | |||
1324 | 50 | libmm_test_common_la_SOURCES = \ | ||
1325 | 51 | tests/test-fixture.h \ | ||
1326 | 52 | tests/test-fixture.c \ | ||
1327 | 53 | tests/test-port-context.h \ | ||
1328 | 54 | tests/test-port-context.c | ||
1329 | 55 | |||
1330 | 56 | libmm_test_common_la_CPPFLAGS = \ | ||
1331 | 57 | $(MM_CFLAGS) \ | ||
1332 | 58 | -I$(top_srcdir)/include \ | ||
1333 | 59 | -I$(top_builddir)/include \ | ||
1334 | 60 | -I$(top_srcdir)/libmm-glib \ | ||
1335 | 61 | -I$(top_srcdir)/libmm-glib/generated \ | ||
1336 | 62 | -I$(top_builddir)/libmm-glib/generated \ | ||
1337 | 63 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
1338 | 64 | -DTEST_SERVICES=\""$(abs_top_builddir)/data/tests"\" | ||
1339 | 65 | |||
1340 | 66 | libmm_test_common_la_LIBADD = \ | ||
1341 | 67 | ${top_builddir}/libmm-glib/generated/tests/libmm-test-generated.la \ | ||
1342 | 68 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
1343 | 69 | |||
1344 | 70 | TEST_COMMON_COMPILER_FLAGS = \ | ||
1345 | 71 | $(MM_CFLAGS) \ | ||
1346 | 72 | -I$(top_srcdir)/plugins/tests \ | ||
1347 | 73 | -I$(top_srcdir)/include \ | ||
1348 | 74 | -I$(top_builddir)/include \ | ||
1349 | 75 | -I$(top_srcdir)/libmm-glib \ | ||
1350 | 76 | -I$(top_srcdir)/libmm-glib/generated \ | ||
1351 | 77 | -I$(top_builddir)/libmm-glib/generated \ | ||
1352 | 78 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
1353 | 79 | -DCOMMON_GSM_PORT_CONF=\""$(abs_top_srcdir)/plugins/tests/gsm-port.conf"\" | ||
1354 | 80 | |||
1355 | 81 | TEST_COMMON_LIBADD_FLAGS = \ | ||
1356 | 82 | $(builddir)/libmm-test-common.la \ | ||
1357 | 83 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
1358 | 84 | |||
1359 | 85 | |||
1360 | 86 | ######################################## | ||
1361 | 87 | |||
1362 | 88 | # Icera-specific support | ||
1363 | 89 | noinst_LTLIBRARIES += libmm-utils-icera.la | ||
1364 | 90 | libmm_utils_icera_la_SOURCES = \ | ||
1365 | 91 | icera/mm-broadband-modem-icera.h \ | ||
1366 | 92 | icera/mm-broadband-modem-icera.c \ | ||
1367 | 93 | icera/mm-broadband-bearer-icera.h \ | ||
1368 | 94 | icera/mm-broadband-bearer-icera.c \ | ||
1369 | 95 | icera/mm-modem-helpers-icera.c \ | ||
1370 | 96 | icera/mm-modem-helpers-icera.h | ||
1371 | 97 | libmm_utils_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1372 | 98 | libmm_utils_icera_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
1373 | 99 | |||
1374 | 100 | ICERA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/icera | ||
1375 | 101 | ICERA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-icera.la | ||
1376 | 102 | |||
1377 | 103 | noinst_PROGRAMS += test-modem-helpers-icera | ||
1378 | 104 | test_modem_helpers_icera_SOURCES = \ | ||
1379 | 105 | icera/mm-modem-helpers-icera.c \ | ||
1380 | 106 | icera/mm-modem-helpers-icera.h \ | ||
1381 | 107 | icera/tests/test-modem-helpers-icera.c | ||
1382 | 108 | test_modem_helpers_icera_CPPFLAGS = \ | ||
1383 | 109 | -I$(top_srcdir)/plugins/icera \ | ||
1384 | 110 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1385 | 111 | test_modem_helpers_icera_LDADD = \ | ||
1386 | 112 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
1387 | 113 | $(top_builddir)/src/libmodem-helpers.la | ||
1388 | 114 | test_modem_helpers_icera_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1389 | 115 | |||
1390 | 116 | ######################################## | ||
1391 | 117 | |||
1392 | 118 | pkglib_LTLIBRARIES = \ | ||
1393 | 119 | libmm-plugin-generic.la \ | ||
1394 | 120 | libmm-plugin-nokia.la \ | ||
1395 | 121 | libmm-plugin-nokia-icera.la \ | ||
1396 | 122 | libmm-plugin-cinterion.la \ | ||
1397 | 123 | libmm-plugin-iridium.la \ | ||
1398 | 124 | libmm-plugin-gobi.la \ | ||
1399 | 125 | libmm-plugin-motorola.la \ | ||
1400 | 126 | libmm-plugin-novatel.la \ | ||
1401 | 127 | libmm-plugin-novatel-lte.la \ | ||
1402 | 128 | libmm-plugin-altair-lte.la \ | ||
1403 | 129 | libmm-plugin-samsung.la \ | ||
1404 | 130 | libmm-plugin-option.la \ | ||
1405 | 131 | libmm-plugin-hso.la \ | ||
1406 | 132 | libmm-plugin-anydata.la \ | ||
1407 | 133 | libmm-plugin-linktop.la \ | ||
1408 | 134 | libmm-plugin-simtech.la \ | ||
1409 | 135 | libmm-plugin-wavecom.la \ | ||
1410 | 136 | libmm-plugin-huawei.la \ | ||
1411 | 137 | libmm-plugin-longcheer.la \ | ||
1412 | 138 | libmm-plugin-x22x.la \ | ||
1413 | 139 | libmm-plugin-pantech.la \ | ||
1414 | 140 | libmm-plugin-zte.la \ | ||
1415 | 141 | libmm-plugin-sierra.la \ | ||
1416 | 142 | libmm-plugin-mbm.la \ | ||
1417 | 143 | libmm-plugin-via.la \ | ||
1418 | 144 | libmm-plugin-telit.la \ | ||
1419 | 145 | libmm-plugin-mtk.la | ||
1420 | 146 | |||
1421 | 147 | # Generic | ||
1422 | 148 | libmm_plugin_generic_la_SOURCES = \ | ||
1423 | 149 | generic/mm-plugin-generic.c \ | ||
1424 | 150 | generic/mm-plugin-generic.h | ||
1425 | 151 | libmm_plugin_generic_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1426 | 152 | libmm_plugin_generic_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1427 | 153 | |||
1428 | 154 | noinst_PROGRAMS += test-service-generic | ||
1429 | 155 | test_service_generic_SOURCES = generic/tests/test-service-generic.c | ||
1430 | 156 | test_service_generic_CPPFLAGS = $(TEST_COMMON_COMPILER_FLAGS) | ||
1431 | 157 | test_service_generic_LDADD = $(TEST_COMMON_LIBADD_FLAGS) | ||
1432 | 158 | test_service_generic_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1433 | 159 | |||
1434 | 160 | ## Motorola | ||
1435 | 161 | libmm_plugin_motorola_la_SOURCES = \ | ||
1436 | 162 | motorola/mm-plugin-motorola.c \ | ||
1437 | 163 | motorola/mm-plugin-motorola.h \ | ||
1438 | 164 | motorola/mm-broadband-modem-motorola.c \ | ||
1439 | 165 | motorola/mm-broadband-modem-motorola.h | ||
1440 | 166 | libmm_plugin_motorola_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1441 | 167 | libmm_plugin_motorola_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1442 | 168 | |||
1443 | 169 | # Gobi | ||
1444 | 170 | libmm_plugin_gobi_la_SOURCES = \ | ||
1445 | 171 | gobi/mm-plugin-gobi.c \ | ||
1446 | 172 | gobi/mm-plugin-gobi.h \ | ||
1447 | 173 | gobi/mm-broadband-modem-gobi.c \ | ||
1448 | 174 | gobi/mm-broadband-modem-gobi.h | ||
1449 | 175 | libmm_plugin_gobi_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1450 | 176 | libmm_plugin_gobi_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1451 | 177 | |||
1452 | 178 | # Huawei | ||
1453 | 179 | libmm_plugin_huawei_la_SOURCES = \ | ||
1454 | 180 | huawei/mm-plugin-huawei.c \ | ||
1455 | 181 | huawei/mm-plugin-huawei.h \ | ||
1456 | 182 | huawei/mm-modem-helpers-huawei.c \ | ||
1457 | 183 | huawei/mm-modem-helpers-huawei.h \ | ||
1458 | 184 | huawei/mm-sim-huawei.c \ | ||
1459 | 185 | huawei/mm-sim-huawei.h \ | ||
1460 | 186 | huawei/mm-broadband-modem-huawei.c \ | ||
1461 | 187 | huawei/mm-broadband-modem-huawei.h \ | ||
1462 | 188 | huawei/mm-broadband-bearer-huawei.c \ | ||
1463 | 189 | huawei/mm-broadband-bearer-huawei.h | ||
1464 | 190 | libmm_plugin_huawei_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1465 | 191 | libmm_plugin_huawei_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1466 | 192 | |||
1467 | 193 | udevrules_DATA += huawei/77-mm-huawei-net-port-types.rules | ||
1468 | 194 | |||
1469 | 195 | noinst_PROGRAMS += test-modem-helpers-huawei | ||
1470 | 196 | test_modem_helpers_huawei_SOURCES = \ | ||
1471 | 197 | huawei/mm-modem-helpers-huawei.c \ | ||
1472 | 198 | huawei/mm-modem-helpers-huawei.h \ | ||
1473 | 199 | huawei/tests/test-modem-helpers-huawei.c | ||
1474 | 200 | test_modem_helpers_huawei_CPPFLAGS = \ | ||
1475 | 201 | -I$(top_srcdir)/plugins/huawei \ | ||
1476 | 202 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1477 | 203 | test_modem_helpers_huawei_LDADD = \ | ||
1478 | 204 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
1479 | 205 | $(top_builddir)/src/libmodem-helpers.la | ||
1480 | 206 | test_modem_helpers_huawei_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1481 | 207 | |||
1482 | 208 | # Common Mbm modem support library | ||
1483 | 209 | noinst_LTLIBRARIES += libmm-utils-mbm.la | ||
1484 | 210 | libmm_utils_mbm_la_SOURCES = \ | ||
1485 | 211 | mbm/mm-broadband-modem-mbm.c \ | ||
1486 | 212 | mbm/mm-broadband-modem-mbm.h \ | ||
1487 | 213 | mbm/mm-broadband-bearer-mbm.c \ | ||
1488 | 214 | mbm/mm-broadband-bearer-mbm.h \ | ||
1489 | 215 | mbm/mm-modem-helpers-mbm.c \ | ||
1490 | 216 | mbm/mm-modem-helpers-mbm.h \ | ||
1491 | 217 | mbm/mm-sim-mbm.c \ | ||
1492 | 218 | mbm/mm-sim-mbm.h | ||
1493 | 219 | libmm_utils_mbm_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1494 | 220 | libmm_utils_mbm_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
1495 | 221 | |||
1496 | 222 | MBM_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/mbm | ||
1497 | 223 | MBM_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-mbm.la | ||
1498 | 224 | |||
1499 | 225 | # MBM | ||
1500 | 226 | libmm_plugin_mbm_la_SOURCES = \ | ||
1501 | 227 | mbm/mm-plugin-mbm.c \ | ||
1502 | 228 | mbm/mm-plugin-mbm.h | ||
1503 | 229 | libmm_plugin_mbm_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(MBM_COMMON_COMPILER_FLAGS) | ||
1504 | 230 | libmm_plugin_mbm_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1505 | 231 | libmm_plugin_mbm_la_LIBADD = $(MBM_COMMON_LIBADD_FLAGS) | ||
1506 | 232 | |||
1507 | 233 | udevrules_DATA += mbm/77-mm-ericsson-mbm.rules | ||
1508 | 234 | |||
1509 | 235 | noinst_PROGRAMS += test-modem-helpers-mbm | ||
1510 | 236 | test_modem_helpers_mbm_SOURCES = \ | ||
1511 | 237 | mbm/mm-modem-helpers-mbm.c \ | ||
1512 | 238 | mbm/mm-modem-helpers-mbm.h \ | ||
1513 | 239 | mbm/tests/test-modem-helpers-mbm.c | ||
1514 | 240 | test_modem_helpers_mbm_CPPFLAGS = \ | ||
1515 | 241 | -I$(top_srcdir)/plugins/mbm \ | ||
1516 | 242 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1517 | 243 | test_modem_helpers_mbm_LDADD = \ | ||
1518 | 244 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
1519 | 245 | $(top_builddir)/src/libmodem-helpers.la | ||
1520 | 246 | test_modem_helpers_mbm_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1521 | 247 | |||
1522 | 248 | # Option | ||
1523 | 249 | libmm_plugin_option_la_SOURCES = \ | ||
1524 | 250 | option/mm-plugin-option.c \ | ||
1525 | 251 | option/mm-plugin-option.h \ | ||
1526 | 252 | option/mm-broadband-modem-option.c \ | ||
1527 | 253 | option/mm-broadband-modem-option.h | ||
1528 | 254 | libmm_plugin_option_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1529 | 255 | libmm_plugin_option_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1530 | 256 | |||
1531 | 257 | # HSO | ||
1532 | 258 | libmm_plugin_hso_la_SOURCES = \ | ||
1533 | 259 | option/mm-plugin-hso.c \ | ||
1534 | 260 | option/mm-plugin-hso.h \ | ||
1535 | 261 | option/mm-broadband-modem-option.c \ | ||
1536 | 262 | option/mm-broadband-modem-option.h \ | ||
1537 | 263 | option/mm-broadband-bearer-hso.c \ | ||
1538 | 264 | option/mm-broadband-bearer-hso.h \ | ||
1539 | 265 | option/mm-broadband-modem-hso.c \ | ||
1540 | 266 | option/mm-broadband-modem-hso.h | ||
1541 | 267 | libmm_plugin_hso_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1542 | 268 | libmm_plugin_hso_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1543 | 269 | |||
1544 | 270 | # Common Sierra modem support library | ||
1545 | 271 | noinst_LTLIBRARIES += libmm-utils-sierra.la | ||
1546 | 272 | libmm_utils_sierra_la_SOURCES = \ | ||
1547 | 273 | sierra/mm-common-sierra.c \ | ||
1548 | 274 | sierra/mm-common-sierra.h \ | ||
1549 | 275 | sierra/mm-sim-sierra.c \ | ||
1550 | 276 | sierra/mm-sim-sierra.h \ | ||
1551 | 277 | sierra/mm-broadband-bearer-sierra.c \ | ||
1552 | 278 | sierra/mm-broadband-bearer-sierra.h \ | ||
1553 | 279 | sierra/mm-broadband-modem-sierra.c \ | ||
1554 | 280 | sierra/mm-broadband-modem-sierra.h | ||
1555 | 281 | libmm_utils_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1556 | 282 | libmm_utils_sierra_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
1557 | 283 | |||
1558 | 284 | SIERRA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/sierra | ||
1559 | 285 | SIERRA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-sierra.la | ||
1560 | 286 | |||
1561 | 287 | # Sierra | ||
1562 | 288 | libmm_plugin_sierra_la_SOURCES = \ | ||
1563 | 289 | sierra/mm-plugin-sierra.c \ | ||
1564 | 290 | sierra/mm-plugin-sierra.h \ | ||
1565 | 291 | sierra/mm-broadband-modem-sierra-icera.c \ | ||
1566 | 292 | sierra/mm-broadband-modem-sierra-icera.h | ||
1567 | 293 | libmm_plugin_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) $(SIERRA_COMMON_COMPILER_FLAGS) | ||
1568 | 294 | libmm_plugin_sierra_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1569 | 295 | libmm_plugin_sierra_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) $(SIERRA_COMMON_LIBADD_FLAGS) | ||
1570 | 296 | |||
1571 | 297 | # Wavecom (Sierra Airlink) | ||
1572 | 298 | libmm_plugin_wavecom_la_SOURCES = \ | ||
1573 | 299 | wavecom/mm-plugin-wavecom.c \ | ||
1574 | 300 | wavecom/mm-plugin-wavecom.h \ | ||
1575 | 301 | wavecom/mm-broadband-modem-wavecom.c \ | ||
1576 | 302 | wavecom/mm-broadband-modem-wavecom.h | ||
1577 | 303 | libmm_plugin_wavecom_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1578 | 304 | libmm_plugin_wavecom_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1579 | 305 | |||
1580 | 306 | # Nokia | ||
1581 | 307 | libmm_plugin_nokia_la_SOURCES = \ | ||
1582 | 308 | nokia/mm-plugin-nokia.c \ | ||
1583 | 309 | nokia/mm-plugin-nokia.h \ | ||
1584 | 310 | nokia/mm-sim-nokia.c \ | ||
1585 | 311 | nokia/mm-sim-nokia.h \ | ||
1586 | 312 | nokia/mm-broadband-modem-nokia.c \ | ||
1587 | 313 | nokia/mm-broadband-modem-nokia.h | ||
1588 | 314 | libmm_plugin_nokia_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1589 | 315 | libmm_plugin_nokia_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1590 | 316 | |||
1591 | 317 | # Nokia (Icera) | ||
1592 | 318 | libmm_plugin_nokia_icera_la_SOURCES = \ | ||
1593 | 319 | nokia/mm-plugin-nokia-icera.c \ | ||
1594 | 320 | nokia/mm-plugin-nokia-icera.h | ||
1595 | 321 | libmm_plugin_nokia_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
1596 | 322 | libmm_plugin_nokia_icera_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1597 | 323 | libmm_plugin_nokia_icera_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
1598 | 324 | udevrules_DATA += nokia/77-mm-nokia-port-types.rules | ||
1599 | 325 | |||
1600 | 326 | # Zte | ||
1601 | 327 | libmm_plugin_zte_la_SOURCES = \ | ||
1602 | 328 | zte/mm-plugin-zte.c \ | ||
1603 | 329 | zte/mm-plugin-zte.h \ | ||
1604 | 330 | zte/mm-common-zte.h \ | ||
1605 | 331 | zte/mm-common-zte.c \ | ||
1606 | 332 | zte/mm-broadband-modem-zte.h \ | ||
1607 | 333 | zte/mm-broadband-modem-zte.c \ | ||
1608 | 334 | zte/mm-broadband-modem-zte-icera.h \ | ||
1609 | 335 | zte/mm-broadband-modem-zte-icera.c | ||
1610 | 336 | libmm_plugin_zte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
1611 | 337 | libmm_plugin_zte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1612 | 338 | libmm_plugin_zte_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
1613 | 339 | udevrules_DATA += zte/77-mm-zte-port-types.rules | ||
1614 | 340 | |||
1615 | 341 | # Longcheer (and rebranded dongles) | ||
1616 | 342 | libmm_plugin_longcheer_la_SOURCES = \ | ||
1617 | 343 | longcheer/mm-plugin-longcheer.c \ | ||
1618 | 344 | longcheer/mm-plugin-longcheer.h \ | ||
1619 | 345 | longcheer/mm-broadband-modem-longcheer.h \ | ||
1620 | 346 | longcheer/mm-broadband-modem-longcheer.c | ||
1621 | 347 | libmm_plugin_longcheer_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1622 | 348 | libmm_plugin_longcheer_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1623 | 349 | udevrules_DATA += longcheer/77-mm-longcheer-port-types.rules | ||
1624 | 350 | |||
1625 | 351 | # AnyData CDMA | ||
1626 | 352 | libmm_plugin_anydata_la_SOURCES = \ | ||
1627 | 353 | anydata/mm-plugin-anydata.c \ | ||
1628 | 354 | anydata/mm-plugin-anydata.h \ | ||
1629 | 355 | anydata/mm-broadband-modem-anydata.h \ | ||
1630 | 356 | anydata/mm-broadband-modem-anydata.c | ||
1631 | 357 | libmm_plugin_anydata_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1632 | 358 | libmm_plugin_anydata_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1633 | 359 | |||
1634 | 360 | # Linktop CDMA | ||
1635 | 361 | libmm_plugin_linktop_la_SOURCES = \ | ||
1636 | 362 | linktop/mm-plugin-linktop.c \ | ||
1637 | 363 | linktop/mm-plugin-linktop.h \ | ||
1638 | 364 | linktop/mm-broadband-modem-linktop.h \ | ||
1639 | 365 | linktop/mm-broadband-modem-linktop.c | ||
1640 | 366 | libmm_plugin_linktop_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1641 | 367 | libmm_plugin_linktop_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1642 | 368 | |||
1643 | 369 | # SimTech | ||
1644 | 370 | libmm_plugin_simtech_la_SOURCES = \ | ||
1645 | 371 | simtech/mm-plugin-simtech.c \ | ||
1646 | 372 | simtech/mm-plugin-simtech.h \ | ||
1647 | 373 | simtech/mm-broadband-modem-simtech.h \ | ||
1648 | 374 | simtech/mm-broadband-modem-simtech.c | ||
1649 | 375 | libmm_plugin_simtech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1650 | 376 | libmm_plugin_simtech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1651 | 377 | udevrules_DATA += simtech/77-mm-simtech-port-types.rules | ||
1652 | 378 | |||
1653 | 379 | # Alcatel/TCT/JRD x220D and possibly others | ||
1654 | 380 | libmm_plugin_x22x_la_SOURCES = \ | ||
1655 | 381 | x22x/mm-plugin-x22x.c \ | ||
1656 | 382 | x22x/mm-plugin-x22x.h \ | ||
1657 | 383 | x22x/mm-broadband-modem-x22x.h \ | ||
1658 | 384 | x22x/mm-broadband-modem-x22x.c | ||
1659 | 385 | libmm_plugin_x22x_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1660 | 386 | libmm_plugin_x22x_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1661 | 387 | udevrules_DATA += x22x/77-mm-x22x-port-types.rules | ||
1662 | 388 | |||
1663 | 389 | # Pantech | ||
1664 | 390 | libmm_plugin_pantech_la_SOURCES = \ | ||
1665 | 391 | pantech/mm-plugin-pantech.c \ | ||
1666 | 392 | pantech/mm-plugin-pantech.h \ | ||
1667 | 393 | pantech/mm-sim-pantech.c \ | ||
1668 | 394 | pantech/mm-sim-pantech.h \ | ||
1669 | 395 | pantech/mm-broadband-modem-pantech.c \ | ||
1670 | 396 | pantech/mm-broadband-modem-pantech.h | ||
1671 | 397 | libmm_plugin_pantech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1672 | 398 | libmm_plugin_pantech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1673 | 399 | |||
1674 | 400 | # Samsung modem | ||
1675 | 401 | libmm_plugin_samsung_la_SOURCES = \ | ||
1676 | 402 | samsung/mm-plugin-samsung.c \ | ||
1677 | 403 | samsung/mm-plugin-samsung.h \ | ||
1678 | 404 | samsung/mm-broadband-modem-samsung.c \ | ||
1679 | 405 | samsung/mm-broadband-modem-samsung.h | ||
1680 | 406 | libmm_plugin_samsung_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
1681 | 407 | libmm_plugin_samsung_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1682 | 408 | libmm_plugin_samsung_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
1683 | 409 | |||
1684 | 410 | # Cinterion (previously Siemens) modem | ||
1685 | 411 | libmm_plugin_cinterion_la_SOURCES = \ | ||
1686 | 412 | cinterion/mm-plugin-cinterion.c \ | ||
1687 | 413 | cinterion/mm-plugin-cinterion.h \ | ||
1688 | 414 | cinterion/mm-modem-helpers-cinterion.c \ | ||
1689 | 415 | cinterion/mm-modem-helpers-cinterion.h \ | ||
1690 | 416 | cinterion/mm-common-cinterion.c \ | ||
1691 | 417 | cinterion/mm-common-cinterion.h \ | ||
1692 | 418 | cinterion/mm-broadband-modem-cinterion.c \ | ||
1693 | 419 | cinterion/mm-broadband-modem-cinterion.h | ||
1694 | 420 | |||
1695 | 421 | if WITH_QMI | ||
1696 | 422 | libmm_plugin_cinterion_la_SOURCES += \ | ||
1697 | 423 | cinterion/mm-broadband-modem-qmi-cinterion.c \ | ||
1698 | 424 | cinterion/mm-broadband-modem-qmi-cinterion.h | ||
1699 | 425 | endif | ||
1700 | 426 | |||
1701 | 427 | libmm_plugin_cinterion_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1702 | 428 | libmm_plugin_cinterion_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1703 | 429 | |||
1704 | 430 | udevrules_DATA += cinterion/77-mm-cinterion-port-types.rules | ||
1705 | 431 | |||
1706 | 432 | noinst_PROGRAMS += test-modem-helpers-cinterion | ||
1707 | 433 | test_modem_helpers_cinterion_SOURCES = \ | ||
1708 | 434 | cinterion/mm-modem-helpers-cinterion.c \ | ||
1709 | 435 | cinterion/mm-modem-helpers-cinterion.h \ | ||
1710 | 436 | cinterion/tests/test-modem-helpers-cinterion.c | ||
1711 | 437 | test_modem_helpers_cinterion_CPPFLAGS = \ | ||
1712 | 438 | -I$(top_srcdir)/plugins/cinterion \ | ||
1713 | 439 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1714 | 440 | test_modem_helpers_cinterion_LDADD = \ | ||
1715 | 441 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
1716 | 442 | $(top_builddir)/src/libmodem-helpers.la | ||
1717 | 443 | test_modem_helpers_cinterion_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1718 | 444 | |||
1719 | 445 | # Iridium modem | ||
1720 | 446 | libmm_plugin_iridium_la_SOURCES = \ | ||
1721 | 447 | iridium/mm-plugin-iridium.c \ | ||
1722 | 448 | iridium/mm-plugin-iridium.h \ | ||
1723 | 449 | iridium/mm-broadband-modem-iridium.c \ | ||
1724 | 450 | iridium/mm-broadband-modem-iridium.h \ | ||
1725 | 451 | iridium/mm-bearer-iridium.c \ | ||
1726 | 452 | iridium/mm-bearer-iridium.h \ | ||
1727 | 453 | iridium/mm-sim-iridium.c \ | ||
1728 | 454 | iridium/mm-sim-iridium.h | ||
1729 | 455 | libmm_plugin_iridium_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1730 | 456 | libmm_plugin_iridium_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1731 | 457 | |||
1732 | 458 | # Common Novatel modem support library | ||
1733 | 459 | noinst_LTLIBRARIES += libmm-utils-novatel.la | ||
1734 | 460 | libmm_utils_novatel_la_SOURCES = \ | ||
1735 | 461 | novatel/mm-common-novatel.c \ | ||
1736 | 462 | novatel/mm-common-novatel.h \ | ||
1737 | 463 | novatel/mm-broadband-modem-novatel.c \ | ||
1738 | 464 | novatel/mm-broadband-modem-novatel.h | ||
1739 | 465 | libmm_utils_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1740 | 466 | libmm_utils_novatel_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
1741 | 467 | |||
1742 | 468 | NOVATEL_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/novatel | ||
1743 | 469 | NOVATEL_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-novatel.la | ||
1744 | 470 | |||
1745 | 471 | # Novatel LTE modem | ||
1746 | 472 | libmm_plugin_novatel_lte_la_SOURCES = \ | ||
1747 | 473 | novatel/mm-plugin-novatel-lte.c \ | ||
1748 | 474 | novatel/mm-plugin-novatel-lte.h \ | ||
1749 | 475 | novatel/mm-broadband-modem-novatel-lte.c \ | ||
1750 | 476 | novatel/mm-broadband-modem-novatel-lte.h \ | ||
1751 | 477 | novatel/mm-broadband-bearer-novatel-lte.c \ | ||
1752 | 478 | novatel/mm-broadband-bearer-novatel-lte.h \ | ||
1753 | 479 | novatel/mm-sim-novatel-lte.c \ | ||
1754 | 480 | novatel/mm-sim-novatel-lte.h | ||
1755 | 481 | libmm_plugin_novatel_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1756 | 482 | libmm_plugin_novatel_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1757 | 483 | |||
1758 | 484 | # Novatel non-LTE modem | ||
1759 | 485 | libmm_plugin_novatel_la_SOURCES = \ | ||
1760 | 486 | novatel/mm-plugin-novatel.c \ | ||
1761 | 487 | novatel/mm-plugin-novatel.h | ||
1762 | 488 | libmm_plugin_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(NOVATEL_COMMON_COMPILER_FLAGS) | ||
1763 | 489 | libmm_plugin_novatel_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1764 | 490 | libmm_plugin_novatel_la_LIBADD = $(NOVATEL_COMMON_LIBADD_FLAGS) | ||
1765 | 491 | |||
1766 | 492 | # Altair LTE modem | ||
1767 | 493 | libmm_plugin_altair_lte_la_SOURCES = \ | ||
1768 | 494 | altair/mm-modem-helpers-altair-lte.c \ | ||
1769 | 495 | altair/mm-modem-helpers-altair-lte.h \ | ||
1770 | 496 | altair/mm-plugin-altair-lte.c \ | ||
1771 | 497 | altair/mm-plugin-altair-lte.h \ | ||
1772 | 498 | altair/mm-broadband-modem-altair-lte.c \ | ||
1773 | 499 | altair/mm-broadband-modem-altair-lte.h \ | ||
1774 | 500 | altair/mm-broadband-bearer-altair-lte.c \ | ||
1775 | 501 | altair/mm-broadband-bearer-altair-lte.h | ||
1776 | 502 | libmm_plugin_altair_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1777 | 503 | libmm_plugin_altair_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1778 | 504 | |||
1779 | 505 | noinst_PROGRAMS += test-modem-helpers-altair-lte | ||
1780 | 506 | test_modem_helpers_altair_lte_SOURCES = \ | ||
1781 | 507 | altair/mm-modem-helpers-altair-lte.c \ | ||
1782 | 508 | altair/mm-modem-helpers-altair-lte.h \ | ||
1783 | 509 | altair/tests/test-modem-helpers-altair-lte.c | ||
1784 | 510 | test_modem_helpers_altair_lte_CPPFLAGS = \ | ||
1785 | 511 | -I$(top_srcdir)/plugins/altair \ | ||
1786 | 512 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1787 | 513 | test_modem_helpers_altair_lte_LDADD = $(top_builddir)/libmm-glib/libmm-glib.la | ||
1788 | 514 | test_modem_helpers_altair_lte_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1789 | 515 | |||
1790 | 516 | |||
1791 | 517 | # VIA modem | ||
1792 | 518 | libmm_plugin_via_la_SOURCES = \ | ||
1793 | 519 | via/mm-plugin-via.c \ | ||
1794 | 520 | via/mm-plugin-via.h \ | ||
1795 | 521 | via/mm-broadband-modem-via.c \ | ||
1796 | 522 | via/mm-broadband-modem-via.h | ||
1797 | 523 | libmm_plugin_via_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1798 | 524 | libmm_plugin_via_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1799 | 525 | |||
1800 | 526 | # Telit modem | ||
1801 | 527 | libmm_plugin_telit_la_SOURCES = \ | ||
1802 | 528 | telit/mm-plugin-telit.c \ | ||
1803 | 529 | telit/mm-plugin-telit.h \ | ||
1804 | 530 | telit/mm-broadband-modem-telit.c \ | ||
1805 | 531 | telit/mm-broadband-modem-telit.h | ||
1806 | 532 | libmm_plugin_telit_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1807 | 533 | libmm_plugin_telit_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1808 | 534 | udevrules_DATA += telit/77-mm-telit-port-types.rules | ||
1809 | 535 | |||
1810 | 536 | # MTK | ||
1811 | 537 | libmm_plugin_mtk_la_SOURCES = \ | ||
1812 | 538 | mtk/mm-plugin-mtk.c \ | ||
1813 | 539 | mtk/mm-plugin-mtk.h \ | ||
1814 | 540 | mtk/mm-broadband-modem-mtk.h \ | ||
1815 | 541 | mtk/mm-broadband-modem-mtk.c | ||
1816 | 542 | libmm_plugin_mtk_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
1817 | 543 | libmm_plugin_mtk_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
1818 | 544 | udevrules_DATA += mtk/77-mm-mtk-port-types.rules | ||
1819 | 545 | |||
1820 | 546 | |||
1821 | 547 | # Additional files to include in the distribution | ||
1822 | 548 | EXTRA_DIST += \ | ||
1823 | 549 | $(udevrules_DATA) \ | ||
1824 | 550 | tests/gsm-port.conf | ||
1825 | 551 | |||
1826 | 552 | # Unit tests | ||
1827 | 553 | TEST_PROGS += $(noinst_PROGRAMS) | ||
1828 | 0 | 554 | ||
1829 | === added directory '.pc/new-sierra-legacy-plugin.patch/plugins/sierra' | |||
1830 | === added file '.pc/new-sierra-legacy-plugin.patch/plugins/sierra/mm-plugin-sierra-legacy.c' | |||
1831 | === added file '.pc/new-sierra-legacy-plugin.patch/plugins/sierra/mm-plugin-sierra-legacy.h' | |||
1832 | === added file '.pc/new-sierra-legacy-plugin.patch/plugins/sierra/mm-plugin-sierra.c' | |||
1833 | --- .pc/new-sierra-legacy-plugin.patch/plugins/sierra/mm-plugin-sierra.c 1970-01-01 00:00:00 +0000 | |||
1834 | +++ .pc/new-sierra-legacy-plugin.patch/plugins/sierra/mm-plugin-sierra.c 2015-10-09 10:06:57 +0000 | |||
1835 | @@ -0,0 +1,129 @@ | |||
1836 | 1 | /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ | ||
1837 | 2 | /* | ||
1838 | 3 | * This program is free software; you can redistribute it and/or modify | ||
1839 | 4 | * it under the terms of the GNU General Public License as published by | ||
1840 | 5 | * the Free Software Foundation; either version 2 of the License, or | ||
1841 | 6 | * (at your option) any later version. | ||
1842 | 7 | * | ||
1843 | 8 | * This program is distributed in the hope that it will be useful, | ||
1844 | 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
1845 | 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
1846 | 11 | * GNU General Public License for more details: | ||
1847 | 12 | * | ||
1848 | 13 | * Copyright (C) 2008 - 2009 Novell, Inc. | ||
1849 | 14 | * Copyright (C) 2009 - 2012 Red Hat, Inc. | ||
1850 | 15 | * Copyright (C) 2012 Lanedo GmbH | ||
1851 | 16 | */ | ||
1852 | 17 | |||
1853 | 18 | #include <stdlib.h> | ||
1854 | 19 | #include <gmodule.h> | ||
1855 | 20 | |||
1856 | 21 | #define _LIBMM_INSIDE_MM | ||
1857 | 22 | #include <libmm-glib.h> | ||
1858 | 23 | |||
1859 | 24 | #include "mm-log.h" | ||
1860 | 25 | #include "mm-plugin-sierra.h" | ||
1861 | 26 | #include "mm-common-sierra.h" | ||
1862 | 27 | #include "mm-broadband-modem-sierra.h" | ||
1863 | 28 | #include "mm-broadband-modem-sierra-icera.h" | ||
1864 | 29 | |||
1865 | 30 | #if defined WITH_QMI | ||
1866 | 31 | #include "mm-broadband-modem-qmi.h" | ||
1867 | 32 | #endif | ||
1868 | 33 | |||
1869 | 34 | #if defined WITH_MBIM | ||
1870 | 35 | #include "mm-broadband-modem-mbim.h" | ||
1871 | 36 | #endif | ||
1872 | 37 | |||
1873 | 38 | G_DEFINE_TYPE (MMPluginSierra, mm_plugin_sierra, MM_TYPE_PLUGIN) | ||
1874 | 39 | |||
1875 | 40 | int mm_plugin_major_version = MM_PLUGIN_MAJOR_VERSION; | ||
1876 | 41 | int mm_plugin_minor_version = MM_PLUGIN_MINOR_VERSION; | ||
1877 | 42 | |||
1878 | 43 | /*****************************************************************************/ | ||
1879 | 44 | |||
1880 | 45 | static MMBaseModem * | ||
1881 | 46 | create_modem (MMPlugin *self, | ||
1882 | 47 | const gchar *sysfs_path, | ||
1883 | 48 | const gchar **drivers, | ||
1884 | 49 | guint16 vendor, | ||
1885 | 50 | guint16 product, | ||
1886 | 51 | GList *probes, | ||
1887 | 52 | GError **error) | ||
1888 | 53 | { | ||
1889 | 54 | #if defined WITH_QMI | ||
1890 | 55 | if (mm_port_probe_list_has_qmi_port (probes)) { | ||
1891 | 56 | mm_dbg ("QMI-powered Sierra modem found..."); | ||
1892 | 57 | return MM_BASE_MODEM (mm_broadband_modem_qmi_new (sysfs_path, | ||
1893 | 58 | drivers, | ||
1894 | 59 | mm_plugin_get_name (self), | ||
1895 | 60 | vendor, | ||
1896 | 61 | product)); | ||
1897 | 62 | } | ||
1898 | 63 | #endif | ||
1899 | 64 | |||
1900 | 65 | #if defined WITH_MBIM | ||
1901 | 66 | if (mm_port_probe_list_has_mbim_port (probes)) { | ||
1902 | 67 | mm_dbg ("MBIM-powered Sierra modem found..."); | ||
1903 | 68 | return MM_BASE_MODEM (mm_broadband_modem_mbim_new (sysfs_path, | ||
1904 | 69 | drivers, | ||
1905 | 70 | mm_plugin_get_name (self), | ||
1906 | 71 | vendor, | ||
1907 | 72 | product)); | ||
1908 | 73 | } | ||
1909 | 74 | #endif | ||
1910 | 75 | |||
1911 | 76 | if (mm_common_sierra_port_probe_list_is_icera (probes)) | ||
1912 | 77 | return MM_BASE_MODEM (mm_broadband_modem_sierra_icera_new (sysfs_path, | ||
1913 | 78 | drivers, | ||
1914 | 79 | mm_plugin_get_name (self), | ||
1915 | 80 | vendor, | ||
1916 | 81 | product)); | ||
1917 | 82 | |||
1918 | 83 | return MM_BASE_MODEM (mm_broadband_modem_sierra_new (sysfs_path, | ||
1919 | 84 | drivers, | ||
1920 | 85 | mm_plugin_get_name (self), | ||
1921 | 86 | vendor, | ||
1922 | 87 | product)); | ||
1923 | 88 | } | ||
1924 | 89 | |||
1925 | 90 | /*****************************************************************************/ | ||
1926 | 91 | |||
1927 | 92 | G_MODULE_EXPORT MMPlugin * | ||
1928 | 93 | mm_plugin_create (void) | ||
1929 | 94 | { | ||
1930 | 95 | static const gchar *subsystems[] = { "tty", "net", "usb", NULL }; | ||
1931 | 96 | static const gchar *drivers[] = { "sierra", "sierra_net", NULL }; | ||
1932 | 97 | static const MMAsyncMethod custom_init = { | ||
1933 | 98 | .async = G_CALLBACK (mm_common_sierra_custom_init), | ||
1934 | 99 | .finish = G_CALLBACK (mm_common_sierra_custom_init_finish), | ||
1935 | 100 | }; | ||
1936 | 101 | |||
1937 | 102 | return MM_PLUGIN ( | ||
1938 | 103 | g_object_new (MM_TYPE_PLUGIN_SIERRA, | ||
1939 | 104 | MM_PLUGIN_NAME, "Sierra", | ||
1940 | 105 | MM_PLUGIN_ALLOWED_SUBSYSTEMS, subsystems, | ||
1941 | 106 | MM_PLUGIN_ALLOWED_DRIVERS, drivers, | ||
1942 | 107 | MM_PLUGIN_ALLOWED_AT, TRUE, | ||
1943 | 108 | MM_PLUGIN_ALLOWED_QCDM, TRUE, | ||
1944 | 109 | MM_PLUGIN_ALLOWED_QMI, TRUE, | ||
1945 | 110 | MM_PLUGIN_ALLOWED_MBIM, TRUE, | ||
1946 | 111 | MM_PLUGIN_CUSTOM_INIT, &custom_init, | ||
1947 | 112 | MM_PLUGIN_ICERA_PROBE, TRUE, | ||
1948 | 113 | MM_PLUGIN_REMOVE_ECHO, FALSE, | ||
1949 | 114 | NULL)); | ||
1950 | 115 | } | ||
1951 | 116 | |||
1952 | 117 | static void | ||
1953 | 118 | mm_plugin_sierra_init (MMPluginSierra *self) | ||
1954 | 119 | { | ||
1955 | 120 | } | ||
1956 | 121 | |||
1957 | 122 | static void | ||
1958 | 123 | mm_plugin_sierra_class_init (MMPluginSierraClass *klass) | ||
1959 | 124 | { | ||
1960 | 125 | MMPluginClass *plugin_class = MM_PLUGIN_CLASS (klass); | ||
1961 | 126 | |||
1962 | 127 | plugin_class->create_modem = create_modem; | ||
1963 | 128 | plugin_class->grab_port = mm_common_sierra_grab_port; | ||
1964 | 129 | } | ||
1965 | 0 | 130 | ||
1966 | === added directory '.pc/novatel-common-library.patch' | |||
1967 | === added directory '.pc/novatel-common-library.patch/plugins' | |||
1968 | === added file '.pc/novatel-common-library.patch/plugins/Makefile.am' | |||
1969 | --- .pc/novatel-common-library.patch/plugins/Makefile.am 1970-01-01 00:00:00 +0000 | |||
1970 | +++ .pc/novatel-common-library.patch/plugins/Makefile.am 2015-10-09 10:06:57 +0000 | |||
1971 | @@ -0,0 +1,523 @@ | |||
1972 | 1 | |||
1973 | 2 | include $(top_srcdir)/gtester.make | ||
1974 | 3 | |||
1975 | 4 | # Common CPPFLAGS and LDFLAGS | ||
1976 | 5 | |||
1977 | 6 | PLUGIN_COMMON_COMPILER_FLAGS = \ | ||
1978 | 7 | $(MM_CFLAGS) \ | ||
1979 | 8 | $(GUDEV_CFLAGS) \ | ||
1980 | 9 | -I$(top_srcdir) \ | ||
1981 | 10 | -I$(top_srcdir)/src \ | ||
1982 | 11 | -I$(top_builddir)/src \ | ||
1983 | 12 | -I$(top_srcdir)/include \ | ||
1984 | 13 | -I$(top_builddir)/include \ | ||
1985 | 14 | -I$(top_srcdir)/libmm-glib \ | ||
1986 | 15 | -I$(top_srcdir)/libmm-glib/generated \ | ||
1987 | 16 | -I$(top_builddir)/libmm-glib/generated | ||
1988 | 17 | |||
1989 | 18 | PLUGIN_COMMON_LINKER_FLAGS = \ | ||
1990 | 19 | $(GUDEV_LIBS) \ | ||
1991 | 20 | $(MM_LIBS) \ | ||
1992 | 21 | -module \ | ||
1993 | 22 | -avoid-version | ||
1994 | 23 | |||
1995 | 24 | if WITH_QMI | ||
1996 | 25 | PLUGIN_COMMON_COMPILER_FLAGS += $(QMI_CFLAGS) | ||
1997 | 26 | PLUGIN_COMMON_LINKER_FLAGS += $(QMI_LIBS) | ||
1998 | 27 | endif | ||
1999 | 28 | |||
2000 | 29 | if WITH_MBIM | ||
2001 | 30 | PLUGIN_COMMON_COMPILER_FLAGS += $(MBIM_CFLAGS) | ||
2002 | 31 | PLUGIN_COMMON_LINKER_FLAGS += $(MBIM_LIBS) | ||
2003 | 32 | endif | ||
2004 | 33 | |||
2005 | 34 | # UDev rules | ||
2006 | 35 | udevrulesdir = $(UDEV_BASE_DIR)/rules.d | ||
2007 | 36 | udevrules_DATA = | ||
2008 | 37 | |||
2009 | 38 | # Unit tests | ||
2010 | 39 | noinst_PROGRAMS = | ||
2011 | 40 | |||
2012 | 41 | # Helper libs | ||
2013 | 42 | noinst_LTLIBRARIES = | ||
2014 | 43 | |||
2015 | 44 | ######################################## | ||
2016 | 45 | |||
2017 | 46 | # Common service test support | ||
2018 | 47 | |||
2019 | 48 | noinst_LTLIBRARIES += libmm-test-common.la | ||
2020 | 49 | |||
2021 | 50 | libmm_test_common_la_SOURCES = \ | ||
2022 | 51 | tests/test-fixture.h \ | ||
2023 | 52 | tests/test-fixture.c \ | ||
2024 | 53 | tests/test-port-context.h \ | ||
2025 | 54 | tests/test-port-context.c | ||
2026 | 55 | |||
2027 | 56 | libmm_test_common_la_CPPFLAGS = \ | ||
2028 | 57 | $(MM_CFLAGS) \ | ||
2029 | 58 | -I$(top_srcdir)/include \ | ||
2030 | 59 | -I$(top_builddir)/include \ | ||
2031 | 60 | -I$(top_srcdir)/libmm-glib \ | ||
2032 | 61 | -I$(top_srcdir)/libmm-glib/generated \ | ||
2033 | 62 | -I$(top_builddir)/libmm-glib/generated \ | ||
2034 | 63 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
2035 | 64 | -DTEST_SERVICES=\""$(abs_top_builddir)/data/tests"\" | ||
2036 | 65 | |||
2037 | 66 | libmm_test_common_la_LIBADD = \ | ||
2038 | 67 | ${top_builddir}/libmm-glib/generated/tests/libmm-test-generated.la \ | ||
2039 | 68 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
2040 | 69 | |||
2041 | 70 | TEST_COMMON_COMPILER_FLAGS = \ | ||
2042 | 71 | $(MM_CFLAGS) \ | ||
2043 | 72 | -I$(top_srcdir)/plugins/tests \ | ||
2044 | 73 | -I$(top_srcdir)/include \ | ||
2045 | 74 | -I$(top_builddir)/include \ | ||
2046 | 75 | -I$(top_srcdir)/libmm-glib \ | ||
2047 | 76 | -I$(top_srcdir)/libmm-glib/generated \ | ||
2048 | 77 | -I$(top_builddir)/libmm-glib/generated \ | ||
2049 | 78 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
2050 | 79 | -DCOMMON_GSM_PORT_CONF=\""$(abs_top_srcdir)/plugins/tests/gsm-port.conf"\" | ||
2051 | 80 | |||
2052 | 81 | TEST_COMMON_LIBADD_FLAGS = \ | ||
2053 | 82 | $(builddir)/libmm-test-common.la \ | ||
2054 | 83 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
2055 | 84 | |||
2056 | 85 | |||
2057 | 86 | ######################################## | ||
2058 | 87 | |||
2059 | 88 | # Icera-specific support | ||
2060 | 89 | noinst_LTLIBRARIES += libmm-utils-icera.la | ||
2061 | 90 | libmm_utils_icera_la_SOURCES = \ | ||
2062 | 91 | icera/mm-broadband-modem-icera.h \ | ||
2063 | 92 | icera/mm-broadband-modem-icera.c \ | ||
2064 | 93 | icera/mm-broadband-bearer-icera.h \ | ||
2065 | 94 | icera/mm-broadband-bearer-icera.c \ | ||
2066 | 95 | icera/mm-modem-helpers-icera.c \ | ||
2067 | 96 | icera/mm-modem-helpers-icera.h | ||
2068 | 97 | libmm_utils_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2069 | 98 | libmm_utils_icera_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
2070 | 99 | |||
2071 | 100 | ICERA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/icera | ||
2072 | 101 | ICERA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-icera.la | ||
2073 | 102 | |||
2074 | 103 | noinst_PROGRAMS += test-modem-helpers-icera | ||
2075 | 104 | test_modem_helpers_icera_SOURCES = \ | ||
2076 | 105 | icera/mm-modem-helpers-icera.c \ | ||
2077 | 106 | icera/mm-modem-helpers-icera.h \ | ||
2078 | 107 | icera/tests/test-modem-helpers-icera.c | ||
2079 | 108 | test_modem_helpers_icera_CPPFLAGS = \ | ||
2080 | 109 | -I$(top_srcdir)/plugins/icera \ | ||
2081 | 110 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2082 | 111 | test_modem_helpers_icera_LDADD = \ | ||
2083 | 112 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
2084 | 113 | $(top_builddir)/src/libmodem-helpers.la | ||
2085 | 114 | test_modem_helpers_icera_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2086 | 115 | |||
2087 | 116 | ######################################## | ||
2088 | 117 | |||
2089 | 118 | pkglib_LTLIBRARIES = \ | ||
2090 | 119 | libmm-plugin-generic.la \ | ||
2091 | 120 | libmm-plugin-nokia.la \ | ||
2092 | 121 | libmm-plugin-nokia-icera.la \ | ||
2093 | 122 | libmm-plugin-cinterion.la \ | ||
2094 | 123 | libmm-plugin-iridium.la \ | ||
2095 | 124 | libmm-plugin-gobi.la \ | ||
2096 | 125 | libmm-plugin-motorola.la \ | ||
2097 | 126 | libmm-plugin-novatel.la \ | ||
2098 | 127 | libmm-plugin-novatel-lte.la \ | ||
2099 | 128 | libmm-plugin-altair-lte.la \ | ||
2100 | 129 | libmm-plugin-samsung.la \ | ||
2101 | 130 | libmm-plugin-option.la \ | ||
2102 | 131 | libmm-plugin-hso.la \ | ||
2103 | 132 | libmm-plugin-anydata.la \ | ||
2104 | 133 | libmm-plugin-linktop.la \ | ||
2105 | 134 | libmm-plugin-simtech.la \ | ||
2106 | 135 | libmm-plugin-wavecom.la \ | ||
2107 | 136 | libmm-plugin-huawei.la \ | ||
2108 | 137 | libmm-plugin-longcheer.la \ | ||
2109 | 138 | libmm-plugin-x22x.la \ | ||
2110 | 139 | libmm-plugin-pantech.la \ | ||
2111 | 140 | libmm-plugin-zte.la \ | ||
2112 | 141 | libmm-plugin-sierra.la \ | ||
2113 | 142 | libmm-plugin-mbm.la \ | ||
2114 | 143 | libmm-plugin-via.la \ | ||
2115 | 144 | libmm-plugin-telit.la \ | ||
2116 | 145 | libmm-plugin-mtk.la | ||
2117 | 146 | |||
2118 | 147 | # Generic | ||
2119 | 148 | libmm_plugin_generic_la_SOURCES = \ | ||
2120 | 149 | generic/mm-plugin-generic.c \ | ||
2121 | 150 | generic/mm-plugin-generic.h | ||
2122 | 151 | libmm_plugin_generic_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2123 | 152 | libmm_plugin_generic_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2124 | 153 | |||
2125 | 154 | noinst_PROGRAMS += test-service-generic | ||
2126 | 155 | test_service_generic_SOURCES = generic/tests/test-service-generic.c | ||
2127 | 156 | test_service_generic_CPPFLAGS = $(TEST_COMMON_COMPILER_FLAGS) | ||
2128 | 157 | test_service_generic_LDADD = $(TEST_COMMON_LIBADD_FLAGS) | ||
2129 | 158 | test_service_generic_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2130 | 159 | |||
2131 | 160 | ## Motorola | ||
2132 | 161 | libmm_plugin_motorola_la_SOURCES = \ | ||
2133 | 162 | motorola/mm-plugin-motorola.c \ | ||
2134 | 163 | motorola/mm-plugin-motorola.h \ | ||
2135 | 164 | motorola/mm-broadband-modem-motorola.c \ | ||
2136 | 165 | motorola/mm-broadband-modem-motorola.h | ||
2137 | 166 | libmm_plugin_motorola_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2138 | 167 | libmm_plugin_motorola_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2139 | 168 | |||
2140 | 169 | # Gobi | ||
2141 | 170 | libmm_plugin_gobi_la_SOURCES = \ | ||
2142 | 171 | gobi/mm-plugin-gobi.c \ | ||
2143 | 172 | gobi/mm-plugin-gobi.h \ | ||
2144 | 173 | gobi/mm-broadband-modem-gobi.c \ | ||
2145 | 174 | gobi/mm-broadband-modem-gobi.h | ||
2146 | 175 | libmm_plugin_gobi_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2147 | 176 | libmm_plugin_gobi_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2148 | 177 | |||
2149 | 178 | # Huawei | ||
2150 | 179 | libmm_plugin_huawei_la_SOURCES = \ | ||
2151 | 180 | huawei/mm-plugin-huawei.c \ | ||
2152 | 181 | huawei/mm-plugin-huawei.h \ | ||
2153 | 182 | huawei/mm-modem-helpers-huawei.c \ | ||
2154 | 183 | huawei/mm-modem-helpers-huawei.h \ | ||
2155 | 184 | huawei/mm-sim-huawei.c \ | ||
2156 | 185 | huawei/mm-sim-huawei.h \ | ||
2157 | 186 | huawei/mm-broadband-modem-huawei.c \ | ||
2158 | 187 | huawei/mm-broadband-modem-huawei.h \ | ||
2159 | 188 | huawei/mm-broadband-bearer-huawei.c \ | ||
2160 | 189 | huawei/mm-broadband-bearer-huawei.h | ||
2161 | 190 | libmm_plugin_huawei_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2162 | 191 | libmm_plugin_huawei_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2163 | 192 | |||
2164 | 193 | udevrules_DATA += huawei/77-mm-huawei-net-port-types.rules | ||
2165 | 194 | |||
2166 | 195 | noinst_PROGRAMS += test-modem-helpers-huawei | ||
2167 | 196 | test_modem_helpers_huawei_SOURCES = \ | ||
2168 | 197 | huawei/mm-modem-helpers-huawei.c \ | ||
2169 | 198 | huawei/mm-modem-helpers-huawei.h \ | ||
2170 | 199 | huawei/tests/test-modem-helpers-huawei.c | ||
2171 | 200 | test_modem_helpers_huawei_CPPFLAGS = \ | ||
2172 | 201 | -I$(top_srcdir)/plugins/huawei \ | ||
2173 | 202 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2174 | 203 | test_modem_helpers_huawei_LDADD = \ | ||
2175 | 204 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
2176 | 205 | $(top_builddir)/src/libmodem-helpers.la | ||
2177 | 206 | test_modem_helpers_huawei_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2178 | 207 | |||
2179 | 208 | # MBM | ||
2180 | 209 | libmm_plugin_mbm_la_SOURCES = \ | ||
2181 | 210 | mbm/mm-plugin-mbm.c \ | ||
2182 | 211 | mbm/mm-plugin-mbm.h \ | ||
2183 | 212 | mbm/mm-broadband-modem-mbm.c \ | ||
2184 | 213 | mbm/mm-broadband-modem-mbm.h \ | ||
2185 | 214 | mbm/mm-broadband-bearer-mbm.c \ | ||
2186 | 215 | mbm/mm-broadband-bearer-mbm.h \ | ||
2187 | 216 | mbm/mm-modem-helpers-mbm.c \ | ||
2188 | 217 | mbm/mm-modem-helpers-mbm.h \ | ||
2189 | 218 | mbm/mm-sim-mbm.c \ | ||
2190 | 219 | mbm/mm-sim-mbm.h | ||
2191 | 220 | libmm_plugin_mbm_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2192 | 221 | libmm_plugin_mbm_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2193 | 222 | udevrules_DATA += mbm/77-mm-ericsson-mbm.rules | ||
2194 | 223 | |||
2195 | 224 | noinst_PROGRAMS += test-modem-helpers-mbm | ||
2196 | 225 | test_modem_helpers_mbm_SOURCES = \ | ||
2197 | 226 | mbm/mm-modem-helpers-mbm.c \ | ||
2198 | 227 | mbm/mm-modem-helpers-mbm.h \ | ||
2199 | 228 | mbm/tests/test-modem-helpers-mbm.c | ||
2200 | 229 | test_modem_helpers_mbm_CPPFLAGS = \ | ||
2201 | 230 | -I$(top_srcdir)/plugins/mbm \ | ||
2202 | 231 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2203 | 232 | test_modem_helpers_mbm_LDADD = \ | ||
2204 | 233 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
2205 | 234 | $(top_builddir)/src/libmodem-helpers.la | ||
2206 | 235 | test_modem_helpers_mbm_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2207 | 236 | |||
2208 | 237 | # Option | ||
2209 | 238 | libmm_plugin_option_la_SOURCES = \ | ||
2210 | 239 | option/mm-plugin-option.c \ | ||
2211 | 240 | option/mm-plugin-option.h \ | ||
2212 | 241 | option/mm-broadband-modem-option.c \ | ||
2213 | 242 | option/mm-broadband-modem-option.h | ||
2214 | 243 | libmm_plugin_option_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2215 | 244 | libmm_plugin_option_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2216 | 245 | |||
2217 | 246 | # HSO | ||
2218 | 247 | libmm_plugin_hso_la_SOURCES = \ | ||
2219 | 248 | option/mm-plugin-hso.c \ | ||
2220 | 249 | option/mm-plugin-hso.h \ | ||
2221 | 250 | option/mm-broadband-modem-option.c \ | ||
2222 | 251 | option/mm-broadband-modem-option.h \ | ||
2223 | 252 | option/mm-broadband-bearer-hso.c \ | ||
2224 | 253 | option/mm-broadband-bearer-hso.h \ | ||
2225 | 254 | option/mm-broadband-modem-hso.c \ | ||
2226 | 255 | option/mm-broadband-modem-hso.h | ||
2227 | 256 | libmm_plugin_hso_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2228 | 257 | libmm_plugin_hso_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2229 | 258 | |||
2230 | 259 | # Sierra | ||
2231 | 260 | libmm_plugin_sierra_la_SOURCES = \ | ||
2232 | 261 | sierra/mm-plugin-sierra.c \ | ||
2233 | 262 | sierra/mm-plugin-sierra.h \ | ||
2234 | 263 | sierra/mm-common-sierra.c \ | ||
2235 | 264 | sierra/mm-common-sierra.h \ | ||
2236 | 265 | sierra/mm-sim-sierra.c \ | ||
2237 | 266 | sierra/mm-sim-sierra.h \ | ||
2238 | 267 | sierra/mm-broadband-bearer-sierra.c \ | ||
2239 | 268 | sierra/mm-broadband-bearer-sierra.h \ | ||
2240 | 269 | sierra/mm-broadband-modem-sierra.c \ | ||
2241 | 270 | sierra/mm-broadband-modem-sierra.h \ | ||
2242 | 271 | sierra/mm-broadband-modem-sierra-icera.c \ | ||
2243 | 272 | sierra/mm-broadband-modem-sierra-icera.h | ||
2244 | 273 | libmm_plugin_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
2245 | 274 | libmm_plugin_sierra_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2246 | 275 | libmm_plugin_sierra_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
2247 | 276 | |||
2248 | 277 | # Wavecom (Sierra Airlink) | ||
2249 | 278 | libmm_plugin_wavecom_la_SOURCES = \ | ||
2250 | 279 | wavecom/mm-plugin-wavecom.c \ | ||
2251 | 280 | wavecom/mm-plugin-wavecom.h \ | ||
2252 | 281 | wavecom/mm-broadband-modem-wavecom.c \ | ||
2253 | 282 | wavecom/mm-broadband-modem-wavecom.h | ||
2254 | 283 | libmm_plugin_wavecom_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2255 | 284 | libmm_plugin_wavecom_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2256 | 285 | |||
2257 | 286 | # Nokia | ||
2258 | 287 | libmm_plugin_nokia_la_SOURCES = \ | ||
2259 | 288 | nokia/mm-plugin-nokia.c \ | ||
2260 | 289 | nokia/mm-plugin-nokia.h \ | ||
2261 | 290 | nokia/mm-sim-nokia.c \ | ||
2262 | 291 | nokia/mm-sim-nokia.h \ | ||
2263 | 292 | nokia/mm-broadband-modem-nokia.c \ | ||
2264 | 293 | nokia/mm-broadband-modem-nokia.h | ||
2265 | 294 | libmm_plugin_nokia_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2266 | 295 | libmm_plugin_nokia_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2267 | 296 | |||
2268 | 297 | # Nokia (Icera) | ||
2269 | 298 | libmm_plugin_nokia_icera_la_SOURCES = \ | ||
2270 | 299 | nokia/mm-plugin-nokia-icera.c \ | ||
2271 | 300 | nokia/mm-plugin-nokia-icera.h | ||
2272 | 301 | libmm_plugin_nokia_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
2273 | 302 | libmm_plugin_nokia_icera_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2274 | 303 | libmm_plugin_nokia_icera_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
2275 | 304 | udevrules_DATA += nokia/77-mm-nokia-port-types.rules | ||
2276 | 305 | |||
2277 | 306 | # Zte | ||
2278 | 307 | libmm_plugin_zte_la_SOURCES = \ | ||
2279 | 308 | zte/mm-plugin-zte.c \ | ||
2280 | 309 | zte/mm-plugin-zte.h \ | ||
2281 | 310 | zte/mm-common-zte.h \ | ||
2282 | 311 | zte/mm-common-zte.c \ | ||
2283 | 312 | zte/mm-broadband-modem-zte.h \ | ||
2284 | 313 | zte/mm-broadband-modem-zte.c \ | ||
2285 | 314 | zte/mm-broadband-modem-zte-icera.h \ | ||
2286 | 315 | zte/mm-broadband-modem-zte-icera.c | ||
2287 | 316 | libmm_plugin_zte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
2288 | 317 | libmm_plugin_zte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2289 | 318 | libmm_plugin_zte_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
2290 | 319 | udevrules_DATA += zte/77-mm-zte-port-types.rules | ||
2291 | 320 | |||
2292 | 321 | # Longcheer (and rebranded dongles) | ||
2293 | 322 | libmm_plugin_longcheer_la_SOURCES = \ | ||
2294 | 323 | longcheer/mm-plugin-longcheer.c \ | ||
2295 | 324 | longcheer/mm-plugin-longcheer.h \ | ||
2296 | 325 | longcheer/mm-broadband-modem-longcheer.h \ | ||
2297 | 326 | longcheer/mm-broadband-modem-longcheer.c | ||
2298 | 327 | libmm_plugin_longcheer_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2299 | 328 | libmm_plugin_longcheer_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2300 | 329 | udevrules_DATA += longcheer/77-mm-longcheer-port-types.rules | ||
2301 | 330 | |||
2302 | 331 | # AnyData CDMA | ||
2303 | 332 | libmm_plugin_anydata_la_SOURCES = \ | ||
2304 | 333 | anydata/mm-plugin-anydata.c \ | ||
2305 | 334 | anydata/mm-plugin-anydata.h \ | ||
2306 | 335 | anydata/mm-broadband-modem-anydata.h \ | ||
2307 | 336 | anydata/mm-broadband-modem-anydata.c | ||
2308 | 337 | libmm_plugin_anydata_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2309 | 338 | libmm_plugin_anydata_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2310 | 339 | |||
2311 | 340 | # Linktop CDMA | ||
2312 | 341 | libmm_plugin_linktop_la_SOURCES = \ | ||
2313 | 342 | linktop/mm-plugin-linktop.c \ | ||
2314 | 343 | linktop/mm-plugin-linktop.h \ | ||
2315 | 344 | linktop/mm-broadband-modem-linktop.h \ | ||
2316 | 345 | linktop/mm-broadband-modem-linktop.c | ||
2317 | 346 | libmm_plugin_linktop_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2318 | 347 | libmm_plugin_linktop_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2319 | 348 | |||
2320 | 349 | # SimTech | ||
2321 | 350 | libmm_plugin_simtech_la_SOURCES = \ | ||
2322 | 351 | simtech/mm-plugin-simtech.c \ | ||
2323 | 352 | simtech/mm-plugin-simtech.h \ | ||
2324 | 353 | simtech/mm-broadband-modem-simtech.h \ | ||
2325 | 354 | simtech/mm-broadband-modem-simtech.c | ||
2326 | 355 | libmm_plugin_simtech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2327 | 356 | libmm_plugin_simtech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2328 | 357 | udevrules_DATA += simtech/77-mm-simtech-port-types.rules | ||
2329 | 358 | |||
2330 | 359 | # Alcatel/TCT/JRD x220D and possibly others | ||
2331 | 360 | libmm_plugin_x22x_la_SOURCES = \ | ||
2332 | 361 | x22x/mm-plugin-x22x.c \ | ||
2333 | 362 | x22x/mm-plugin-x22x.h \ | ||
2334 | 363 | x22x/mm-broadband-modem-x22x.h \ | ||
2335 | 364 | x22x/mm-broadband-modem-x22x.c | ||
2336 | 365 | libmm_plugin_x22x_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2337 | 366 | libmm_plugin_x22x_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2338 | 367 | udevrules_DATA += x22x/77-mm-x22x-port-types.rules | ||
2339 | 368 | |||
2340 | 369 | # Pantech | ||
2341 | 370 | libmm_plugin_pantech_la_SOURCES = \ | ||
2342 | 371 | pantech/mm-plugin-pantech.c \ | ||
2343 | 372 | pantech/mm-plugin-pantech.h \ | ||
2344 | 373 | pantech/mm-sim-pantech.c \ | ||
2345 | 374 | pantech/mm-sim-pantech.h \ | ||
2346 | 375 | pantech/mm-broadband-modem-pantech.c \ | ||
2347 | 376 | pantech/mm-broadband-modem-pantech.h | ||
2348 | 377 | libmm_plugin_pantech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2349 | 378 | libmm_plugin_pantech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2350 | 379 | |||
2351 | 380 | # Samsung modem | ||
2352 | 381 | libmm_plugin_samsung_la_SOURCES = \ | ||
2353 | 382 | samsung/mm-plugin-samsung.c \ | ||
2354 | 383 | samsung/mm-plugin-samsung.h \ | ||
2355 | 384 | samsung/mm-broadband-modem-samsung.c \ | ||
2356 | 385 | samsung/mm-broadband-modem-samsung.h | ||
2357 | 386 | libmm_plugin_samsung_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
2358 | 387 | libmm_plugin_samsung_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2359 | 388 | libmm_plugin_samsung_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
2360 | 389 | |||
2361 | 390 | # Cinterion (previously Siemens) modem | ||
2362 | 391 | libmm_plugin_cinterion_la_SOURCES = \ | ||
2363 | 392 | cinterion/mm-plugin-cinterion.c \ | ||
2364 | 393 | cinterion/mm-plugin-cinterion.h \ | ||
2365 | 394 | cinterion/mm-modem-helpers-cinterion.c \ | ||
2366 | 395 | cinterion/mm-modem-helpers-cinterion.h \ | ||
2367 | 396 | cinterion/mm-common-cinterion.c \ | ||
2368 | 397 | cinterion/mm-common-cinterion.h \ | ||
2369 | 398 | cinterion/mm-broadband-modem-cinterion.c \ | ||
2370 | 399 | cinterion/mm-broadband-modem-cinterion.h | ||
2371 | 400 | |||
2372 | 401 | if WITH_QMI | ||
2373 | 402 | libmm_plugin_cinterion_la_SOURCES += \ | ||
2374 | 403 | cinterion/mm-broadband-modem-qmi-cinterion.c \ | ||
2375 | 404 | cinterion/mm-broadband-modem-qmi-cinterion.h | ||
2376 | 405 | endif | ||
2377 | 406 | |||
2378 | 407 | libmm_plugin_cinterion_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2379 | 408 | libmm_plugin_cinterion_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2380 | 409 | |||
2381 | 410 | udevrules_DATA += cinterion/77-mm-cinterion-port-types.rules | ||
2382 | 411 | |||
2383 | 412 | noinst_PROGRAMS += test-modem-helpers-cinterion | ||
2384 | 413 | test_modem_helpers_cinterion_SOURCES = \ | ||
2385 | 414 | cinterion/mm-modem-helpers-cinterion.c \ | ||
2386 | 415 | cinterion/mm-modem-helpers-cinterion.h \ | ||
2387 | 416 | cinterion/tests/test-modem-helpers-cinterion.c | ||
2388 | 417 | test_modem_helpers_cinterion_CPPFLAGS = \ | ||
2389 | 418 | -I$(top_srcdir)/plugins/cinterion \ | ||
2390 | 419 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2391 | 420 | test_modem_helpers_cinterion_LDADD = \ | ||
2392 | 421 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
2393 | 422 | $(top_builddir)/src/libmodem-helpers.la | ||
2394 | 423 | test_modem_helpers_cinterion_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2395 | 424 | |||
2396 | 425 | # Iridium modem | ||
2397 | 426 | libmm_plugin_iridium_la_SOURCES = \ | ||
2398 | 427 | iridium/mm-plugin-iridium.c \ | ||
2399 | 428 | iridium/mm-plugin-iridium.h \ | ||
2400 | 429 | iridium/mm-broadband-modem-iridium.c \ | ||
2401 | 430 | iridium/mm-broadband-modem-iridium.h \ | ||
2402 | 431 | iridium/mm-bearer-iridium.c \ | ||
2403 | 432 | iridium/mm-bearer-iridium.h \ | ||
2404 | 433 | iridium/mm-sim-iridium.c \ | ||
2405 | 434 | iridium/mm-sim-iridium.h | ||
2406 | 435 | libmm_plugin_iridium_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2407 | 436 | libmm_plugin_iridium_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2408 | 437 | |||
2409 | 438 | # Novatel LTE modem | ||
2410 | 439 | libmm_plugin_novatel_lte_la_SOURCES = \ | ||
2411 | 440 | novatel/mm-plugin-novatel-lte.c \ | ||
2412 | 441 | novatel/mm-plugin-novatel-lte.h \ | ||
2413 | 442 | novatel/mm-broadband-modem-novatel-lte.c \ | ||
2414 | 443 | novatel/mm-broadband-modem-novatel-lte.h \ | ||
2415 | 444 | novatel/mm-broadband-bearer-novatel-lte.c \ | ||
2416 | 445 | novatel/mm-broadband-bearer-novatel-lte.h \ | ||
2417 | 446 | novatel/mm-sim-novatel-lte.c \ | ||
2418 | 447 | novatel/mm-sim-novatel-lte.h | ||
2419 | 448 | libmm_plugin_novatel_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2420 | 449 | libmm_plugin_novatel_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2421 | 450 | |||
2422 | 451 | # Novatel non-LTE modem | ||
2423 | 452 | libmm_plugin_novatel_la_SOURCES = \ | ||
2424 | 453 | novatel/mm-plugin-novatel.c \ | ||
2425 | 454 | novatel/mm-plugin-novatel.h \ | ||
2426 | 455 | novatel/mm-common-novatel.c \ | ||
2427 | 456 | novatel/mm-common-novatel.h \ | ||
2428 | 457 | novatel/mm-broadband-modem-novatel.c \ | ||
2429 | 458 | novatel/mm-broadband-modem-novatel.h | ||
2430 | 459 | libmm_plugin_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2431 | 460 | libmm_plugin_novatel_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2432 | 461 | |||
2433 | 462 | # Altair LTE modem | ||
2434 | 463 | libmm_plugin_altair_lte_la_SOURCES = \ | ||
2435 | 464 | altair/mm-modem-helpers-altair-lte.c \ | ||
2436 | 465 | altair/mm-modem-helpers-altair-lte.h \ | ||
2437 | 466 | altair/mm-plugin-altair-lte.c \ | ||
2438 | 467 | altair/mm-plugin-altair-lte.h \ | ||
2439 | 468 | altair/mm-broadband-modem-altair-lte.c \ | ||
2440 | 469 | altair/mm-broadband-modem-altair-lte.h \ | ||
2441 | 470 | altair/mm-broadband-bearer-altair-lte.c \ | ||
2442 | 471 | altair/mm-broadband-bearer-altair-lte.h | ||
2443 | 472 | libmm_plugin_altair_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2444 | 473 | libmm_plugin_altair_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2445 | 474 | |||
2446 | 475 | noinst_PROGRAMS += test-modem-helpers-altair-lte | ||
2447 | 476 | test_modem_helpers_altair_lte_SOURCES = \ | ||
2448 | 477 | altair/mm-modem-helpers-altair-lte.c \ | ||
2449 | 478 | altair/mm-modem-helpers-altair-lte.h \ | ||
2450 | 479 | altair/tests/test-modem-helpers-altair-lte.c | ||
2451 | 480 | test_modem_helpers_altair_lte_CPPFLAGS = \ | ||
2452 | 481 | -I$(top_srcdir)/plugins/altair \ | ||
2453 | 482 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2454 | 483 | test_modem_helpers_altair_lte_LDADD = $(top_builddir)/libmm-glib/libmm-glib.la | ||
2455 | 484 | test_modem_helpers_altair_lte_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2456 | 485 | |||
2457 | 486 | |||
2458 | 487 | # VIA modem | ||
2459 | 488 | libmm_plugin_via_la_SOURCES = \ | ||
2460 | 489 | via/mm-plugin-via.c \ | ||
2461 | 490 | via/mm-plugin-via.h \ | ||
2462 | 491 | via/mm-broadband-modem-via.c \ | ||
2463 | 492 | via/mm-broadband-modem-via.h | ||
2464 | 493 | libmm_plugin_via_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2465 | 494 | libmm_plugin_via_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2466 | 495 | |||
2467 | 496 | # Telit modem | ||
2468 | 497 | libmm_plugin_telit_la_SOURCES = \ | ||
2469 | 498 | telit/mm-plugin-telit.c \ | ||
2470 | 499 | telit/mm-plugin-telit.h \ | ||
2471 | 500 | telit/mm-broadband-modem-telit.c \ | ||
2472 | 501 | telit/mm-broadband-modem-telit.h | ||
2473 | 502 | libmm_plugin_telit_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2474 | 503 | libmm_plugin_telit_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2475 | 504 | udevrules_DATA += telit/77-mm-telit-port-types.rules | ||
2476 | 505 | |||
2477 | 506 | # MTK | ||
2478 | 507 | libmm_plugin_mtk_la_SOURCES = \ | ||
2479 | 508 | mtk/mm-plugin-mtk.c \ | ||
2480 | 509 | mtk/mm-plugin-mtk.h \ | ||
2481 | 510 | mtk/mm-broadband-modem-mtk.h \ | ||
2482 | 511 | mtk/mm-broadband-modem-mtk.c | ||
2483 | 512 | libmm_plugin_mtk_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2484 | 513 | libmm_plugin_mtk_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2485 | 514 | udevrules_DATA += mtk/77-mm-mtk-port-types.rules | ||
2486 | 515 | |||
2487 | 516 | |||
2488 | 517 | # Additional files to include in the distribution | ||
2489 | 518 | EXTRA_DIST += \ | ||
2490 | 519 | $(udevrules_DATA) \ | ||
2491 | 520 | tests/gsm-port.conf | ||
2492 | 521 | |||
2493 | 522 | # Unit tests | ||
2494 | 523 | TEST_PROGS += $(noinst_PROGRAMS) | ||
2495 | 0 | 524 | ||
2496 | === added directory '.pc/novatel-custom-init.patch' | |||
2497 | === added directory '.pc/novatel-custom-init.patch/plugins' | |||
2498 | === added file '.pc/novatel-custom-init.patch/plugins/Makefile.am' | |||
2499 | --- .pc/novatel-custom-init.patch/plugins/Makefile.am 1970-01-01 00:00:00 +0000 | |||
2500 | +++ .pc/novatel-custom-init.patch/plugins/Makefile.am 2015-10-09 10:06:57 +0000 | |||
2501 | @@ -0,0 +1,521 @@ | |||
2502 | 1 | |||
2503 | 2 | include $(top_srcdir)/gtester.make | ||
2504 | 3 | |||
2505 | 4 | # Common CPPFLAGS and LDFLAGS | ||
2506 | 5 | |||
2507 | 6 | PLUGIN_COMMON_COMPILER_FLAGS = \ | ||
2508 | 7 | $(MM_CFLAGS) \ | ||
2509 | 8 | $(GUDEV_CFLAGS) \ | ||
2510 | 9 | -I$(top_srcdir) \ | ||
2511 | 10 | -I$(top_srcdir)/src \ | ||
2512 | 11 | -I$(top_builddir)/src \ | ||
2513 | 12 | -I$(top_srcdir)/include \ | ||
2514 | 13 | -I$(top_builddir)/include \ | ||
2515 | 14 | -I$(top_srcdir)/libmm-glib \ | ||
2516 | 15 | -I$(top_srcdir)/libmm-glib/generated \ | ||
2517 | 16 | -I$(top_builddir)/libmm-glib/generated | ||
2518 | 17 | |||
2519 | 18 | PLUGIN_COMMON_LINKER_FLAGS = \ | ||
2520 | 19 | $(GUDEV_LIBS) \ | ||
2521 | 20 | $(MM_LIBS) \ | ||
2522 | 21 | -module \ | ||
2523 | 22 | -avoid-version | ||
2524 | 23 | |||
2525 | 24 | if WITH_QMI | ||
2526 | 25 | PLUGIN_COMMON_COMPILER_FLAGS += $(QMI_CFLAGS) | ||
2527 | 26 | PLUGIN_COMMON_LINKER_FLAGS += $(QMI_LIBS) | ||
2528 | 27 | endif | ||
2529 | 28 | |||
2530 | 29 | if WITH_MBIM | ||
2531 | 30 | PLUGIN_COMMON_COMPILER_FLAGS += $(MBIM_CFLAGS) | ||
2532 | 31 | PLUGIN_COMMON_LINKER_FLAGS += $(MBIM_LIBS) | ||
2533 | 32 | endif | ||
2534 | 33 | |||
2535 | 34 | # UDev rules | ||
2536 | 35 | udevrulesdir = $(UDEV_BASE_DIR)/rules.d | ||
2537 | 36 | udevrules_DATA = | ||
2538 | 37 | |||
2539 | 38 | # Unit tests | ||
2540 | 39 | noinst_PROGRAMS = | ||
2541 | 40 | |||
2542 | 41 | # Helper libs | ||
2543 | 42 | noinst_LTLIBRARIES = | ||
2544 | 43 | |||
2545 | 44 | ######################################## | ||
2546 | 45 | |||
2547 | 46 | # Common service test support | ||
2548 | 47 | |||
2549 | 48 | noinst_LTLIBRARIES += libmm-test-common.la | ||
2550 | 49 | |||
2551 | 50 | libmm_test_common_la_SOURCES = \ | ||
2552 | 51 | tests/test-fixture.h \ | ||
2553 | 52 | tests/test-fixture.c \ | ||
2554 | 53 | tests/test-port-context.h \ | ||
2555 | 54 | tests/test-port-context.c | ||
2556 | 55 | |||
2557 | 56 | libmm_test_common_la_CPPFLAGS = \ | ||
2558 | 57 | $(MM_CFLAGS) \ | ||
2559 | 58 | -I$(top_srcdir)/include \ | ||
2560 | 59 | -I$(top_builddir)/include \ | ||
2561 | 60 | -I$(top_srcdir)/libmm-glib \ | ||
2562 | 61 | -I$(top_srcdir)/libmm-glib/generated \ | ||
2563 | 62 | -I$(top_builddir)/libmm-glib/generated \ | ||
2564 | 63 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
2565 | 64 | -DTEST_SERVICES=\""$(abs_top_builddir)/data/tests"\" | ||
2566 | 65 | |||
2567 | 66 | libmm_test_common_la_LIBADD = \ | ||
2568 | 67 | ${top_builddir}/libmm-glib/generated/tests/libmm-test-generated.la \ | ||
2569 | 68 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
2570 | 69 | |||
2571 | 70 | TEST_COMMON_COMPILER_FLAGS = \ | ||
2572 | 71 | $(MM_CFLAGS) \ | ||
2573 | 72 | -I$(top_srcdir)/plugins/tests \ | ||
2574 | 73 | -I$(top_srcdir)/include \ | ||
2575 | 74 | -I$(top_builddir)/include \ | ||
2576 | 75 | -I$(top_srcdir)/libmm-glib \ | ||
2577 | 76 | -I$(top_srcdir)/libmm-glib/generated \ | ||
2578 | 77 | -I$(top_builddir)/libmm-glib/generated \ | ||
2579 | 78 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
2580 | 79 | -DCOMMON_GSM_PORT_CONF=\""$(abs_top_srcdir)/plugins/tests/gsm-port.conf"\" | ||
2581 | 80 | |||
2582 | 81 | TEST_COMMON_LIBADD_FLAGS = \ | ||
2583 | 82 | $(builddir)/libmm-test-common.la \ | ||
2584 | 83 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
2585 | 84 | |||
2586 | 85 | |||
2587 | 86 | ######################################## | ||
2588 | 87 | |||
2589 | 88 | # Icera-specific support | ||
2590 | 89 | noinst_LTLIBRARIES += libmm-utils-icera.la | ||
2591 | 90 | libmm_utils_icera_la_SOURCES = \ | ||
2592 | 91 | icera/mm-broadband-modem-icera.h \ | ||
2593 | 92 | icera/mm-broadband-modem-icera.c \ | ||
2594 | 93 | icera/mm-broadband-bearer-icera.h \ | ||
2595 | 94 | icera/mm-broadband-bearer-icera.c \ | ||
2596 | 95 | icera/mm-modem-helpers-icera.c \ | ||
2597 | 96 | icera/mm-modem-helpers-icera.h | ||
2598 | 97 | libmm_utils_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2599 | 98 | libmm_utils_icera_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
2600 | 99 | |||
2601 | 100 | ICERA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/icera | ||
2602 | 101 | ICERA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-icera.la | ||
2603 | 102 | |||
2604 | 103 | noinst_PROGRAMS += test-modem-helpers-icera | ||
2605 | 104 | test_modem_helpers_icera_SOURCES = \ | ||
2606 | 105 | icera/mm-modem-helpers-icera.c \ | ||
2607 | 106 | icera/mm-modem-helpers-icera.h \ | ||
2608 | 107 | icera/tests/test-modem-helpers-icera.c | ||
2609 | 108 | test_modem_helpers_icera_CPPFLAGS = \ | ||
2610 | 109 | -I$(top_srcdir)/plugins/icera \ | ||
2611 | 110 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2612 | 111 | test_modem_helpers_icera_LDADD = \ | ||
2613 | 112 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
2614 | 113 | $(top_builddir)/src/libmodem-helpers.la | ||
2615 | 114 | test_modem_helpers_icera_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2616 | 115 | |||
2617 | 116 | ######################################## | ||
2618 | 117 | |||
2619 | 118 | pkglib_LTLIBRARIES = \ | ||
2620 | 119 | libmm-plugin-generic.la \ | ||
2621 | 120 | libmm-plugin-nokia.la \ | ||
2622 | 121 | libmm-plugin-nokia-icera.la \ | ||
2623 | 122 | libmm-plugin-cinterion.la \ | ||
2624 | 123 | libmm-plugin-iridium.la \ | ||
2625 | 124 | libmm-plugin-gobi.la \ | ||
2626 | 125 | libmm-plugin-motorola.la \ | ||
2627 | 126 | libmm-plugin-novatel.la \ | ||
2628 | 127 | libmm-plugin-novatel-lte.la \ | ||
2629 | 128 | libmm-plugin-altair-lte.la \ | ||
2630 | 129 | libmm-plugin-samsung.la \ | ||
2631 | 130 | libmm-plugin-option.la \ | ||
2632 | 131 | libmm-plugin-hso.la \ | ||
2633 | 132 | libmm-plugin-anydata.la \ | ||
2634 | 133 | libmm-plugin-linktop.la \ | ||
2635 | 134 | libmm-plugin-simtech.la \ | ||
2636 | 135 | libmm-plugin-wavecom.la \ | ||
2637 | 136 | libmm-plugin-huawei.la \ | ||
2638 | 137 | libmm-plugin-longcheer.la \ | ||
2639 | 138 | libmm-plugin-x22x.la \ | ||
2640 | 139 | libmm-plugin-pantech.la \ | ||
2641 | 140 | libmm-plugin-zte.la \ | ||
2642 | 141 | libmm-plugin-sierra.la \ | ||
2643 | 142 | libmm-plugin-mbm.la \ | ||
2644 | 143 | libmm-plugin-via.la \ | ||
2645 | 144 | libmm-plugin-telit.la \ | ||
2646 | 145 | libmm-plugin-mtk.la | ||
2647 | 146 | |||
2648 | 147 | # Generic | ||
2649 | 148 | libmm_plugin_generic_la_SOURCES = \ | ||
2650 | 149 | generic/mm-plugin-generic.c \ | ||
2651 | 150 | generic/mm-plugin-generic.h | ||
2652 | 151 | libmm_plugin_generic_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2653 | 152 | libmm_plugin_generic_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2654 | 153 | |||
2655 | 154 | noinst_PROGRAMS += test-service-generic | ||
2656 | 155 | test_service_generic_SOURCES = generic/tests/test-service-generic.c | ||
2657 | 156 | test_service_generic_CPPFLAGS = $(TEST_COMMON_COMPILER_FLAGS) | ||
2658 | 157 | test_service_generic_LDADD = $(TEST_COMMON_LIBADD_FLAGS) | ||
2659 | 158 | test_service_generic_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2660 | 159 | |||
2661 | 160 | ## Motorola | ||
2662 | 161 | libmm_plugin_motorola_la_SOURCES = \ | ||
2663 | 162 | motorola/mm-plugin-motorola.c \ | ||
2664 | 163 | motorola/mm-plugin-motorola.h \ | ||
2665 | 164 | motorola/mm-broadband-modem-motorola.c \ | ||
2666 | 165 | motorola/mm-broadband-modem-motorola.h | ||
2667 | 166 | libmm_plugin_motorola_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2668 | 167 | libmm_plugin_motorola_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2669 | 168 | |||
2670 | 169 | # Gobi | ||
2671 | 170 | libmm_plugin_gobi_la_SOURCES = \ | ||
2672 | 171 | gobi/mm-plugin-gobi.c \ | ||
2673 | 172 | gobi/mm-plugin-gobi.h \ | ||
2674 | 173 | gobi/mm-broadband-modem-gobi.c \ | ||
2675 | 174 | gobi/mm-broadband-modem-gobi.h | ||
2676 | 175 | libmm_plugin_gobi_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2677 | 176 | libmm_plugin_gobi_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2678 | 177 | |||
2679 | 178 | # Huawei | ||
2680 | 179 | libmm_plugin_huawei_la_SOURCES = \ | ||
2681 | 180 | huawei/mm-plugin-huawei.c \ | ||
2682 | 181 | huawei/mm-plugin-huawei.h \ | ||
2683 | 182 | huawei/mm-modem-helpers-huawei.c \ | ||
2684 | 183 | huawei/mm-modem-helpers-huawei.h \ | ||
2685 | 184 | huawei/mm-sim-huawei.c \ | ||
2686 | 185 | huawei/mm-sim-huawei.h \ | ||
2687 | 186 | huawei/mm-broadband-modem-huawei.c \ | ||
2688 | 187 | huawei/mm-broadband-modem-huawei.h \ | ||
2689 | 188 | huawei/mm-broadband-bearer-huawei.c \ | ||
2690 | 189 | huawei/mm-broadband-bearer-huawei.h | ||
2691 | 190 | libmm_plugin_huawei_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2692 | 191 | libmm_plugin_huawei_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2693 | 192 | |||
2694 | 193 | udevrules_DATA += huawei/77-mm-huawei-net-port-types.rules | ||
2695 | 194 | |||
2696 | 195 | noinst_PROGRAMS += test-modem-helpers-huawei | ||
2697 | 196 | test_modem_helpers_huawei_SOURCES = \ | ||
2698 | 197 | huawei/mm-modem-helpers-huawei.c \ | ||
2699 | 198 | huawei/mm-modem-helpers-huawei.h \ | ||
2700 | 199 | huawei/tests/test-modem-helpers-huawei.c | ||
2701 | 200 | test_modem_helpers_huawei_CPPFLAGS = \ | ||
2702 | 201 | -I$(top_srcdir)/plugins/huawei \ | ||
2703 | 202 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2704 | 203 | test_modem_helpers_huawei_LDADD = \ | ||
2705 | 204 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
2706 | 205 | $(top_builddir)/src/libmodem-helpers.la | ||
2707 | 206 | test_modem_helpers_huawei_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2708 | 207 | |||
2709 | 208 | # MBM | ||
2710 | 209 | libmm_plugin_mbm_la_SOURCES = \ | ||
2711 | 210 | mbm/mm-plugin-mbm.c \ | ||
2712 | 211 | mbm/mm-plugin-mbm.h \ | ||
2713 | 212 | mbm/mm-broadband-modem-mbm.c \ | ||
2714 | 213 | mbm/mm-broadband-modem-mbm.h \ | ||
2715 | 214 | mbm/mm-broadband-bearer-mbm.c \ | ||
2716 | 215 | mbm/mm-broadband-bearer-mbm.h \ | ||
2717 | 216 | mbm/mm-modem-helpers-mbm.c \ | ||
2718 | 217 | mbm/mm-modem-helpers-mbm.h \ | ||
2719 | 218 | mbm/mm-sim-mbm.c \ | ||
2720 | 219 | mbm/mm-sim-mbm.h | ||
2721 | 220 | libmm_plugin_mbm_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2722 | 221 | libmm_plugin_mbm_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2723 | 222 | udevrules_DATA += mbm/77-mm-ericsson-mbm.rules | ||
2724 | 223 | |||
2725 | 224 | noinst_PROGRAMS += test-modem-helpers-mbm | ||
2726 | 225 | test_modem_helpers_mbm_SOURCES = \ | ||
2727 | 226 | mbm/mm-modem-helpers-mbm.c \ | ||
2728 | 227 | mbm/mm-modem-helpers-mbm.h \ | ||
2729 | 228 | mbm/tests/test-modem-helpers-mbm.c | ||
2730 | 229 | test_modem_helpers_mbm_CPPFLAGS = \ | ||
2731 | 230 | -I$(top_srcdir)/plugins/mbm \ | ||
2732 | 231 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2733 | 232 | test_modem_helpers_mbm_LDADD = \ | ||
2734 | 233 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
2735 | 234 | $(top_builddir)/src/libmodem-helpers.la | ||
2736 | 235 | test_modem_helpers_mbm_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2737 | 236 | |||
2738 | 237 | # Option | ||
2739 | 238 | libmm_plugin_option_la_SOURCES = \ | ||
2740 | 239 | option/mm-plugin-option.c \ | ||
2741 | 240 | option/mm-plugin-option.h \ | ||
2742 | 241 | option/mm-broadband-modem-option.c \ | ||
2743 | 242 | option/mm-broadband-modem-option.h | ||
2744 | 243 | libmm_plugin_option_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2745 | 244 | libmm_plugin_option_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2746 | 245 | |||
2747 | 246 | # HSO | ||
2748 | 247 | libmm_plugin_hso_la_SOURCES = \ | ||
2749 | 248 | option/mm-plugin-hso.c \ | ||
2750 | 249 | option/mm-plugin-hso.h \ | ||
2751 | 250 | option/mm-broadband-modem-option.c \ | ||
2752 | 251 | option/mm-broadband-modem-option.h \ | ||
2753 | 252 | option/mm-broadband-bearer-hso.c \ | ||
2754 | 253 | option/mm-broadband-bearer-hso.h \ | ||
2755 | 254 | option/mm-broadband-modem-hso.c \ | ||
2756 | 255 | option/mm-broadband-modem-hso.h | ||
2757 | 256 | libmm_plugin_hso_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2758 | 257 | libmm_plugin_hso_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2759 | 258 | |||
2760 | 259 | # Sierra | ||
2761 | 260 | libmm_plugin_sierra_la_SOURCES = \ | ||
2762 | 261 | sierra/mm-plugin-sierra.c \ | ||
2763 | 262 | sierra/mm-plugin-sierra.h \ | ||
2764 | 263 | sierra/mm-common-sierra.c \ | ||
2765 | 264 | sierra/mm-common-sierra.h \ | ||
2766 | 265 | sierra/mm-sim-sierra.c \ | ||
2767 | 266 | sierra/mm-sim-sierra.h \ | ||
2768 | 267 | sierra/mm-broadband-bearer-sierra.c \ | ||
2769 | 268 | sierra/mm-broadband-bearer-sierra.h \ | ||
2770 | 269 | sierra/mm-broadband-modem-sierra.c \ | ||
2771 | 270 | sierra/mm-broadband-modem-sierra.h \ | ||
2772 | 271 | sierra/mm-broadband-modem-sierra-icera.c \ | ||
2773 | 272 | sierra/mm-broadband-modem-sierra-icera.h | ||
2774 | 273 | libmm_plugin_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
2775 | 274 | libmm_plugin_sierra_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2776 | 275 | libmm_plugin_sierra_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
2777 | 276 | |||
2778 | 277 | # Wavecom (Sierra Airlink) | ||
2779 | 278 | libmm_plugin_wavecom_la_SOURCES = \ | ||
2780 | 279 | wavecom/mm-plugin-wavecom.c \ | ||
2781 | 280 | wavecom/mm-plugin-wavecom.h \ | ||
2782 | 281 | wavecom/mm-broadband-modem-wavecom.c \ | ||
2783 | 282 | wavecom/mm-broadband-modem-wavecom.h | ||
2784 | 283 | libmm_plugin_wavecom_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2785 | 284 | libmm_plugin_wavecom_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2786 | 285 | |||
2787 | 286 | # Nokia | ||
2788 | 287 | libmm_plugin_nokia_la_SOURCES = \ | ||
2789 | 288 | nokia/mm-plugin-nokia.c \ | ||
2790 | 289 | nokia/mm-plugin-nokia.h \ | ||
2791 | 290 | nokia/mm-sim-nokia.c \ | ||
2792 | 291 | nokia/mm-sim-nokia.h \ | ||
2793 | 292 | nokia/mm-broadband-modem-nokia.c \ | ||
2794 | 293 | nokia/mm-broadband-modem-nokia.h | ||
2795 | 294 | libmm_plugin_nokia_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2796 | 295 | libmm_plugin_nokia_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2797 | 296 | |||
2798 | 297 | # Nokia (Icera) | ||
2799 | 298 | libmm_plugin_nokia_icera_la_SOURCES = \ | ||
2800 | 299 | nokia/mm-plugin-nokia-icera.c \ | ||
2801 | 300 | nokia/mm-plugin-nokia-icera.h | ||
2802 | 301 | libmm_plugin_nokia_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
2803 | 302 | libmm_plugin_nokia_icera_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2804 | 303 | libmm_plugin_nokia_icera_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
2805 | 304 | udevrules_DATA += nokia/77-mm-nokia-port-types.rules | ||
2806 | 305 | |||
2807 | 306 | # Zte | ||
2808 | 307 | libmm_plugin_zte_la_SOURCES = \ | ||
2809 | 308 | zte/mm-plugin-zte.c \ | ||
2810 | 309 | zte/mm-plugin-zte.h \ | ||
2811 | 310 | zte/mm-common-zte.h \ | ||
2812 | 311 | zte/mm-common-zte.c \ | ||
2813 | 312 | zte/mm-broadband-modem-zte.h \ | ||
2814 | 313 | zte/mm-broadband-modem-zte.c \ | ||
2815 | 314 | zte/mm-broadband-modem-zte-icera.h \ | ||
2816 | 315 | zte/mm-broadband-modem-zte-icera.c | ||
2817 | 316 | libmm_plugin_zte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
2818 | 317 | libmm_plugin_zte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2819 | 318 | libmm_plugin_zte_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
2820 | 319 | udevrules_DATA += zte/77-mm-zte-port-types.rules | ||
2821 | 320 | |||
2822 | 321 | # Longcheer (and rebranded dongles) | ||
2823 | 322 | libmm_plugin_longcheer_la_SOURCES = \ | ||
2824 | 323 | longcheer/mm-plugin-longcheer.c \ | ||
2825 | 324 | longcheer/mm-plugin-longcheer.h \ | ||
2826 | 325 | longcheer/mm-broadband-modem-longcheer.h \ | ||
2827 | 326 | longcheer/mm-broadband-modem-longcheer.c | ||
2828 | 327 | libmm_plugin_longcheer_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2829 | 328 | libmm_plugin_longcheer_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2830 | 329 | udevrules_DATA += longcheer/77-mm-longcheer-port-types.rules | ||
2831 | 330 | |||
2832 | 331 | # AnyData CDMA | ||
2833 | 332 | libmm_plugin_anydata_la_SOURCES = \ | ||
2834 | 333 | anydata/mm-plugin-anydata.c \ | ||
2835 | 334 | anydata/mm-plugin-anydata.h \ | ||
2836 | 335 | anydata/mm-broadband-modem-anydata.h \ | ||
2837 | 336 | anydata/mm-broadband-modem-anydata.c | ||
2838 | 337 | libmm_plugin_anydata_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2839 | 338 | libmm_plugin_anydata_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2840 | 339 | |||
2841 | 340 | # Linktop CDMA | ||
2842 | 341 | libmm_plugin_linktop_la_SOURCES = \ | ||
2843 | 342 | linktop/mm-plugin-linktop.c \ | ||
2844 | 343 | linktop/mm-plugin-linktop.h \ | ||
2845 | 344 | linktop/mm-broadband-modem-linktop.h \ | ||
2846 | 345 | linktop/mm-broadband-modem-linktop.c | ||
2847 | 346 | libmm_plugin_linktop_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2848 | 347 | libmm_plugin_linktop_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2849 | 348 | |||
2850 | 349 | # SimTech | ||
2851 | 350 | libmm_plugin_simtech_la_SOURCES = \ | ||
2852 | 351 | simtech/mm-plugin-simtech.c \ | ||
2853 | 352 | simtech/mm-plugin-simtech.h \ | ||
2854 | 353 | simtech/mm-broadband-modem-simtech.h \ | ||
2855 | 354 | simtech/mm-broadband-modem-simtech.c | ||
2856 | 355 | libmm_plugin_simtech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2857 | 356 | libmm_plugin_simtech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2858 | 357 | udevrules_DATA += simtech/77-mm-simtech-port-types.rules | ||
2859 | 358 | |||
2860 | 359 | # Alcatel/TCT/JRD x220D and possibly others | ||
2861 | 360 | libmm_plugin_x22x_la_SOURCES = \ | ||
2862 | 361 | x22x/mm-plugin-x22x.c \ | ||
2863 | 362 | x22x/mm-plugin-x22x.h \ | ||
2864 | 363 | x22x/mm-broadband-modem-x22x.h \ | ||
2865 | 364 | x22x/mm-broadband-modem-x22x.c | ||
2866 | 365 | libmm_plugin_x22x_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2867 | 366 | libmm_plugin_x22x_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2868 | 367 | udevrules_DATA += x22x/77-mm-x22x-port-types.rules | ||
2869 | 368 | |||
2870 | 369 | # Pantech | ||
2871 | 370 | libmm_plugin_pantech_la_SOURCES = \ | ||
2872 | 371 | pantech/mm-plugin-pantech.c \ | ||
2873 | 372 | pantech/mm-plugin-pantech.h \ | ||
2874 | 373 | pantech/mm-sim-pantech.c \ | ||
2875 | 374 | pantech/mm-sim-pantech.h \ | ||
2876 | 375 | pantech/mm-broadband-modem-pantech.c \ | ||
2877 | 376 | pantech/mm-broadband-modem-pantech.h | ||
2878 | 377 | libmm_plugin_pantech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2879 | 378 | libmm_plugin_pantech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2880 | 379 | |||
2881 | 380 | # Samsung modem | ||
2882 | 381 | libmm_plugin_samsung_la_SOURCES = \ | ||
2883 | 382 | samsung/mm-plugin-samsung.c \ | ||
2884 | 383 | samsung/mm-plugin-samsung.h \ | ||
2885 | 384 | samsung/mm-broadband-modem-samsung.c \ | ||
2886 | 385 | samsung/mm-broadband-modem-samsung.h | ||
2887 | 386 | libmm_plugin_samsung_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
2888 | 387 | libmm_plugin_samsung_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2889 | 388 | libmm_plugin_samsung_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
2890 | 389 | |||
2891 | 390 | # Cinterion (previously Siemens) modem | ||
2892 | 391 | libmm_plugin_cinterion_la_SOURCES = \ | ||
2893 | 392 | cinterion/mm-plugin-cinterion.c \ | ||
2894 | 393 | cinterion/mm-plugin-cinterion.h \ | ||
2895 | 394 | cinterion/mm-modem-helpers-cinterion.c \ | ||
2896 | 395 | cinterion/mm-modem-helpers-cinterion.h \ | ||
2897 | 396 | cinterion/mm-common-cinterion.c \ | ||
2898 | 397 | cinterion/mm-common-cinterion.h \ | ||
2899 | 398 | cinterion/mm-broadband-modem-cinterion.c \ | ||
2900 | 399 | cinterion/mm-broadband-modem-cinterion.h | ||
2901 | 400 | |||
2902 | 401 | if WITH_QMI | ||
2903 | 402 | libmm_plugin_cinterion_la_SOURCES += \ | ||
2904 | 403 | cinterion/mm-broadband-modem-qmi-cinterion.c \ | ||
2905 | 404 | cinterion/mm-broadband-modem-qmi-cinterion.h | ||
2906 | 405 | endif | ||
2907 | 406 | |||
2908 | 407 | libmm_plugin_cinterion_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2909 | 408 | libmm_plugin_cinterion_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2910 | 409 | |||
2911 | 410 | udevrules_DATA += cinterion/77-mm-cinterion-port-types.rules | ||
2912 | 411 | |||
2913 | 412 | noinst_PROGRAMS += test-modem-helpers-cinterion | ||
2914 | 413 | test_modem_helpers_cinterion_SOURCES = \ | ||
2915 | 414 | cinterion/mm-modem-helpers-cinterion.c \ | ||
2916 | 415 | cinterion/mm-modem-helpers-cinterion.h \ | ||
2917 | 416 | cinterion/tests/test-modem-helpers-cinterion.c | ||
2918 | 417 | test_modem_helpers_cinterion_CPPFLAGS = \ | ||
2919 | 418 | -I$(top_srcdir)/plugins/cinterion \ | ||
2920 | 419 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2921 | 420 | test_modem_helpers_cinterion_LDADD = \ | ||
2922 | 421 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
2923 | 422 | $(top_builddir)/src/libmodem-helpers.la | ||
2924 | 423 | test_modem_helpers_cinterion_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2925 | 424 | |||
2926 | 425 | # Iridium modem | ||
2927 | 426 | libmm_plugin_iridium_la_SOURCES = \ | ||
2928 | 427 | iridium/mm-plugin-iridium.c \ | ||
2929 | 428 | iridium/mm-plugin-iridium.h \ | ||
2930 | 429 | iridium/mm-broadband-modem-iridium.c \ | ||
2931 | 430 | iridium/mm-broadband-modem-iridium.h \ | ||
2932 | 431 | iridium/mm-bearer-iridium.c \ | ||
2933 | 432 | iridium/mm-bearer-iridium.h \ | ||
2934 | 433 | iridium/mm-sim-iridium.c \ | ||
2935 | 434 | iridium/mm-sim-iridium.h | ||
2936 | 435 | libmm_plugin_iridium_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2937 | 436 | libmm_plugin_iridium_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2938 | 437 | |||
2939 | 438 | # Novatel LTE modem | ||
2940 | 439 | libmm_plugin_novatel_lte_la_SOURCES = \ | ||
2941 | 440 | novatel/mm-plugin-novatel-lte.c \ | ||
2942 | 441 | novatel/mm-plugin-novatel-lte.h \ | ||
2943 | 442 | novatel/mm-broadband-modem-novatel-lte.c \ | ||
2944 | 443 | novatel/mm-broadband-modem-novatel-lte.h \ | ||
2945 | 444 | novatel/mm-broadband-bearer-novatel-lte.c \ | ||
2946 | 445 | novatel/mm-broadband-bearer-novatel-lte.h \ | ||
2947 | 446 | novatel/mm-sim-novatel-lte.c \ | ||
2948 | 447 | novatel/mm-sim-novatel-lte.h | ||
2949 | 448 | libmm_plugin_novatel_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2950 | 449 | libmm_plugin_novatel_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2951 | 450 | |||
2952 | 451 | # Novatel non-LTE modem | ||
2953 | 452 | libmm_plugin_novatel_la_SOURCES = \ | ||
2954 | 453 | novatel/mm-plugin-novatel.c \ | ||
2955 | 454 | novatel/mm-plugin-novatel.h \ | ||
2956 | 455 | novatel/mm-broadband-modem-novatel.c \ | ||
2957 | 456 | novatel/mm-broadband-modem-novatel.h | ||
2958 | 457 | libmm_plugin_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2959 | 458 | libmm_plugin_novatel_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2960 | 459 | |||
2961 | 460 | # Altair LTE modem | ||
2962 | 461 | libmm_plugin_altair_lte_la_SOURCES = \ | ||
2963 | 462 | altair/mm-modem-helpers-altair-lte.c \ | ||
2964 | 463 | altair/mm-modem-helpers-altair-lte.h \ | ||
2965 | 464 | altair/mm-plugin-altair-lte.c \ | ||
2966 | 465 | altair/mm-plugin-altair-lte.h \ | ||
2967 | 466 | altair/mm-broadband-modem-altair-lte.c \ | ||
2968 | 467 | altair/mm-broadband-modem-altair-lte.h \ | ||
2969 | 468 | altair/mm-broadband-bearer-altair-lte.c \ | ||
2970 | 469 | altair/mm-broadband-bearer-altair-lte.h | ||
2971 | 470 | libmm_plugin_altair_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2972 | 471 | libmm_plugin_altair_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2973 | 472 | |||
2974 | 473 | noinst_PROGRAMS += test-modem-helpers-altair-lte | ||
2975 | 474 | test_modem_helpers_altair_lte_SOURCES = \ | ||
2976 | 475 | altair/mm-modem-helpers-altair-lte.c \ | ||
2977 | 476 | altair/mm-modem-helpers-altair-lte.h \ | ||
2978 | 477 | altair/tests/test-modem-helpers-altair-lte.c | ||
2979 | 478 | test_modem_helpers_altair_lte_CPPFLAGS = \ | ||
2980 | 479 | -I$(top_srcdir)/plugins/altair \ | ||
2981 | 480 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2982 | 481 | test_modem_helpers_altair_lte_LDADD = $(top_builddir)/libmm-glib/libmm-glib.la | ||
2983 | 482 | test_modem_helpers_altair_lte_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2984 | 483 | |||
2985 | 484 | |||
2986 | 485 | # VIA modem | ||
2987 | 486 | libmm_plugin_via_la_SOURCES = \ | ||
2988 | 487 | via/mm-plugin-via.c \ | ||
2989 | 488 | via/mm-plugin-via.h \ | ||
2990 | 489 | via/mm-broadband-modem-via.c \ | ||
2991 | 490 | via/mm-broadband-modem-via.h | ||
2992 | 491 | libmm_plugin_via_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
2993 | 492 | libmm_plugin_via_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
2994 | 493 | |||
2995 | 494 | # Telit modem | ||
2996 | 495 | libmm_plugin_telit_la_SOURCES = \ | ||
2997 | 496 | telit/mm-plugin-telit.c \ | ||
2998 | 497 | telit/mm-plugin-telit.h \ | ||
2999 | 498 | telit/mm-broadband-modem-telit.c \ | ||
3000 | 499 | telit/mm-broadband-modem-telit.h | ||
3001 | 500 | libmm_plugin_telit_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3002 | 501 | libmm_plugin_telit_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3003 | 502 | udevrules_DATA += telit/77-mm-telit-port-types.rules | ||
3004 | 503 | |||
3005 | 504 | # MTK | ||
3006 | 505 | libmm_plugin_mtk_la_SOURCES = \ | ||
3007 | 506 | mtk/mm-plugin-mtk.c \ | ||
3008 | 507 | mtk/mm-plugin-mtk.h \ | ||
3009 | 508 | mtk/mm-broadband-modem-mtk.h \ | ||
3010 | 509 | mtk/mm-broadband-modem-mtk.c | ||
3011 | 510 | libmm_plugin_mtk_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3012 | 511 | libmm_plugin_mtk_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3013 | 512 | udevrules_DATA += mtk/77-mm-mtk-port-types.rules | ||
3014 | 513 | |||
3015 | 514 | |||
3016 | 515 | # Additional files to include in the distribution | ||
3017 | 516 | EXTRA_DIST += \ | ||
3018 | 517 | $(udevrules_DATA) \ | ||
3019 | 518 | tests/gsm-port.conf | ||
3020 | 519 | |||
3021 | 520 | # Unit tests | ||
3022 | 521 | TEST_PROGS += $(noinst_PROGRAMS) | ||
3023 | 0 | 522 | ||
3024 | === added directory '.pc/novatel-custom-init.patch/plugins/novatel' | |||
3025 | === added file '.pc/novatel-custom-init.patch/plugins/novatel/mm-common-novatel.c' | |||
3026 | === added file '.pc/novatel-custom-init.patch/plugins/novatel/mm-common-novatel.h' | |||
3027 | === added file '.pc/novatel-custom-init.patch/plugins/novatel/mm-plugin-novatel.c' | |||
3028 | --- .pc/novatel-custom-init.patch/plugins/novatel/mm-plugin-novatel.c 1970-01-01 00:00:00 +0000 | |||
3029 | +++ .pc/novatel-custom-init.patch/plugins/novatel/mm-plugin-novatel.c 2015-10-09 10:06:57 +0000 | |||
3030 | @@ -0,0 +1,267 @@ | |||
3031 | 1 | /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ | ||
3032 | 2 | |||
3033 | 3 | /* | ||
3034 | 4 | * This program is free software; you can redistribute it and/or | ||
3035 | 5 | * modify it under the terms of the GNU General Public License as | ||
3036 | 6 | * published by the Free Software Foundation; either version 2 of the | ||
3037 | 7 | * License, or (at your option) any later version. | ||
3038 | 8 | * | ||
3039 | 9 | * This program is distributed in the hope that it will be useful, | ||
3040 | 10 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
3041 | 11 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
3042 | 12 | * General Public License for more details. | ||
3043 | 13 | * | ||
3044 | 14 | * You should have received a copy of the GNU General Public | ||
3045 | 15 | * License along with this program; if not, write to the | ||
3046 | 16 | * Free Software Foundation, Inc., 59 Temple Place - Suite 330, | ||
3047 | 17 | * Boston, MA 02111-1307, USA. | ||
3048 | 18 | * | ||
3049 | 19 | * Copyright (C) 2008 - 2009 Novell, Inc. | ||
3050 | 20 | * Copyright (C) 2009 - 2012 Red Hat, Inc. | ||
3051 | 21 | * Copyright (C) 2012 Aleksander Morgado <aleksander@gnu.org> | ||
3052 | 22 | */ | ||
3053 | 23 | |||
3054 | 24 | #include <string.h> | ||
3055 | 25 | #include <gmodule.h> | ||
3056 | 26 | |||
3057 | 27 | #define _LIBMM_INSIDE_MM | ||
3058 | 28 | #include <libmm-glib.h> | ||
3059 | 29 | |||
3060 | 30 | #include "mm-plugin-novatel.h" | ||
3061 | 31 | #include "mm-private-boxed-types.h" | ||
3062 | 32 | #include "mm-broadband-modem-novatel.h" | ||
3063 | 33 | #include "mm-log.h" | ||
3064 | 34 | |||
3065 | 35 | #if defined WITH_QMI | ||
3066 | 36 | #include "mm-broadband-modem-qmi.h" | ||
3067 | 37 | #endif | ||
3068 | 38 | |||
3069 | 39 | G_DEFINE_TYPE (MMPluginNovatel, mm_plugin_novatel, MM_TYPE_PLUGIN) | ||
3070 | 40 | |||
3071 | 41 | int mm_plugin_major_version = MM_PLUGIN_MAJOR_VERSION; | ||
3072 | 42 | int mm_plugin_minor_version = MM_PLUGIN_MINOR_VERSION; | ||
3073 | 43 | |||
3074 | 44 | /*****************************************************************************/ | ||
3075 | 45 | /* Custom commands for AT probing */ | ||
3076 | 46 | |||
3077 | 47 | /* We need to explicitly flip secondary ports to AT mode. | ||
3078 | 48 | * We also use this command also for checking AT support in the current port. | ||
3079 | 49 | */ | ||
3080 | 50 | static const MMPortProbeAtCommand custom_at_probe[] = { | ||
3081 | 51 | { "$NWDMAT=1", 3, mm_port_probe_response_processor_is_at }, | ||
3082 | 52 | { "$NWDMAT=1", 3, mm_port_probe_response_processor_is_at }, | ||
3083 | 53 | { "$NWDMAT=1", 3, mm_port_probe_response_processor_is_at }, | ||
3084 | 54 | { NULL } | ||
3085 | 55 | }; | ||
3086 | 56 | |||
3087 | 57 | /*****************************************************************************/ | ||
3088 | 58 | /* Custom init */ | ||
3089 | 59 | |||
3090 | 60 | typedef struct { | ||
3091 | 61 | MMPortProbe *probe; | ||
3092 | 62 | MMPortSerialAt *port; | ||
3093 | 63 | GCancellable *cancellable; | ||
3094 | 64 | GSimpleAsyncResult *result; | ||
3095 | 65 | guint nwdmat_retries; | ||
3096 | 66 | guint wait_time; | ||
3097 | 67 | } CustomInitContext; | ||
3098 | 68 | |||
3099 | 69 | static void | ||
3100 | 70 | custom_init_context_complete_and_free (CustomInitContext *ctx) | ||
3101 | 71 | { | ||
3102 | 72 | g_simple_async_result_complete_in_idle (ctx->result); | ||
3103 | 73 | |||
3104 | 74 | if (ctx->cancellable) | ||
3105 | 75 | g_object_unref (ctx->cancellable); | ||
3106 | 76 | g_object_unref (ctx->port); | ||
3107 | 77 | g_object_unref (ctx->probe); | ||
3108 | 78 | g_object_unref (ctx->result); | ||
3109 | 79 | g_slice_free (CustomInitContext, ctx); | ||
3110 | 80 | } | ||
3111 | 81 | |||
3112 | 82 | static gboolean | ||
3113 | 83 | novatel_custom_init_finish (MMPortProbe *probe, | ||
3114 | 84 | GAsyncResult *result, | ||
3115 | 85 | GError **error) | ||
3116 | 86 | { | ||
3117 | 87 | return !g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (result), error); | ||
3118 | 88 | } | ||
3119 | 89 | |||
3120 | 90 | static void custom_init_step (CustomInitContext *ctx); | ||
3121 | 91 | |||
3122 | 92 | static void | ||
3123 | 93 | nwdmat_ready (MMPortSerialAt *port, | ||
3124 | 94 | GAsyncResult *res, | ||
3125 | 95 | CustomInitContext *ctx) | ||
3126 | 96 | { | ||
3127 | 97 | const gchar *response; | ||
3128 | 98 | GError *error = NULL; | ||
3129 | 99 | |||
3130 | 100 | response = mm_port_serial_at_command_finish (port, res, &error); | ||
3131 | 101 | if (error) { | ||
3132 | 102 | if (g_error_matches (error, | ||
3133 | 103 | MM_SERIAL_ERROR, | ||
3134 | 104 | MM_SERIAL_ERROR_RESPONSE_TIMEOUT)) { | ||
3135 | 105 | custom_init_step (ctx); | ||
3136 | 106 | goto out; | ||
3137 | 107 | } | ||
3138 | 108 | |||
3139 | 109 | mm_dbg ("(Novatel) Error flipping secondary ports to AT mode: %s", error->message); | ||
3140 | 110 | } | ||
3141 | 111 | |||
3142 | 112 | /* Finish custom_init */ | ||
3143 | 113 | g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
3144 | 114 | custom_init_context_complete_and_free (ctx); | ||
3145 | 115 | |||
3146 | 116 | out: | ||
3147 | 117 | if (error) | ||
3148 | 118 | g_error_free (error); | ||
3149 | 119 | } | ||
3150 | 120 | |||
3151 | 121 | static gboolean | ||
3152 | 122 | custom_init_wait_cb (CustomInitContext *ctx) | ||
3153 | 123 | { | ||
3154 | 124 | custom_init_step (ctx); | ||
3155 | 125 | return FALSE; | ||
3156 | 126 | } | ||
3157 | 127 | |||
3158 | 128 | static void | ||
3159 | 129 | custom_init_step (CustomInitContext *ctx) | ||
3160 | 130 | { | ||
3161 | 131 | /* If cancelled, end */ | ||
3162 | 132 | if (g_cancellable_is_cancelled (ctx->cancellable)) { | ||
3163 | 133 | mm_dbg ("(Novatel) no need to keep on running custom init in (%s)", | ||
3164 | 134 | mm_port_get_device (MM_PORT (ctx->port))); | ||
3165 | 135 | g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
3166 | 136 | custom_init_context_complete_and_free (ctx); | ||
3167 | 137 | return; | ||
3168 | 138 | } | ||
3169 | 139 | |||
3170 | 140 | /* If device has a QMI port, don't run $NWDMAT */ | ||
3171 | 141 | if (mm_port_probe_list_has_qmi_port (mm_device_peek_port_probe_list (mm_port_probe_peek_device (ctx->probe)))) { | ||
3172 | 142 | mm_dbg ("(Novatel) no need to run custom init in (%s): device has QMI port", | ||
3173 | 143 | mm_port_get_device (MM_PORT (ctx->port))); | ||
3174 | 144 | g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
3175 | 145 | custom_init_context_complete_and_free (ctx); | ||
3176 | 146 | return; | ||
3177 | 147 | } | ||
3178 | 148 | |||
3179 | 149 | if (ctx->wait_time > 0) { | ||
3180 | 150 | ctx->wait_time--; | ||
3181 | 151 | g_timeout_add_seconds (1, (GSourceFunc)custom_init_wait_cb, ctx); | ||
3182 | 152 | return; | ||
3183 | 153 | } | ||
3184 | 154 | |||
3185 | 155 | if (ctx->nwdmat_retries > 0) { | ||
3186 | 156 | ctx->nwdmat_retries--; | ||
3187 | 157 | mm_port_serial_at_command (ctx->port, | ||
3188 | 158 | "$NWDMAT=1", | ||
3189 | 159 | 3, | ||
3190 | 160 | FALSE, /* raw */ | ||
3191 | 161 | FALSE, /* allow_cached */ | ||
3192 | 162 | ctx->cancellable, | ||
3193 | 163 | (GAsyncReadyCallback)nwdmat_ready, | ||
3194 | 164 | ctx); | ||
3195 | 165 | return; | ||
3196 | 166 | } | ||
3197 | 167 | |||
3198 | 168 | /* Finish custom_init */ | ||
3199 | 169 | mm_dbg ("(Novatel) couldn't flip secondary port to AT in (%s): all retries consumed", | ||
3200 | 170 | mm_port_get_device (MM_PORT (ctx->port))); | ||
3201 | 171 | g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
3202 | 172 | custom_init_context_complete_and_free (ctx); | ||
3203 | 173 | } | ||
3204 | 174 | |||
3205 | 175 | static void | ||
3206 | 176 | novatel_custom_init (MMPortProbe *probe, | ||
3207 | 177 | MMPortSerialAt *port, | ||
3208 | 178 | GCancellable *cancellable, | ||
3209 | 179 | GAsyncReadyCallback callback, | ||
3210 | 180 | gpointer user_data) | ||
3211 | 181 | { | ||
3212 | 182 | CustomInitContext *ctx; | ||
3213 | 183 | |||
3214 | 184 | ctx = g_slice_new (CustomInitContext); | ||
3215 | 185 | ctx->result = g_simple_async_result_new (G_OBJECT (probe), | ||
3216 | 186 | callback, | ||
3217 | 187 | user_data, | ||
3218 | 188 | novatel_custom_init); | ||
3219 | 189 | ctx->probe = g_object_ref (probe); | ||
3220 | 190 | ctx->port = g_object_ref (port); | ||
3221 | 191 | ctx->cancellable = cancellable ? g_object_ref (cancellable) : NULL; | ||
3222 | 192 | ctx->nwdmat_retries = 3; | ||
3223 | 193 | ctx->wait_time = 2; | ||
3224 | 194 | |||
3225 | 195 | custom_init_step (ctx); | ||
3226 | 196 | } | ||
3227 | 197 | |||
3228 | 198 | /*****************************************************************************/ | ||
3229 | 199 | |||
3230 | 200 | static MMBaseModem * | ||
3231 | 201 | create_modem (MMPlugin *self, | ||
3232 | 202 | const gchar *sysfs_path, | ||
3233 | 203 | const gchar **drivers, | ||
3234 | 204 | guint16 vendor, | ||
3235 | 205 | guint16 product, | ||
3236 | 206 | GList *probes, | ||
3237 | 207 | GError **error) | ||
3238 | 208 | { | ||
3239 | 209 | #if defined WITH_QMI | ||
3240 | 210 | if (mm_port_probe_list_has_qmi_port (probes)) { | ||
3241 | 211 | mm_dbg ("QMI-powered Novatel modem found..."); | ||
3242 | 212 | return MM_BASE_MODEM (mm_broadband_modem_qmi_new (sysfs_path, | ||
3243 | 213 | drivers, | ||
3244 | 214 | mm_plugin_get_name (self), | ||
3245 | 215 | vendor, | ||
3246 | 216 | product)); | ||
3247 | 217 | } | ||
3248 | 218 | #endif | ||
3249 | 219 | |||
3250 | 220 | return MM_BASE_MODEM (mm_broadband_modem_novatel_new (sysfs_path, | ||
3251 | 221 | drivers, | ||
3252 | 222 | mm_plugin_get_name (self), | ||
3253 | 223 | vendor, | ||
3254 | 224 | product)); | ||
3255 | 225 | } | ||
3256 | 226 | |||
3257 | 227 | /*****************************************************************************/ | ||
3258 | 228 | |||
3259 | 229 | G_MODULE_EXPORT MMPlugin * | ||
3260 | 230 | mm_plugin_create (void) | ||
3261 | 231 | { | ||
3262 | 232 | static const gchar *subsystems[] = { "tty", "net", "usb", NULL }; | ||
3263 | 233 | static const guint16 vendors[] = { 0x1410, /* Novatel */ | ||
3264 | 234 | 0x413c, /* Dell */ | ||
3265 | 235 | 0 }; | ||
3266 | 236 | static const mm_uint16_pair forbidden_products[] = { { 0x1410, 0x9010 }, /* Novatel E362 */ | ||
3267 | 237 | { 0, 0 } }; | ||
3268 | 238 | static const MMAsyncMethod custom_init = { | ||
3269 | 239 | .async = G_CALLBACK (novatel_custom_init), | ||
3270 | 240 | .finish = G_CALLBACK (novatel_custom_init_finish), | ||
3271 | 241 | }; | ||
3272 | 242 | |||
3273 | 243 | return MM_PLUGIN ( | ||
3274 | 244 | g_object_new (MM_TYPE_PLUGIN_NOVATEL, | ||
3275 | 245 | MM_PLUGIN_NAME, "Novatel", | ||
3276 | 246 | MM_PLUGIN_ALLOWED_SUBSYSTEMS, subsystems, | ||
3277 | 247 | MM_PLUGIN_ALLOWED_VENDOR_IDS, vendors, | ||
3278 | 248 | MM_PLUGIN_FORBIDDEN_PRODUCT_IDS, forbidden_products, | ||
3279 | 249 | MM_PLUGIN_ALLOWED_AT, TRUE, | ||
3280 | 250 | MM_PLUGIN_CUSTOM_INIT, &custom_init, | ||
3281 | 251 | MM_PLUGIN_ALLOWED_QCDM, TRUE, | ||
3282 | 252 | MM_PLUGIN_ALLOWED_QMI, TRUE, | ||
3283 | 253 | NULL)); | ||
3284 | 254 | } | ||
3285 | 255 | |||
3286 | 256 | static void | ||
3287 | 257 | mm_plugin_novatel_init (MMPluginNovatel *self) | ||
3288 | 258 | { | ||
3289 | 259 | } | ||
3290 | 260 | |||
3291 | 261 | static void | ||
3292 | 262 | mm_plugin_novatel_class_init (MMPluginNovatelClass *klass) | ||
3293 | 263 | { | ||
3294 | 264 | MMPluginClass *plugin_class = MM_PLUGIN_CLASS (klass); | ||
3295 | 265 | |||
3296 | 266 | plugin_class->create_modem = create_modem; | ||
3297 | 267 | } | ||
3298 | 0 | 268 | ||
3299 | === added directory '.pc/sierra-common-library.patch' | |||
3300 | === added directory '.pc/sierra-common-library.patch/plugins' | |||
3301 | === added file '.pc/sierra-common-library.patch/plugins/Makefile.am' | |||
3302 | --- .pc/sierra-common-library.patch/plugins/Makefile.am 1970-01-01 00:00:00 +0000 | |||
3303 | +++ .pc/sierra-common-library.patch/plugins/Makefile.am 2015-10-09 10:06:57 +0000 | |||
3304 | @@ -0,0 +1,533 @@ | |||
3305 | 1 | |||
3306 | 2 | include $(top_srcdir)/gtester.make | ||
3307 | 3 | |||
3308 | 4 | # Common CPPFLAGS and LDFLAGS | ||
3309 | 5 | |||
3310 | 6 | PLUGIN_COMMON_COMPILER_FLAGS = \ | ||
3311 | 7 | $(MM_CFLAGS) \ | ||
3312 | 8 | $(GUDEV_CFLAGS) \ | ||
3313 | 9 | -I$(top_srcdir) \ | ||
3314 | 10 | -I$(top_srcdir)/src \ | ||
3315 | 11 | -I$(top_builddir)/src \ | ||
3316 | 12 | -I$(top_srcdir)/include \ | ||
3317 | 13 | -I$(top_builddir)/include \ | ||
3318 | 14 | -I$(top_srcdir)/libmm-glib \ | ||
3319 | 15 | -I$(top_srcdir)/libmm-glib/generated \ | ||
3320 | 16 | -I$(top_builddir)/libmm-glib/generated | ||
3321 | 17 | |||
3322 | 18 | PLUGIN_COMMON_LINKER_FLAGS = \ | ||
3323 | 19 | $(GUDEV_LIBS) \ | ||
3324 | 20 | $(MM_LIBS) \ | ||
3325 | 21 | -module \ | ||
3326 | 22 | -avoid-version | ||
3327 | 23 | |||
3328 | 24 | if WITH_QMI | ||
3329 | 25 | PLUGIN_COMMON_COMPILER_FLAGS += $(QMI_CFLAGS) | ||
3330 | 26 | PLUGIN_COMMON_LINKER_FLAGS += $(QMI_LIBS) | ||
3331 | 27 | endif | ||
3332 | 28 | |||
3333 | 29 | if WITH_MBIM | ||
3334 | 30 | PLUGIN_COMMON_COMPILER_FLAGS += $(MBIM_CFLAGS) | ||
3335 | 31 | PLUGIN_COMMON_LINKER_FLAGS += $(MBIM_LIBS) | ||
3336 | 32 | endif | ||
3337 | 33 | |||
3338 | 34 | # UDev rules | ||
3339 | 35 | udevrulesdir = $(UDEV_BASE_DIR)/rules.d | ||
3340 | 36 | udevrules_DATA = | ||
3341 | 37 | |||
3342 | 38 | # Unit tests | ||
3343 | 39 | noinst_PROGRAMS = | ||
3344 | 40 | |||
3345 | 41 | # Helper libs | ||
3346 | 42 | noinst_LTLIBRARIES = | ||
3347 | 43 | |||
3348 | 44 | ######################################## | ||
3349 | 45 | |||
3350 | 46 | # Common service test support | ||
3351 | 47 | |||
3352 | 48 | noinst_LTLIBRARIES += libmm-test-common.la | ||
3353 | 49 | |||
3354 | 50 | libmm_test_common_la_SOURCES = \ | ||
3355 | 51 | tests/test-fixture.h \ | ||
3356 | 52 | tests/test-fixture.c \ | ||
3357 | 53 | tests/test-port-context.h \ | ||
3358 | 54 | tests/test-port-context.c | ||
3359 | 55 | |||
3360 | 56 | libmm_test_common_la_CPPFLAGS = \ | ||
3361 | 57 | $(MM_CFLAGS) \ | ||
3362 | 58 | -I$(top_srcdir)/include \ | ||
3363 | 59 | -I$(top_builddir)/include \ | ||
3364 | 60 | -I$(top_srcdir)/libmm-glib \ | ||
3365 | 61 | -I$(top_srcdir)/libmm-glib/generated \ | ||
3366 | 62 | -I$(top_builddir)/libmm-glib/generated \ | ||
3367 | 63 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
3368 | 64 | -DTEST_SERVICES=\""$(abs_top_builddir)/data/tests"\" | ||
3369 | 65 | |||
3370 | 66 | libmm_test_common_la_LIBADD = \ | ||
3371 | 67 | ${top_builddir}/libmm-glib/generated/tests/libmm-test-generated.la \ | ||
3372 | 68 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
3373 | 69 | |||
3374 | 70 | TEST_COMMON_COMPILER_FLAGS = \ | ||
3375 | 71 | $(MM_CFLAGS) \ | ||
3376 | 72 | -I$(top_srcdir)/plugins/tests \ | ||
3377 | 73 | -I$(top_srcdir)/include \ | ||
3378 | 74 | -I$(top_builddir)/include \ | ||
3379 | 75 | -I$(top_srcdir)/libmm-glib \ | ||
3380 | 76 | -I$(top_srcdir)/libmm-glib/generated \ | ||
3381 | 77 | -I$(top_builddir)/libmm-glib/generated \ | ||
3382 | 78 | -I$(top_builddir)/libmm-glib/generated/tests \ | ||
3383 | 79 | -DCOMMON_GSM_PORT_CONF=\""$(abs_top_srcdir)/plugins/tests/gsm-port.conf"\" | ||
3384 | 80 | |||
3385 | 81 | TEST_COMMON_LIBADD_FLAGS = \ | ||
3386 | 82 | $(builddir)/libmm-test-common.la \ | ||
3387 | 83 | $(top_builddir)/libmm-glib/libmm-glib.la | ||
3388 | 84 | |||
3389 | 85 | |||
3390 | 86 | ######################################## | ||
3391 | 87 | |||
3392 | 88 | # Icera-specific support | ||
3393 | 89 | noinst_LTLIBRARIES += libmm-utils-icera.la | ||
3394 | 90 | libmm_utils_icera_la_SOURCES = \ | ||
3395 | 91 | icera/mm-broadband-modem-icera.h \ | ||
3396 | 92 | icera/mm-broadband-modem-icera.c \ | ||
3397 | 93 | icera/mm-broadband-bearer-icera.h \ | ||
3398 | 94 | icera/mm-broadband-bearer-icera.c \ | ||
3399 | 95 | icera/mm-modem-helpers-icera.c \ | ||
3400 | 96 | icera/mm-modem-helpers-icera.h | ||
3401 | 97 | libmm_utils_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3402 | 98 | libmm_utils_icera_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
3403 | 99 | |||
3404 | 100 | ICERA_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/icera | ||
3405 | 101 | ICERA_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-icera.la | ||
3406 | 102 | |||
3407 | 103 | noinst_PROGRAMS += test-modem-helpers-icera | ||
3408 | 104 | test_modem_helpers_icera_SOURCES = \ | ||
3409 | 105 | icera/mm-modem-helpers-icera.c \ | ||
3410 | 106 | icera/mm-modem-helpers-icera.h \ | ||
3411 | 107 | icera/tests/test-modem-helpers-icera.c | ||
3412 | 108 | test_modem_helpers_icera_CPPFLAGS = \ | ||
3413 | 109 | -I$(top_srcdir)/plugins/icera \ | ||
3414 | 110 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3415 | 111 | test_modem_helpers_icera_LDADD = \ | ||
3416 | 112 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
3417 | 113 | $(top_builddir)/src/libmodem-helpers.la | ||
3418 | 114 | test_modem_helpers_icera_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3419 | 115 | |||
3420 | 116 | ######################################## | ||
3421 | 117 | |||
3422 | 118 | pkglib_LTLIBRARIES = \ | ||
3423 | 119 | libmm-plugin-generic.la \ | ||
3424 | 120 | libmm-plugin-nokia.la \ | ||
3425 | 121 | libmm-plugin-nokia-icera.la \ | ||
3426 | 122 | libmm-plugin-cinterion.la \ | ||
3427 | 123 | libmm-plugin-iridium.la \ | ||
3428 | 124 | libmm-plugin-gobi.la \ | ||
3429 | 125 | libmm-plugin-motorola.la \ | ||
3430 | 126 | libmm-plugin-novatel.la \ | ||
3431 | 127 | libmm-plugin-novatel-lte.la \ | ||
3432 | 128 | libmm-plugin-altair-lte.la \ | ||
3433 | 129 | libmm-plugin-samsung.la \ | ||
3434 | 130 | libmm-plugin-option.la \ | ||
3435 | 131 | libmm-plugin-hso.la \ | ||
3436 | 132 | libmm-plugin-anydata.la \ | ||
3437 | 133 | libmm-plugin-linktop.la \ | ||
3438 | 134 | libmm-plugin-simtech.la \ | ||
3439 | 135 | libmm-plugin-wavecom.la \ | ||
3440 | 136 | libmm-plugin-huawei.la \ | ||
3441 | 137 | libmm-plugin-longcheer.la \ | ||
3442 | 138 | libmm-plugin-x22x.la \ | ||
3443 | 139 | libmm-plugin-pantech.la \ | ||
3444 | 140 | libmm-plugin-zte.la \ | ||
3445 | 141 | libmm-plugin-sierra.la \ | ||
3446 | 142 | libmm-plugin-mbm.la \ | ||
3447 | 143 | libmm-plugin-via.la \ | ||
3448 | 144 | libmm-plugin-telit.la \ | ||
3449 | 145 | libmm-plugin-mtk.la | ||
3450 | 146 | |||
3451 | 147 | # Generic | ||
3452 | 148 | libmm_plugin_generic_la_SOURCES = \ | ||
3453 | 149 | generic/mm-plugin-generic.c \ | ||
3454 | 150 | generic/mm-plugin-generic.h | ||
3455 | 151 | libmm_plugin_generic_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3456 | 152 | libmm_plugin_generic_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3457 | 153 | |||
3458 | 154 | noinst_PROGRAMS += test-service-generic | ||
3459 | 155 | test_service_generic_SOURCES = generic/tests/test-service-generic.c | ||
3460 | 156 | test_service_generic_CPPFLAGS = $(TEST_COMMON_COMPILER_FLAGS) | ||
3461 | 157 | test_service_generic_LDADD = $(TEST_COMMON_LIBADD_FLAGS) | ||
3462 | 158 | test_service_generic_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3463 | 159 | |||
3464 | 160 | ## Motorola | ||
3465 | 161 | libmm_plugin_motorola_la_SOURCES = \ | ||
3466 | 162 | motorola/mm-plugin-motorola.c \ | ||
3467 | 163 | motorola/mm-plugin-motorola.h \ | ||
3468 | 164 | motorola/mm-broadband-modem-motorola.c \ | ||
3469 | 165 | motorola/mm-broadband-modem-motorola.h | ||
3470 | 166 | libmm_plugin_motorola_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3471 | 167 | libmm_plugin_motorola_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3472 | 168 | |||
3473 | 169 | # Gobi | ||
3474 | 170 | libmm_plugin_gobi_la_SOURCES = \ | ||
3475 | 171 | gobi/mm-plugin-gobi.c \ | ||
3476 | 172 | gobi/mm-plugin-gobi.h \ | ||
3477 | 173 | gobi/mm-broadband-modem-gobi.c \ | ||
3478 | 174 | gobi/mm-broadband-modem-gobi.h | ||
3479 | 175 | libmm_plugin_gobi_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3480 | 176 | libmm_plugin_gobi_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3481 | 177 | |||
3482 | 178 | # Huawei | ||
3483 | 179 | libmm_plugin_huawei_la_SOURCES = \ | ||
3484 | 180 | huawei/mm-plugin-huawei.c \ | ||
3485 | 181 | huawei/mm-plugin-huawei.h \ | ||
3486 | 182 | huawei/mm-modem-helpers-huawei.c \ | ||
3487 | 183 | huawei/mm-modem-helpers-huawei.h \ | ||
3488 | 184 | huawei/mm-sim-huawei.c \ | ||
3489 | 185 | huawei/mm-sim-huawei.h \ | ||
3490 | 186 | huawei/mm-broadband-modem-huawei.c \ | ||
3491 | 187 | huawei/mm-broadband-modem-huawei.h \ | ||
3492 | 188 | huawei/mm-broadband-bearer-huawei.c \ | ||
3493 | 189 | huawei/mm-broadband-bearer-huawei.h | ||
3494 | 190 | libmm_plugin_huawei_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3495 | 191 | libmm_plugin_huawei_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3496 | 192 | |||
3497 | 193 | udevrules_DATA += huawei/77-mm-huawei-net-port-types.rules | ||
3498 | 194 | |||
3499 | 195 | noinst_PROGRAMS += test-modem-helpers-huawei | ||
3500 | 196 | test_modem_helpers_huawei_SOURCES = \ | ||
3501 | 197 | huawei/mm-modem-helpers-huawei.c \ | ||
3502 | 198 | huawei/mm-modem-helpers-huawei.h \ | ||
3503 | 199 | huawei/tests/test-modem-helpers-huawei.c | ||
3504 | 200 | test_modem_helpers_huawei_CPPFLAGS = \ | ||
3505 | 201 | -I$(top_srcdir)/plugins/huawei \ | ||
3506 | 202 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3507 | 203 | test_modem_helpers_huawei_LDADD = \ | ||
3508 | 204 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
3509 | 205 | $(top_builddir)/src/libmodem-helpers.la | ||
3510 | 206 | test_modem_helpers_huawei_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3511 | 207 | |||
3512 | 208 | # MBM | ||
3513 | 209 | libmm_plugin_mbm_la_SOURCES = \ | ||
3514 | 210 | mbm/mm-plugin-mbm.c \ | ||
3515 | 211 | mbm/mm-plugin-mbm.h \ | ||
3516 | 212 | mbm/mm-broadband-modem-mbm.c \ | ||
3517 | 213 | mbm/mm-broadband-modem-mbm.h \ | ||
3518 | 214 | mbm/mm-broadband-bearer-mbm.c \ | ||
3519 | 215 | mbm/mm-broadband-bearer-mbm.h \ | ||
3520 | 216 | mbm/mm-modem-helpers-mbm.c \ | ||
3521 | 217 | mbm/mm-modem-helpers-mbm.h \ | ||
3522 | 218 | mbm/mm-sim-mbm.c \ | ||
3523 | 219 | mbm/mm-sim-mbm.h | ||
3524 | 220 | libmm_plugin_mbm_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3525 | 221 | libmm_plugin_mbm_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3526 | 222 | udevrules_DATA += mbm/77-mm-ericsson-mbm.rules | ||
3527 | 223 | |||
3528 | 224 | noinst_PROGRAMS += test-modem-helpers-mbm | ||
3529 | 225 | test_modem_helpers_mbm_SOURCES = \ | ||
3530 | 226 | mbm/mm-modem-helpers-mbm.c \ | ||
3531 | 227 | mbm/mm-modem-helpers-mbm.h \ | ||
3532 | 228 | mbm/tests/test-modem-helpers-mbm.c | ||
3533 | 229 | test_modem_helpers_mbm_CPPFLAGS = \ | ||
3534 | 230 | -I$(top_srcdir)/plugins/mbm \ | ||
3535 | 231 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3536 | 232 | test_modem_helpers_mbm_LDADD = \ | ||
3537 | 233 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
3538 | 234 | $(top_builddir)/src/libmodem-helpers.la | ||
3539 | 235 | test_modem_helpers_mbm_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3540 | 236 | |||
3541 | 237 | # Option | ||
3542 | 238 | libmm_plugin_option_la_SOURCES = \ | ||
3543 | 239 | option/mm-plugin-option.c \ | ||
3544 | 240 | option/mm-plugin-option.h \ | ||
3545 | 241 | option/mm-broadband-modem-option.c \ | ||
3546 | 242 | option/mm-broadband-modem-option.h | ||
3547 | 243 | libmm_plugin_option_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3548 | 244 | libmm_plugin_option_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3549 | 245 | |||
3550 | 246 | # HSO | ||
3551 | 247 | libmm_plugin_hso_la_SOURCES = \ | ||
3552 | 248 | option/mm-plugin-hso.c \ | ||
3553 | 249 | option/mm-plugin-hso.h \ | ||
3554 | 250 | option/mm-broadband-modem-option.c \ | ||
3555 | 251 | option/mm-broadband-modem-option.h \ | ||
3556 | 252 | option/mm-broadband-bearer-hso.c \ | ||
3557 | 253 | option/mm-broadband-bearer-hso.h \ | ||
3558 | 254 | option/mm-broadband-modem-hso.c \ | ||
3559 | 255 | option/mm-broadband-modem-hso.h | ||
3560 | 256 | libmm_plugin_hso_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3561 | 257 | libmm_plugin_hso_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3562 | 258 | |||
3563 | 259 | # Sierra | ||
3564 | 260 | libmm_plugin_sierra_la_SOURCES = \ | ||
3565 | 261 | sierra/mm-plugin-sierra.c \ | ||
3566 | 262 | sierra/mm-plugin-sierra.h \ | ||
3567 | 263 | sierra/mm-common-sierra.c \ | ||
3568 | 264 | sierra/mm-common-sierra.h \ | ||
3569 | 265 | sierra/mm-sim-sierra.c \ | ||
3570 | 266 | sierra/mm-sim-sierra.h \ | ||
3571 | 267 | sierra/mm-broadband-bearer-sierra.c \ | ||
3572 | 268 | sierra/mm-broadband-bearer-sierra.h \ | ||
3573 | 269 | sierra/mm-broadband-modem-sierra.c \ | ||
3574 | 270 | sierra/mm-broadband-modem-sierra.h \ | ||
3575 | 271 | sierra/mm-broadband-modem-sierra-icera.c \ | ||
3576 | 272 | sierra/mm-broadband-modem-sierra-icera.h | ||
3577 | 273 | libmm_plugin_sierra_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
3578 | 274 | libmm_plugin_sierra_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3579 | 275 | libmm_plugin_sierra_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
3580 | 276 | |||
3581 | 277 | # Wavecom (Sierra Airlink) | ||
3582 | 278 | libmm_plugin_wavecom_la_SOURCES = \ | ||
3583 | 279 | wavecom/mm-plugin-wavecom.c \ | ||
3584 | 280 | wavecom/mm-plugin-wavecom.h \ | ||
3585 | 281 | wavecom/mm-broadband-modem-wavecom.c \ | ||
3586 | 282 | wavecom/mm-broadband-modem-wavecom.h | ||
3587 | 283 | libmm_plugin_wavecom_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3588 | 284 | libmm_plugin_wavecom_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3589 | 285 | |||
3590 | 286 | # Nokia | ||
3591 | 287 | libmm_plugin_nokia_la_SOURCES = \ | ||
3592 | 288 | nokia/mm-plugin-nokia.c \ | ||
3593 | 289 | nokia/mm-plugin-nokia.h \ | ||
3594 | 290 | nokia/mm-sim-nokia.c \ | ||
3595 | 291 | nokia/mm-sim-nokia.h \ | ||
3596 | 292 | nokia/mm-broadband-modem-nokia.c \ | ||
3597 | 293 | nokia/mm-broadband-modem-nokia.h | ||
3598 | 294 | libmm_plugin_nokia_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3599 | 295 | libmm_plugin_nokia_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3600 | 296 | |||
3601 | 297 | # Nokia (Icera) | ||
3602 | 298 | libmm_plugin_nokia_icera_la_SOURCES = \ | ||
3603 | 299 | nokia/mm-plugin-nokia-icera.c \ | ||
3604 | 300 | nokia/mm-plugin-nokia-icera.h | ||
3605 | 301 | libmm_plugin_nokia_icera_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
3606 | 302 | libmm_plugin_nokia_icera_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3607 | 303 | libmm_plugin_nokia_icera_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
3608 | 304 | udevrules_DATA += nokia/77-mm-nokia-port-types.rules | ||
3609 | 305 | |||
3610 | 306 | # Zte | ||
3611 | 307 | libmm_plugin_zte_la_SOURCES = \ | ||
3612 | 308 | zte/mm-plugin-zte.c \ | ||
3613 | 309 | zte/mm-plugin-zte.h \ | ||
3614 | 310 | zte/mm-common-zte.h \ | ||
3615 | 311 | zte/mm-common-zte.c \ | ||
3616 | 312 | zte/mm-broadband-modem-zte.h \ | ||
3617 | 313 | zte/mm-broadband-modem-zte.c \ | ||
3618 | 314 | zte/mm-broadband-modem-zte-icera.h \ | ||
3619 | 315 | zte/mm-broadband-modem-zte-icera.c | ||
3620 | 316 | libmm_plugin_zte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
3621 | 317 | libmm_plugin_zte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3622 | 318 | libmm_plugin_zte_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
3623 | 319 | udevrules_DATA += zte/77-mm-zte-port-types.rules | ||
3624 | 320 | |||
3625 | 321 | # Longcheer (and rebranded dongles) | ||
3626 | 322 | libmm_plugin_longcheer_la_SOURCES = \ | ||
3627 | 323 | longcheer/mm-plugin-longcheer.c \ | ||
3628 | 324 | longcheer/mm-plugin-longcheer.h \ | ||
3629 | 325 | longcheer/mm-broadband-modem-longcheer.h \ | ||
3630 | 326 | longcheer/mm-broadband-modem-longcheer.c | ||
3631 | 327 | libmm_plugin_longcheer_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3632 | 328 | libmm_plugin_longcheer_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3633 | 329 | udevrules_DATA += longcheer/77-mm-longcheer-port-types.rules | ||
3634 | 330 | |||
3635 | 331 | # AnyData CDMA | ||
3636 | 332 | libmm_plugin_anydata_la_SOURCES = \ | ||
3637 | 333 | anydata/mm-plugin-anydata.c \ | ||
3638 | 334 | anydata/mm-plugin-anydata.h \ | ||
3639 | 335 | anydata/mm-broadband-modem-anydata.h \ | ||
3640 | 336 | anydata/mm-broadband-modem-anydata.c | ||
3641 | 337 | libmm_plugin_anydata_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3642 | 338 | libmm_plugin_anydata_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3643 | 339 | |||
3644 | 340 | # Linktop CDMA | ||
3645 | 341 | libmm_plugin_linktop_la_SOURCES = \ | ||
3646 | 342 | linktop/mm-plugin-linktop.c \ | ||
3647 | 343 | linktop/mm-plugin-linktop.h \ | ||
3648 | 344 | linktop/mm-broadband-modem-linktop.h \ | ||
3649 | 345 | linktop/mm-broadband-modem-linktop.c | ||
3650 | 346 | libmm_plugin_linktop_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3651 | 347 | libmm_plugin_linktop_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3652 | 348 | |||
3653 | 349 | # SimTech | ||
3654 | 350 | libmm_plugin_simtech_la_SOURCES = \ | ||
3655 | 351 | simtech/mm-plugin-simtech.c \ | ||
3656 | 352 | simtech/mm-plugin-simtech.h \ | ||
3657 | 353 | simtech/mm-broadband-modem-simtech.h \ | ||
3658 | 354 | simtech/mm-broadband-modem-simtech.c | ||
3659 | 355 | libmm_plugin_simtech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3660 | 356 | libmm_plugin_simtech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3661 | 357 | udevrules_DATA += simtech/77-mm-simtech-port-types.rules | ||
3662 | 358 | |||
3663 | 359 | # Alcatel/TCT/JRD x220D and possibly others | ||
3664 | 360 | libmm_plugin_x22x_la_SOURCES = \ | ||
3665 | 361 | x22x/mm-plugin-x22x.c \ | ||
3666 | 362 | x22x/mm-plugin-x22x.h \ | ||
3667 | 363 | x22x/mm-broadband-modem-x22x.h \ | ||
3668 | 364 | x22x/mm-broadband-modem-x22x.c | ||
3669 | 365 | libmm_plugin_x22x_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3670 | 366 | libmm_plugin_x22x_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3671 | 367 | udevrules_DATA += x22x/77-mm-x22x-port-types.rules | ||
3672 | 368 | |||
3673 | 369 | # Pantech | ||
3674 | 370 | libmm_plugin_pantech_la_SOURCES = \ | ||
3675 | 371 | pantech/mm-plugin-pantech.c \ | ||
3676 | 372 | pantech/mm-plugin-pantech.h \ | ||
3677 | 373 | pantech/mm-sim-pantech.c \ | ||
3678 | 374 | pantech/mm-sim-pantech.h \ | ||
3679 | 375 | pantech/mm-broadband-modem-pantech.c \ | ||
3680 | 376 | pantech/mm-broadband-modem-pantech.h | ||
3681 | 377 | libmm_plugin_pantech_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3682 | 378 | libmm_plugin_pantech_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3683 | 379 | |||
3684 | 380 | # Samsung modem | ||
3685 | 381 | libmm_plugin_samsung_la_SOURCES = \ | ||
3686 | 382 | samsung/mm-plugin-samsung.c \ | ||
3687 | 383 | samsung/mm-plugin-samsung.h \ | ||
3688 | 384 | samsung/mm-broadband-modem-samsung.c \ | ||
3689 | 385 | samsung/mm-broadband-modem-samsung.h | ||
3690 | 386 | libmm_plugin_samsung_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(ICERA_COMMON_COMPILER_FLAGS) | ||
3691 | 387 | libmm_plugin_samsung_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3692 | 388 | libmm_plugin_samsung_la_LIBADD = $(ICERA_COMMON_LIBADD_FLAGS) | ||
3693 | 389 | |||
3694 | 390 | # Cinterion (previously Siemens) modem | ||
3695 | 391 | libmm_plugin_cinterion_la_SOURCES = \ | ||
3696 | 392 | cinterion/mm-plugin-cinterion.c \ | ||
3697 | 393 | cinterion/mm-plugin-cinterion.h \ | ||
3698 | 394 | cinterion/mm-modem-helpers-cinterion.c \ | ||
3699 | 395 | cinterion/mm-modem-helpers-cinterion.h \ | ||
3700 | 396 | cinterion/mm-common-cinterion.c \ | ||
3701 | 397 | cinterion/mm-common-cinterion.h \ | ||
3702 | 398 | cinterion/mm-broadband-modem-cinterion.c \ | ||
3703 | 399 | cinterion/mm-broadband-modem-cinterion.h | ||
3704 | 400 | |||
3705 | 401 | if WITH_QMI | ||
3706 | 402 | libmm_plugin_cinterion_la_SOURCES += \ | ||
3707 | 403 | cinterion/mm-broadband-modem-qmi-cinterion.c \ | ||
3708 | 404 | cinterion/mm-broadband-modem-qmi-cinterion.h | ||
3709 | 405 | endif | ||
3710 | 406 | |||
3711 | 407 | libmm_plugin_cinterion_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3712 | 408 | libmm_plugin_cinterion_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3713 | 409 | |||
3714 | 410 | udevrules_DATA += cinterion/77-mm-cinterion-port-types.rules | ||
3715 | 411 | |||
3716 | 412 | noinst_PROGRAMS += test-modem-helpers-cinterion | ||
3717 | 413 | test_modem_helpers_cinterion_SOURCES = \ | ||
3718 | 414 | cinterion/mm-modem-helpers-cinterion.c \ | ||
3719 | 415 | cinterion/mm-modem-helpers-cinterion.h \ | ||
3720 | 416 | cinterion/tests/test-modem-helpers-cinterion.c | ||
3721 | 417 | test_modem_helpers_cinterion_CPPFLAGS = \ | ||
3722 | 418 | -I$(top_srcdir)/plugins/cinterion \ | ||
3723 | 419 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3724 | 420 | test_modem_helpers_cinterion_LDADD = \ | ||
3725 | 421 | $(top_builddir)/libmm-glib/libmm-glib.la \ | ||
3726 | 422 | $(top_builddir)/src/libmodem-helpers.la | ||
3727 | 423 | test_modem_helpers_cinterion_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3728 | 424 | |||
3729 | 425 | # Iridium modem | ||
3730 | 426 | libmm_plugin_iridium_la_SOURCES = \ | ||
3731 | 427 | iridium/mm-plugin-iridium.c \ | ||
3732 | 428 | iridium/mm-plugin-iridium.h \ | ||
3733 | 429 | iridium/mm-broadband-modem-iridium.c \ | ||
3734 | 430 | iridium/mm-broadband-modem-iridium.h \ | ||
3735 | 431 | iridium/mm-bearer-iridium.c \ | ||
3736 | 432 | iridium/mm-bearer-iridium.h \ | ||
3737 | 433 | iridium/mm-sim-iridium.c \ | ||
3738 | 434 | iridium/mm-sim-iridium.h | ||
3739 | 435 | libmm_plugin_iridium_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3740 | 436 | libmm_plugin_iridium_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3741 | 437 | |||
3742 | 438 | # Common Novatel modem support library | ||
3743 | 439 | noinst_LTLIBRARIES += libmm-utils-novatel.la | ||
3744 | 440 | libmm_utils_novatel_la_SOURCES = \ | ||
3745 | 441 | novatel/mm-common-novatel.c \ | ||
3746 | 442 | novatel/mm-common-novatel.h \ | ||
3747 | 443 | novatel/mm-broadband-modem-novatel.c \ | ||
3748 | 444 | novatel/mm-broadband-modem-novatel.h | ||
3749 | 445 | libmm_utils_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3750 | 446 | libmm_utils_novatel_la_LIBADD = $(GUDEV_LIBS) $(MM_LIBS) | ||
3751 | 447 | |||
3752 | 448 | NOVATEL_COMMON_COMPILER_FLAGS = -I$(top_srcdir)/plugins/novatel | ||
3753 | 449 | NOVATEL_COMMON_LIBADD_FLAGS = $(builddir)/libmm-utils-novatel.la | ||
3754 | 450 | |||
3755 | 451 | # Novatel LTE modem | ||
3756 | 452 | libmm_plugin_novatel_lte_la_SOURCES = \ | ||
3757 | 453 | novatel/mm-plugin-novatel-lte.c \ | ||
3758 | 454 | novatel/mm-plugin-novatel-lte.h \ | ||
3759 | 455 | novatel/mm-broadband-modem-novatel-lte.c \ | ||
3760 | 456 | novatel/mm-broadband-modem-novatel-lte.h \ | ||
3761 | 457 | novatel/mm-broadband-bearer-novatel-lte.c \ | ||
3762 | 458 | novatel/mm-broadband-bearer-novatel-lte.h \ | ||
3763 | 459 | novatel/mm-sim-novatel-lte.c \ | ||
3764 | 460 | novatel/mm-sim-novatel-lte.h | ||
3765 | 461 | libmm_plugin_novatel_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3766 | 462 | libmm_plugin_novatel_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3767 | 463 | |||
3768 | 464 | # Novatel non-LTE modem | ||
3769 | 465 | libmm_plugin_novatel_la_SOURCES = \ | ||
3770 | 466 | novatel/mm-plugin-novatel.c \ | ||
3771 | 467 | novatel/mm-plugin-novatel.h | ||
3772 | 468 | libmm_plugin_novatel_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(NOVATEL_COMMON_COMPILER_FLAGS) | ||
3773 | 469 | libmm_plugin_novatel_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3774 | 470 | libmm_plugin_novatel_la_LIBADD = $(NOVATEL_COMMON_LIBADD_FLAGS) | ||
3775 | 471 | |||
3776 | 472 | # Altair LTE modem | ||
3777 | 473 | libmm_plugin_altair_lte_la_SOURCES = \ | ||
3778 | 474 | altair/mm-modem-helpers-altair-lte.c \ | ||
3779 | 475 | altair/mm-modem-helpers-altair-lte.h \ | ||
3780 | 476 | altair/mm-plugin-altair-lte.c \ | ||
3781 | 477 | altair/mm-plugin-altair-lte.h \ | ||
3782 | 478 | altair/mm-broadband-modem-altair-lte.c \ | ||
3783 | 479 | altair/mm-broadband-modem-altair-lte.h \ | ||
3784 | 480 | altair/mm-broadband-bearer-altair-lte.c \ | ||
3785 | 481 | altair/mm-broadband-bearer-altair-lte.h | ||
3786 | 482 | libmm_plugin_altair_lte_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3787 | 483 | libmm_plugin_altair_lte_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3788 | 484 | |||
3789 | 485 | noinst_PROGRAMS += test-modem-helpers-altair-lte | ||
3790 | 486 | test_modem_helpers_altair_lte_SOURCES = \ | ||
3791 | 487 | altair/mm-modem-helpers-altair-lte.c \ | ||
3792 | 488 | altair/mm-modem-helpers-altair-lte.h \ | ||
3793 | 489 | altair/tests/test-modem-helpers-altair-lte.c | ||
3794 | 490 | test_modem_helpers_altair_lte_CPPFLAGS = \ | ||
3795 | 491 | -I$(top_srcdir)/plugins/altair \ | ||
3796 | 492 | $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3797 | 493 | test_modem_helpers_altair_lte_LDADD = $(top_builddir)/libmm-glib/libmm-glib.la | ||
3798 | 494 | test_modem_helpers_altair_lte_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3799 | 495 | |||
3800 | 496 | |||
3801 | 497 | # VIA modem | ||
3802 | 498 | libmm_plugin_via_la_SOURCES = \ | ||
3803 | 499 | via/mm-plugin-via.c \ | ||
3804 | 500 | via/mm-plugin-via.h \ | ||
3805 | 501 | via/mm-broadband-modem-via.c \ | ||
3806 | 502 | via/mm-broadband-modem-via.h | ||
3807 | 503 | libmm_plugin_via_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3808 | 504 | libmm_plugin_via_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3809 | 505 | |||
3810 | 506 | # Telit modem | ||
3811 | 507 | libmm_plugin_telit_la_SOURCES = \ | ||
3812 | 508 | telit/mm-plugin-telit.c \ | ||
3813 | 509 | telit/mm-plugin-telit.h \ | ||
3814 | 510 | telit/mm-broadband-modem-telit.c \ | ||
3815 | 511 | telit/mm-broadband-modem-telit.h | ||
3816 | 512 | libmm_plugin_telit_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3817 | 513 | libmm_plugin_telit_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3818 | 514 | udevrules_DATA += telit/77-mm-telit-port-types.rules | ||
3819 | 515 | |||
3820 | 516 | # MTK | ||
3821 | 517 | libmm_plugin_mtk_la_SOURCES = \ | ||
3822 | 518 | mtk/mm-plugin-mtk.c \ | ||
3823 | 519 | mtk/mm-plugin-mtk.h \ | ||
3824 | 520 | mtk/mm-broadband-modem-mtk.h \ | ||
3825 | 521 | mtk/mm-broadband-modem-mtk.c | ||
3826 | 522 | libmm_plugin_mtk_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) | ||
3827 | 523 | libmm_plugin_mtk_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
3828 | 524 | udevrules_DATA += mtk/77-mm-mtk-port-types.rules | ||
3829 | 525 | |||
3830 | 526 | |||
3831 | 527 | # Additional files to include in the distribution | ||
3832 | 528 | EXTRA_DIST += \ | ||
3833 | 529 | $(udevrules_DATA) \ | ||
3834 | 530 | tests/gsm-port.conf | ||
3835 | 531 | |||
3836 | 532 | # Unit tests | ||
3837 | 533 | TEST_PROGS += $(noinst_PROGRAMS) | ||
3838 | 0 | 534 | ||
3839 | === added directory '.pc/sierra-custom-init.patch' | |||
3840 | === added directory '.pc/sierra-custom-init.patch/plugins' | |||
3841 | === added directory '.pc/sierra-custom-init.patch/plugins/sierra' | |||
3842 | === added file '.pc/sierra-custom-init.patch/plugins/sierra/mm-common-sierra.c' | |||
3843 | --- .pc/sierra-custom-init.patch/plugins/sierra/mm-common-sierra.c 1970-01-01 00:00:00 +0000 | |||
3844 | +++ .pc/sierra-custom-init.patch/plugins/sierra/mm-common-sierra.c 2015-10-09 10:06:57 +0000 | |||
3845 | @@ -0,0 +1,308 @@ | |||
3846 | 1 | /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ | ||
3847 | 2 | /* | ||
3848 | 3 | * This program is free software; you can redistribute it and/or modify | ||
3849 | 4 | * it under the terms of the GNU General Public License as published by | ||
3850 | 5 | * the Free Software Foundation; either version 2 of the License, or | ||
3851 | 6 | * (at your option) any later version. | ||
3852 | 7 | * | ||
3853 | 8 | * This program is distributed in the hope that it will be useful, | ||
3854 | 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
3855 | 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
3856 | 11 | * GNU General Public License for more details: | ||
3857 | 12 | * | ||
3858 | 13 | * Copyright (C) 2008 - 2009 Novell, Inc. | ||
3859 | 14 | * Copyright (C) 2009 - 2012 Red Hat, Inc. | ||
3860 | 15 | * Copyright (C) 2012 Lanedo GmbH | ||
3861 | 16 | */ | ||
3862 | 17 | |||
3863 | 18 | #include "mm-common-sierra.h" | ||
3864 | 19 | #include "mm-base-modem-at.h" | ||
3865 | 20 | #include "mm-log.h" | ||
3866 | 21 | #include "mm-modem-helpers.h" | ||
3867 | 22 | #include "mm-sim-sierra.h" | ||
3868 | 23 | |||
3869 | 24 | static MMIfaceModem *iface_modem_parent; | ||
3870 | 25 | |||
3871 | 26 | /*****************************************************************************/ | ||
3872 | 27 | /* Modem power up (Modem interface) */ | ||
3873 | 28 | |||
3874 | 29 | gboolean | ||
3875 | 30 | mm_common_sierra_modem_power_up_finish (MMIfaceModem *self, | ||
3876 | 31 | GAsyncResult *res, | ||
3877 | 32 | GError **error) | ||
3878 | 33 | { | ||
3879 | 34 | return !g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (res), error); | ||
3880 | 35 | } | ||
3881 | 36 | |||
3882 | 37 | static gboolean | ||
3883 | 38 | sierra_power_up_wait_cb (GSimpleAsyncResult *result) | ||
3884 | 39 | { | ||
3885 | 40 | g_simple_async_result_set_op_res_gboolean (result, TRUE); | ||
3886 | 41 | g_simple_async_result_complete (result); | ||
3887 | 42 | g_object_unref (result); | ||
3888 | 43 | return FALSE; | ||
3889 | 44 | } | ||
3890 | 45 | |||
3891 | 46 | static void | ||
3892 | 47 | cfun_enable_ready (MMBaseModem *self, | ||
3893 | 48 | GAsyncResult *res, | ||
3894 | 49 | GSimpleAsyncResult *simple) | ||
3895 | 50 | { | ||
3896 | 51 | GError *error = NULL; | ||
3897 | 52 | guint i; | ||
3898 | 53 | const gchar **drivers; | ||
3899 | 54 | gboolean is_new_sierra = FALSE; | ||
3900 | 55 | |||
3901 | 56 | if (!mm_base_modem_at_command_finish (MM_BASE_MODEM (self), res, &error)) { | ||
3902 | 57 | g_simple_async_result_take_error (simple, error); | ||
3903 | 58 | g_simple_async_result_complete (simple); | ||
3904 | 59 | g_object_unref (simple); | ||
3905 | 60 | return; | ||
3906 | 61 | } | ||
3907 | 62 | |||
3908 | 63 | /* Many Sierra devices return OK immediately in response to CFUN=1 but | ||
3909 | 64 | * need some time to finish powering up, otherwise subsequent commands | ||
3910 | 65 | * may return failure or even crash the modem. Give more time for older | ||
3911 | 66 | * devices like the AC860 and C885, which aren't driven by the 'sierra_net' | ||
3912 | 67 | * driver. Assume any DirectIP (ie, sierra_net) device is new enough | ||
3913 | 68 | * to allow a lower timeout. | ||
3914 | 69 | */ | ||
3915 | 70 | drivers = mm_base_modem_get_drivers (MM_BASE_MODEM (self)); | ||
3916 | 71 | for (i = 0; drivers[i]; i++) { | ||
3917 | 72 | if (g_str_equal (drivers[i], "sierra_net")) { | ||
3918 | 73 | is_new_sierra = TRUE; | ||
3919 | 74 | break; | ||
3920 | 75 | } | ||
3921 | 76 | } | ||
3922 | 77 | |||
3923 | 78 | /* The modem object will be valid in the callback as 'result' keeps a | ||
3924 | 79 | * reference to it. */ | ||
3925 | 80 | g_timeout_add_seconds (is_new_sierra ? 5 : 10, (GSourceFunc)sierra_power_up_wait_cb, simple); | ||
3926 | 81 | } | ||
3927 | 82 | |||
3928 | 83 | static void | ||
3929 | 84 | pcstate_enable_ready (MMBaseModem *self, | ||
3930 | 85 | GAsyncResult *res, | ||
3931 | 86 | GSimpleAsyncResult *simple) | ||
3932 | 87 | { | ||
3933 | 88 | /* Ignore errors for now; we're not sure if all Sierra CDMA devices support | ||
3934 | 89 | * at!pcstate. | ||
3935 | 90 | */ | ||
3936 | 91 | mm_base_modem_at_command_finish (MM_BASE_MODEM (self), res, NULL); | ||
3937 | 92 | |||
3938 | 93 | g_simple_async_result_set_op_res_gboolean (simple, TRUE); | ||
3939 | 94 | g_simple_async_result_complete (simple); | ||
3940 | 95 | g_object_unref (simple); | ||
3941 | 96 | } | ||
3942 | 97 | |||
3943 | 98 | void | ||
3944 | 99 | mm_common_sierra_modem_power_up (MMIfaceModem *self, | ||
3945 | 100 | GAsyncReadyCallback callback, | ||
3946 | 101 | gpointer user_data) | ||
3947 | 102 | { | ||
3948 | 103 | GSimpleAsyncResult *result; | ||
3949 | 104 | |||
3950 | 105 | result = g_simple_async_result_new (G_OBJECT (self), | ||
3951 | 106 | callback, | ||
3952 | 107 | user_data, | ||
3953 | 108 | mm_common_sierra_modem_power_up); | ||
3954 | 109 | |||
3955 | 110 | /* For CDMA modems, run !pcstate */ | ||
3956 | 111 | if (mm_iface_modem_is_cdma_only (self)) { | ||
3957 | 112 | mm_base_modem_at_command (MM_BASE_MODEM (self), | ||
3958 | 113 | "!pcstate=1", | ||
3959 | 114 | 5, | ||
3960 | 115 | FALSE, | ||
3961 | 116 | (GAsyncReadyCallback)pcstate_enable_ready, | ||
3962 | 117 | result); | ||
3963 | 118 | return; | ||
3964 | 119 | } | ||
3965 | 120 | |||
3966 | 121 | mm_warn ("Not in full functionality status, power-up command is needed. " | ||
3967 | 122 | "Note that it may reboot the modem."); | ||
3968 | 123 | |||
3969 | 124 | /* Try to go to full functionality mode without rebooting the system. | ||
3970 | 125 | * Works well if we previously switched off the power with CFUN=4 | ||
3971 | 126 | */ | ||
3972 | 127 | mm_base_modem_at_command (MM_BASE_MODEM (self), | ||
3973 | 128 | "+CFUN=1,0", /* ",0" requests no reset */ | ||
3974 | 129 | 10, | ||
3975 | 130 | FALSE, | ||
3976 | 131 | (GAsyncReadyCallback)cfun_enable_ready, | ||
3977 | 132 | result); | ||
3978 | 133 | } | ||
3979 | 134 | |||
3980 | 135 | /*****************************************************************************/ | ||
3981 | 136 | /* Power state loading (Modem interface) */ | ||
3982 | 137 | |||
3983 | 138 | MMModemPowerState | ||
3984 | 139 | mm_common_sierra_load_power_state_finish (MMIfaceModem *self, | ||
3985 | 140 | GAsyncResult *res, | ||
3986 | 141 | GError **error) | ||
3987 | 142 | { | ||
3988 | 143 | if (g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (res), error)) | ||
3989 | 144 | return MM_MODEM_POWER_STATE_UNKNOWN; | ||
3990 | 145 | |||
3991 | 146 | return (MMModemPowerState)GPOINTER_TO_UINT (g_simple_async_result_get_op_res_gpointer (G_SIMPLE_ASYNC_RESULT (res))); | ||
3992 | 147 | } | ||
3993 | 148 | |||
3994 | 149 | static void | ||
3995 | 150 | parent_load_power_state_ready (MMIfaceModem *self, | ||
3996 | 151 | GAsyncResult *res, | ||
3997 | 152 | GSimpleAsyncResult *simple) | ||
3998 | 153 | { | ||
3999 | 154 | GError *error = NULL; | ||
4000 | 155 | MMModemPowerState state; | ||
4001 | 156 | |||
4002 | 157 | state = iface_modem_parent->load_power_state_finish (self, res, &error); | ||
4003 | 158 | if (error) | ||
4004 | 159 | g_simple_async_result_take_error (simple, error); | ||
4005 | 160 | else | ||
4006 | 161 | g_simple_async_result_set_op_res_gpointer (simple, GUINT_TO_POINTER (state), NULL); | ||
4007 | 162 | g_simple_async_result_complete (simple); | ||
4008 | 163 | g_object_unref (simple); | ||
4009 | 164 | } | ||
4010 | 165 | |||
4011 | 166 | static void | ||
4012 | 167 | pcstate_query_ready (MMBaseModem *self, | ||
4013 | 168 | GAsyncResult *res, | ||
4014 | 169 | GSimpleAsyncResult *simple) | ||
4015 | 170 | { | ||
4016 | 171 | const gchar *result; | ||
4017 | 172 | guint state; | ||
4018 | 173 | GError *error = NULL; | ||
4019 | 174 | |||
4020 | 175 | result = mm_base_modem_at_command_finish (MM_BASE_MODEM (self), res, &error); | ||
4021 | 176 | if (!result) { | ||
4022 | 177 | g_simple_async_result_take_error (simple, error); | ||
4023 | 178 | g_simple_async_result_complete (simple); | ||
4024 | 179 | g_object_unref (simple); | ||
4025 | 180 | return; | ||
4026 | 181 | } | ||
4027 | 182 | |||
4028 | 183 | /* Parse power state reply */ | ||
4029 | 184 | result = mm_strip_tag (result, "!PCSTATE:"); | ||
4030 | 185 | if (!mm_get_uint_from_str (result, &state)) { | ||
4031 | 186 | g_simple_async_result_set_error (simple, | ||
4032 | 187 | MM_CORE_ERROR, | ||
4033 | 188 | MM_CORE_ERROR_FAILED, | ||
4034 | 189 | "Failed to parse !PCSTATE response '%s'", | ||
4035 | 190 | result); | ||
4036 | 191 | } else { | ||
4037 | 192 | switch (state) { | ||
4038 | 193 | case 0: | ||
4039 | 194 | g_simple_async_result_set_op_res_gpointer (simple, GUINT_TO_POINTER (MM_MODEM_POWER_STATE_LOW), NULL); | ||
4040 | 195 | break; | ||
4041 | 196 | case 1: | ||
4042 | 197 | g_simple_async_result_set_op_res_gpointer (simple, GUINT_TO_POINTER (MM_MODEM_POWER_STATE_ON), NULL); | ||
4043 | 198 | break; | ||
4044 | 199 | default: | ||
4045 | 200 | g_simple_async_result_set_error (simple, | ||
4046 | 201 | MM_CORE_ERROR, | ||
4047 | 202 | MM_CORE_ERROR_FAILED, | ||
4048 | 203 | "Unhandled power state: '%u'", | ||
4049 | 204 | state); | ||
4050 | 205 | break; | ||
4051 | 206 | } | ||
4052 | 207 | } | ||
4053 | 208 | |||
4054 | 209 | g_simple_async_result_complete (simple); | ||
4055 | 210 | g_object_unref (simple); | ||
4056 | 211 | } | ||
4057 | 212 | |||
4058 | 213 | void | ||
4059 | 214 | mm_common_sierra_load_power_state (MMIfaceModem *self, | ||
4060 | 215 | GAsyncReadyCallback callback, | ||
4061 | 216 | gpointer user_data) | ||
4062 | 217 | { | ||
4063 | 218 | GSimpleAsyncResult *result; | ||
4064 | 219 | |||
4065 | 220 | result = g_simple_async_result_new (G_OBJECT (self), | ||
4066 | 221 | callback, | ||
4067 | 222 | user_data, | ||
4068 | 223 | mm_common_sierra_load_power_state); | ||
4069 | 224 | |||
4070 | 225 | /* Check power state with AT!PCSTATE? */ | ||
4071 | 226 | if (mm_iface_modem_is_cdma_only (self)) { | ||
4072 | 227 | mm_base_modem_at_command (MM_BASE_MODEM (self), | ||
4073 | 228 | "!pcstate?", | ||
4074 | 229 | 3, | ||
4075 | 230 | FALSE, | ||
4076 | 231 | (GAsyncReadyCallback)pcstate_query_ready, | ||
4077 | 232 | result); | ||
4078 | 233 | return; | ||
4079 | 234 | } | ||
4080 | 235 | |||
4081 | 236 | /* Otherwise run parent's */ | ||
4082 | 237 | iface_modem_parent->load_power_state (self, | ||
4083 | 238 | (GAsyncReadyCallback)parent_load_power_state_ready, | ||
4084 | 239 | result); | ||
4085 | 240 | } | ||
4086 | 241 | |||
4087 | 242 | /*****************************************************************************/ | ||
4088 | 243 | /* Create SIM (Modem interface) */ | ||
4089 | 244 | |||
4090 | 245 | MMBaseSim * | ||
4091 | 246 | mm_common_sierra_create_sim_finish (MMIfaceModem *self, | ||
4092 | 247 | GAsyncResult *res, | ||
4093 | 248 | GError **error) | ||
4094 | 249 | { | ||
4095 | 250 | return mm_sim_sierra_new_finish (res, error); | ||
4096 | 251 | } | ||
4097 | 252 | |||
4098 | 253 | void | ||
4099 | 254 | mm_common_sierra_create_sim (MMIfaceModem *self, | ||
4100 | 255 | GAsyncReadyCallback callback, | ||
4101 | 256 | gpointer user_data) | ||
4102 | 257 | { | ||
4103 | 258 | /* New Sierra SIM */ | ||
4104 | 259 | mm_sim_sierra_new (MM_BASE_MODEM (self), | ||
4105 | 260 | NULL, /* cancellable */ | ||
4106 | 261 | callback, | ||
4107 | 262 | user_data); | ||
4108 | 263 | } | ||
4109 | 264 | |||
4110 | 265 | /*****************************************************************************/ | ||
4111 | 266 | /* Setup ports */ | ||
4112 | 267 | |||
4113 | 268 | void | ||
4114 | 269 | mm_common_sierra_setup_ports (MMBroadbandModem *self) | ||
4115 | 270 | { | ||
4116 | 271 | MMPortSerialAt *ports[2]; | ||
4117 | 272 | guint i; | ||
4118 | 273 | GRegex *pacsp_regex; | ||
4119 | 274 | |||
4120 | 275 | pacsp_regex = g_regex_new ("\\r\\n\\+PACSP.*\\r\\n", G_REGEX_RAW | G_REGEX_OPTIMIZE, 0, NULL); | ||
4121 | 276 | |||
4122 | 277 | ports[0] = mm_base_modem_peek_port_primary (MM_BASE_MODEM (self)); | ||
4123 | 278 | ports[1] = mm_base_modem_peek_port_secondary (MM_BASE_MODEM (self)); | ||
4124 | 279 | |||
4125 | 280 | for (i = 0; i < 2; i++) { | ||
4126 | 281 | if (!ports[i]) | ||
4127 | 282 | continue; | ||
4128 | 283 | |||
4129 | 284 | if (i == 1) { | ||
4130 | 285 | /* Built-in echo removal conflicts with the APP1 port's limited AT | ||
4131 | 286 | * parser, which doesn't always prefix responses with <CR><LF>. | ||
4132 | 287 | */ | ||
4133 | 288 | g_object_set (ports[i], | ||
4134 | 289 | MM_PORT_SERIAL_AT_REMOVE_ECHO, FALSE, | ||
4135 | 290 | NULL); | ||
4136 | 291 | } | ||
4137 | 292 | |||
4138 | 293 | mm_port_serial_at_add_unsolicited_msg_handler ( | ||
4139 | 294 | ports[i], | ||
4140 | 295 | pacsp_regex, | ||
4141 | 296 | NULL, NULL, NULL); | ||
4142 | 297 | } | ||
4143 | 298 | |||
4144 | 299 | g_regex_unref (pacsp_regex); | ||
4145 | 300 | } | ||
4146 | 301 | |||
4147 | 302 | /*****************************************************************************/ | ||
4148 | 303 | |||
4149 | 304 | void | ||
4150 | 305 | mm_common_sierra_peek_parent_interfaces (MMIfaceModem *iface) | ||
4151 | 306 | { | ||
4152 | 307 | iface_modem_parent = g_type_interface_peek_parent (iface); | ||
4153 | 308 | } | ||
4154 | 0 | 309 | ||
4155 | === added file '.pc/sierra-custom-init.patch/plugins/sierra/mm-common-sierra.h' | |||
4156 | --- .pc/sierra-custom-init.patch/plugins/sierra/mm-common-sierra.h 1970-01-01 00:00:00 +0000 | |||
4157 | +++ .pc/sierra-custom-init.patch/plugins/sierra/mm-common-sierra.h 2015-10-09 10:06:57 +0000 | |||
4158 | @@ -0,0 +1,50 @@ | |||
4159 | 1 | /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ | ||
4160 | 2 | /* | ||
4161 | 3 | * This program is free software; you can redistribute it and/or modify | ||
4162 | 4 | * it under the terms of the GNU General Public License as published by | ||
4163 | 5 | * the Free Software Foundation; either version 2 of the License, or | ||
4164 | 6 | * (at your option) any later version. | ||
4165 | 7 | * | ||
4166 | 8 | * This program is distributed in the hope that it will be useful, | ||
4167 | 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
4168 | 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
4169 | 11 | * GNU General Public License for more details: | ||
4170 | 12 | * | ||
4171 | 13 | * Copyright (C) 2008 - 2009 Novell, Inc. | ||
4172 | 14 | * Copyright (C) 2009 - 2012 Red Hat, Inc. | ||
4173 | 15 | * Copyright (C) 2012 Lanedo GmbH | ||
4174 | 16 | */ | ||
4175 | 17 | |||
4176 | 18 | #ifndef MM_COMMON_SIERRA_H | ||
4177 | 19 | #define MM_COMMON_SIERRA_H | ||
4178 | 20 | |||
4179 | 21 | #include "mm-broadband-modem.h" | ||
4180 | 22 | #include "mm-iface-modem.h" | ||
4181 | 23 | #include "mm-base-sim.h" | ||
4182 | 24 | |||
4183 | 25 | void mm_common_sierra_load_power_state (MMIfaceModem *self, | ||
4184 | 26 | GAsyncReadyCallback callback, | ||
4185 | 27 | gpointer user_data); | ||
4186 | 28 | MMModemPowerState mm_common_sierra_load_power_state_finish (MMIfaceModem *self, | ||
4187 | 29 | GAsyncResult *res, | ||
4188 | 30 | GError **error); | ||
4189 | 31 | |||
4190 | 32 | void mm_common_sierra_modem_power_up (MMIfaceModem *self, | ||
4191 | 33 | GAsyncReadyCallback callback, | ||
4192 | 34 | gpointer user_data); | ||
4193 | 35 | gboolean mm_common_sierra_modem_power_up_finish (MMIfaceModem *self, | ||
4194 | 36 | GAsyncResult *res, | ||
4195 | 37 | GError **error); | ||
4196 | 38 | |||
4197 | 39 | void mm_common_sierra_create_sim (MMIfaceModem *self, | ||
4198 | 40 | GAsyncReadyCallback callback, | ||
4199 | 41 | gpointer user_data); | ||
4200 | 42 | MMBaseSim *mm_common_sierra_create_sim_finish (MMIfaceModem *self, | ||
4201 | 43 | GAsyncResult *res, | ||
4202 | 44 | GError **error); | ||
4203 | 45 | |||
4204 | 46 | void mm_common_sierra_setup_ports (MMBroadbandModem *self); | ||
4205 | 47 | |||
4206 | 48 | void mm_common_sierra_peek_parent_interfaces (MMIfaceModem *iface); | ||
4207 | 49 | |||
4208 | 50 | #endif /* MM_COMMON_SIERRA_H */ | ||
4209 | 0 | 51 | ||
4210 | === added file '.pc/sierra-custom-init.patch/plugins/sierra/mm-plugin-sierra.c' | |||
4211 | --- .pc/sierra-custom-init.patch/plugins/sierra/mm-plugin-sierra.c 1970-01-01 00:00:00 +0000 | |||
4212 | +++ .pc/sierra-custom-init.patch/plugins/sierra/mm-plugin-sierra.c 2015-10-09 10:06:57 +0000 | |||
4213 | @@ -0,0 +1,343 @@ | |||
4214 | 1 | /* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ | ||
4215 | 2 | /* | ||
4216 | 3 | * This program is free software; you can redistribute it and/or modify | ||
4217 | 4 | * it under the terms of the GNU General Public License as published by | ||
4218 | 5 | * the Free Software Foundation; either version 2 of the License, or | ||
4219 | 6 | * (at your option) any later version. | ||
4220 | 7 | * | ||
4221 | 8 | * This program is distributed in the hope that it will be useful, | ||
4222 | 9 | * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
4223 | 10 | * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | ||
4224 | 11 | * GNU General Public License for more details: | ||
4225 | 12 | * | ||
4226 | 13 | * Copyright (C) 2008 - 2009 Novell, Inc. | ||
4227 | 14 | * Copyright (C) 2009 - 2012 Red Hat, Inc. | ||
4228 | 15 | * Copyright (C) 2012 Lanedo GmbH | ||
4229 | 16 | */ | ||
4230 | 17 | |||
4231 | 18 | #include <string.h> | ||
4232 | 19 | #include <stdlib.h> | ||
4233 | 20 | #include <gmodule.h> | ||
4234 | 21 | |||
4235 | 22 | #define _LIBMM_INSIDE_MM | ||
4236 | 23 | #include <libmm-glib.h> | ||
4237 | 24 | |||
4238 | 25 | #include "mm-log.h" | ||
4239 | 26 | #include "mm-plugin-sierra.h" | ||
4240 | 27 | #include "mm-broadband-modem-sierra.h" | ||
4241 | 28 | #include "mm-broadband-modem-sierra-icera.h" | ||
4242 | 29 | |||
4243 | 30 | #if defined WITH_QMI | ||
4244 | 31 | #include "mm-broadband-modem-qmi.h" | ||
4245 | 32 | #endif | ||
4246 | 33 | |||
4247 | 34 | #if defined WITH_MBIM | ||
4248 | 35 | #include "mm-broadband-modem-mbim.h" | ||
4249 | 36 | #endif | ||
4250 | 37 | |||
4251 | 38 | G_DEFINE_TYPE (MMPluginSierra, mm_plugin_sierra, MM_TYPE_PLUGIN) | ||
4252 | 39 | |||
4253 | 40 | int mm_plugin_major_version = MM_PLUGIN_MAJOR_VERSION; | ||
4254 | 41 | int mm_plugin_minor_version = MM_PLUGIN_MINOR_VERSION; | ||
4255 | 42 | |||
4256 | 43 | /*****************************************************************************/ | ||
4257 | 44 | /* Custom init */ | ||
4258 | 45 | |||
4259 | 46 | #define TAG_SIERRA_APP_PORT "sierra-app-port" | ||
4260 | 47 | #define TAG_SIERRA_APP1_PPP_OK "sierra-app1-ppp-ok" | ||
4261 | 48 | |||
4262 | 49 | typedef struct { | ||
4263 | 50 | MMPortProbe *probe; | ||
4264 | 51 | MMPortSerialAt *port; | ||
4265 | 52 | GCancellable *cancellable; | ||
4266 | 53 | GSimpleAsyncResult *result; | ||
4267 | 54 | guint retries; | ||
4268 | 55 | } SierraCustomInitContext; | ||
4269 | 56 | |||
4270 | 57 | static void | ||
4271 | 58 | sierra_custom_init_context_complete_and_free (SierraCustomInitContext *ctx) | ||
4272 | 59 | { | ||
4273 | 60 | g_simple_async_result_complete_in_idle (ctx->result); | ||
4274 | 61 | |||
4275 | 62 | if (ctx->cancellable) | ||
4276 | 63 | g_object_unref (ctx->cancellable); | ||
4277 | 64 | g_object_unref (ctx->port); | ||
4278 | 65 | g_object_unref (ctx->probe); | ||
4279 | 66 | g_object_unref (ctx->result); | ||
4280 | 67 | g_slice_free (SierraCustomInitContext, ctx); | ||
4281 | 68 | } | ||
4282 | 69 | |||
4283 | 70 | static gboolean | ||
4284 | 71 | sierra_custom_init_finish (MMPortProbe *probe, | ||
4285 | 72 | GAsyncResult *result, | ||
4286 | 73 | GError **error) | ||
4287 | 74 | { | ||
4288 | 75 | return !g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (result), error); | ||
4289 | 76 | } | ||
4290 | 77 | |||
4291 | 78 | static void sierra_custom_init_step (SierraCustomInitContext *ctx); | ||
4292 | 79 | |||
4293 | 80 | static void | ||
4294 | 81 | gcap_ready (MMPortSerialAt *port, | ||
4295 | 82 | GAsyncResult *res, | ||
4296 | 83 | SierraCustomInitContext *ctx) | ||
4297 | 84 | { | ||
4298 | 85 | const gchar *response; | ||
4299 | 86 | GError *error = NULL; | ||
4300 | 87 | |||
4301 | 88 | response = mm_port_serial_at_command_finish (port, res, &error); | ||
4302 | 89 | if (error) { | ||
4303 | 90 | /* If consumed all tries and the last error was a timeout, assume the | ||
4304 | 91 | * port is not AT */ | ||
4305 | 92 | if (ctx->retries == 0 && | ||
4306 | 93 | g_error_matches (error, MM_SERIAL_ERROR, MM_SERIAL_ERROR_RESPONSE_TIMEOUT)) { | ||
4307 | 94 | mm_port_probe_set_result_at (ctx->probe, FALSE); | ||
4308 | 95 | } | ||
4309 | 96 | /* If reported a hard parse error, this port is definitely not an AT | ||
4310 | 97 | * port, skip trying. */ | ||
4311 | 98 | else if (g_error_matches (error, MM_SERIAL_ERROR, MM_SERIAL_ERROR_PARSE_FAILED)) { | ||
4312 | 99 | mm_port_probe_set_result_at (ctx->probe, FALSE); | ||
4313 | 100 | ctx->retries = 0; | ||
4314 | 101 | } | ||
4315 | 102 | /* Some Icera-based devices (eg, USB305) have an AT-style port that | ||
4316 | 103 | * replies to everything with ERROR, so tag as unsupported; sometimes | ||
4317 | 104 | * the real AT ports do this too, so let a retry tag the port as | ||
4318 | 105 | * supported if it responds correctly later. */ | ||
4319 | 106 | else if (g_error_matches (error, MM_MOBILE_EQUIPMENT_ERROR, MM_MOBILE_EQUIPMENT_ERROR_UNKNOWN)) { | ||
4320 | 107 | mm_port_probe_set_result_at (ctx->probe, FALSE); | ||
4321 | 108 | } | ||
4322 | 109 | |||
4323 | 110 | /* Just retry... */ | ||
4324 | 111 | sierra_custom_init_step (ctx); | ||
4325 | 112 | goto out; | ||
4326 | 113 | } | ||
4327 | 114 | |||
4328 | 115 | /* A valid reply to ATI tells us this is an AT port already */ | ||
4329 | 116 | mm_port_probe_set_result_at (ctx->probe, TRUE); | ||
4330 | 117 | |||
4331 | 118 | /* Sierra APPx ports have limited AT command parsers that just reply with | ||
4332 | 119 | * "OK" to most commands. These can sometimes be used for PPP while the | ||
4333 | 120 | * main port is used for status and control, but older modems tend to crash | ||
4334 | 121 | * or fail PPP. So we whitelist modems that are known to allow PPP on the | ||
4335 | 122 | * secondary APP ports. | ||
4336 | 123 | */ | ||
4337 | 124 | if (strstr (response, "APP1")) { | ||
4338 | 125 | g_object_set_data (G_OBJECT (ctx->probe), TAG_SIERRA_APP_PORT, GUINT_TO_POINTER (TRUE)); | ||
4339 | 126 | |||
4340 | 127 | /* PPP-on-APP1-port whitelist */ | ||
4341 | 128 | if (strstr (response, "C885") || | ||
4342 | 129 | strstr (response, "USB 306") || | ||
4343 | 130 | strstr (response, "MC8790")) | ||
4344 | 131 | g_object_set_data (G_OBJECT (ctx->probe), TAG_SIERRA_APP1_PPP_OK, GUINT_TO_POINTER (TRUE)); | ||
4345 | 132 | |||
4346 | 133 | /* For debugging: let users figure out if their device supports PPP | ||
4347 | 134 | * on the APP1 port or not. | ||
4348 | 135 | */ | ||
4349 | 136 | if (getenv ("MM_SIERRA_APP1_PPP_OK")) { | ||
4350 | 137 | mm_dbg ("Sierra: APP1 PPP OK '%s'", response); | ||
4351 | 138 | g_object_set_data (G_OBJECT (ctx->probe), TAG_SIERRA_APP1_PPP_OK, GUINT_TO_POINTER (TRUE)); | ||
4352 | 139 | } | ||
4353 | 140 | } else if (strstr (response, "APP2") || | ||
4354 | 141 | strstr (response, "APP3") || | ||
4355 | 142 | strstr (response, "APP4")) { | ||
4356 | 143 | /* Additional APP ports don't support most AT commands, so they cannot | ||
4357 | 144 | * be used as the primary port. | ||
4358 | 145 | */ | ||
4359 | 146 | g_object_set_data (G_OBJECT (ctx->probe), TAG_SIERRA_APP_PORT, GUINT_TO_POINTER (TRUE)); | ||
4360 | 147 | } | ||
4361 | 148 | |||
4362 | 149 | g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4363 | 150 | sierra_custom_init_context_complete_and_free (ctx); | ||
4364 | 151 | |||
4365 | 152 | out: | ||
4366 | 153 | if (error) | ||
4367 | 154 | g_error_free (error); | ||
4368 | 155 | } | ||
4369 | 156 | |||
4370 | 157 | static void | ||
4371 | 158 | sierra_custom_init_step (SierraCustomInitContext *ctx) | ||
4372 | 159 | { | ||
4373 | 160 | /* If cancelled, end */ | ||
4374 | 161 | if (g_cancellable_is_cancelled (ctx->cancellable)) { | ||
4375 | 162 | mm_dbg ("(Sierra) no need to keep on running custom init in '%s'", | ||
4376 | 163 | mm_port_get_device (MM_PORT (ctx->port))); | ||
4377 | 164 | g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4378 | 165 | sierra_custom_init_context_complete_and_free (ctx); | ||
4379 | 166 | return; | ||
4380 | 167 | } | ||
4381 | 168 | |||
4382 | 169 | if (ctx->retries == 0) { | ||
4383 | 170 | mm_dbg ("(Sierra) Couldn't get port type hints from '%s'", | ||
4384 | 171 | mm_port_get_device (MM_PORT (ctx->port))); | ||
4385 | 172 | g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4386 | 173 | sierra_custom_init_context_complete_and_free (ctx); | ||
4387 | 174 | return; | ||
4388 | 175 | } | ||
4389 | 176 | |||
4390 | 177 | ctx->retries--; | ||
4391 | 178 | mm_port_serial_at_command ( | ||
4392 | 179 | ctx->port, | ||
4393 | 180 | "ATI", | ||
4394 | 181 | 3, | ||
4395 | 182 | FALSE, /* raw */ | ||
4396 | 183 | FALSE, /* allow_cached */ | ||
4397 | 184 | ctx->cancellable, | ||
4398 | 185 | (GAsyncReadyCallback)gcap_ready, | ||
4399 | 186 | ctx); | ||
4400 | 187 | } | ||
4401 | 188 | |||
4402 | 189 | static void | ||
4403 | 190 | sierra_custom_init (MMPortProbe *probe, | ||
4404 | 191 | MMPortSerialAt *port, | ||
4405 | 192 | GCancellable *cancellable, | ||
4406 | 193 | GAsyncReadyCallback callback, | ||
4407 | 194 | gpointer user_data) | ||
4408 | 195 | { | ||
4409 | 196 | SierraCustomInitContext *ctx; | ||
4410 | 197 | |||
4411 | 198 | ctx = g_slice_new (SierraCustomInitContext); | ||
4412 | 199 | ctx->result = g_simple_async_result_new (G_OBJECT (probe), | ||
4413 | 200 | callback, | ||
4414 | 201 | user_data, | ||
4415 | 202 | sierra_custom_init); | ||
4416 | 203 | ctx->probe = g_object_ref (probe); | ||
4417 | 204 | ctx->port = g_object_ref (port); | ||
4418 | 205 | ctx->cancellable = cancellable ? g_object_ref (cancellable) : NULL; | ||
4419 | 206 | ctx->retries = 3; | ||
4420 | 207 | |||
4421 | 208 | sierra_custom_init_step (ctx); | ||
4422 | 209 | } | ||
4423 | 210 | |||
4424 | 211 | /*****************************************************************************/ | ||
4425 | 212 | |||
4426 | 213 | static gboolean | ||
4427 | 214 | sierra_port_probe_list_is_icera (GList *probes) | ||
4428 | 215 | { | ||
4429 | 216 | GList *l; | ||
4430 | 217 | |||
4431 | 218 | for (l = probes; l; l = g_list_next (l)) { | ||
4432 | 219 | /* Only assume the Icera probing check is valid IF the port is not | ||
4433 | 220 | * secondary. This will skip the stupid ports which reply OK to every | ||
4434 | 221 | * AT command, even the one we use to check for Icera support */ | ||
4435 | 222 | if (mm_port_probe_is_icera (MM_PORT_PROBE (l->data)) && | ||
4436 | 223 | !g_object_get_data (G_OBJECT (l->data), TAG_SIERRA_APP_PORT)) | ||
4437 | 224 | return TRUE; | ||
4438 | 225 | } | ||
4439 | 226 | |||
4440 | 227 | return FALSE; | ||
4441 | 228 | } | ||
4442 | 229 | |||
4443 | 230 | static MMBaseModem * | ||
4444 | 231 | create_modem (MMPlugin *self, | ||
4445 | 232 | const gchar *sysfs_path, | ||
4446 | 233 | const gchar **drivers, | ||
4447 | 234 | guint16 vendor, | ||
4448 | 235 | guint16 product, | ||
4449 | 236 | GList *probes, | ||
4450 | 237 | GError **error) | ||
4451 | 238 | { | ||
4452 | 239 | #if defined WITH_QMI | ||
4453 | 240 | if (mm_port_probe_list_has_qmi_port (probes)) { | ||
4454 | 241 | mm_dbg ("QMI-powered Sierra modem found..."); | ||
4455 | 242 | return MM_BASE_MODEM (mm_broadband_modem_qmi_new (sysfs_path, | ||
4456 | 243 | drivers, | ||
4457 | 244 | mm_plugin_get_name (self), | ||
4458 | 245 | vendor, | ||
4459 | 246 | product)); | ||
4460 | 247 | } | ||
4461 | 248 | #endif | ||
4462 | 249 | |||
4463 | 250 | #if defined WITH_MBIM | ||
4464 | 251 | if (mm_port_probe_list_has_mbim_port (probes)) { | ||
4465 | 252 | mm_dbg ("MBIM-powered Sierra modem found..."); | ||
4466 | 253 | return MM_BASE_MODEM (mm_broadband_modem_mbim_new (sysfs_path, | ||
4467 | 254 | drivers, | ||
4468 | 255 | mm_plugin_get_name (self), | ||
4469 | 256 | vendor, | ||
4470 | 257 | product)); | ||
4471 | 258 | } | ||
4472 | 259 | #endif | ||
4473 | 260 | |||
4474 | 261 | if (sierra_port_probe_list_is_icera (probes)) | ||
4475 | 262 | return MM_BASE_MODEM (mm_broadband_modem_sierra_icera_new (sysfs_path, | ||
4476 | 263 | drivers, | ||
4477 | 264 | mm_plugin_get_name (self), | ||
4478 | 265 | vendor, | ||
4479 | 266 | product)); | ||
4480 | 267 | |||
4481 | 268 | return MM_BASE_MODEM (mm_broadband_modem_sierra_new (sysfs_path, | ||
4482 | 269 | drivers, | ||
4483 | 270 | mm_plugin_get_name (self), | ||
4484 | 271 | vendor, | ||
4485 | 272 | product)); | ||
4486 | 273 | } | ||
4487 | 274 | |||
4488 | 275 | static gboolean | ||
4489 | 276 | grab_port (MMPlugin *self, | ||
4490 | 277 | MMBaseModem *modem, | ||
4491 | 278 | MMPortProbe *probe, | ||
4492 | 279 | GError **error) | ||
4493 | 280 | { | ||
4494 | 281 | MMPortSerialAtFlag pflags = MM_PORT_SERIAL_AT_FLAG_NONE; | ||
4495 | 282 | MMPortType ptype; | ||
4496 | 283 | |||
4497 | 284 | ptype = mm_port_probe_get_port_type (probe); | ||
4498 | 285 | |||
4499 | 286 | /* Is it a GSM secondary port? */ | ||
4500 | 287 | if (g_object_get_data (G_OBJECT (probe), TAG_SIERRA_APP_PORT)) { | ||
4501 | 288 | if (g_object_get_data (G_OBJECT (probe), TAG_SIERRA_APP1_PPP_OK)) | ||
4502 | 289 | pflags = MM_PORT_SERIAL_AT_FLAG_PPP; | ||
4503 | 290 | else | ||
4504 | 291 | pflags = MM_PORT_SERIAL_AT_FLAG_SECONDARY; | ||
4505 | 292 | } else if (ptype == MM_PORT_TYPE_AT) | ||
4506 | 293 | pflags = MM_PORT_SERIAL_AT_FLAG_PRIMARY; | ||
4507 | 294 | |||
4508 | 295 | return mm_base_modem_grab_port (modem, | ||
4509 | 296 | mm_port_probe_get_port_subsys (probe), | ||
4510 | 297 | mm_port_probe_get_port_name (probe), | ||
4511 | 298 | mm_port_probe_get_parent_path (probe), | ||
4512 | 299 | ptype, | ||
4513 | 300 | pflags, | ||
4514 | 301 | error); | ||
4515 | 302 | } | ||
4516 | 303 | |||
4517 | 304 | /*****************************************************************************/ | ||
4518 | 305 | |||
4519 | 306 | G_MODULE_EXPORT MMPlugin * | ||
4520 | 307 | mm_plugin_create (void) | ||
4521 | 308 | { | ||
4522 | 309 | static const gchar *subsystems[] = { "tty", "net", "usb", NULL }; | ||
4523 | 310 | static const gchar *drivers[] = { "sierra", "sierra_net", NULL }; | ||
4524 | 311 | static const MMAsyncMethod custom_init = { | ||
4525 | 312 | .async = G_CALLBACK (sierra_custom_init), | ||
4526 | 313 | .finish = G_CALLBACK (sierra_custom_init_finish), | ||
4527 | 314 | }; | ||
4528 | 315 | |||
4529 | 316 | return MM_PLUGIN ( | ||
4530 | 317 | g_object_new (MM_TYPE_PLUGIN_SIERRA, | ||
4531 | 318 | MM_PLUGIN_NAME, "Sierra", | ||
4532 | 319 | MM_PLUGIN_ALLOWED_SUBSYSTEMS, subsystems, | ||
4533 | 320 | MM_PLUGIN_ALLOWED_DRIVERS, drivers, | ||
4534 | 321 | MM_PLUGIN_ALLOWED_AT, TRUE, | ||
4535 | 322 | MM_PLUGIN_ALLOWED_QCDM, TRUE, | ||
4536 | 323 | MM_PLUGIN_ALLOWED_QMI, TRUE, | ||
4537 | 324 | MM_PLUGIN_ALLOWED_MBIM, TRUE, | ||
4538 | 325 | MM_PLUGIN_CUSTOM_INIT, &custom_init, | ||
4539 | 326 | MM_PLUGIN_ICERA_PROBE, TRUE, | ||
4540 | 327 | MM_PLUGIN_REMOVE_ECHO, FALSE, | ||
4541 | 328 | NULL)); | ||
4542 | 329 | } | ||
4543 | 330 | |||
4544 | 331 | static void | ||
4545 | 332 | mm_plugin_sierra_init (MMPluginSierra *self) | ||
4546 | 333 | { | ||
4547 | 334 | } | ||
4548 | 335 | |||
4549 | 336 | static void | ||
4550 | 337 | mm_plugin_sierra_class_init (MMPluginSierraClass *klass) | ||
4551 | 338 | { | ||
4552 | 339 | MMPluginClass *plugin_class = MM_PLUGIN_CLASS (klass); | ||
4553 | 340 | |||
4554 | 341 | plugin_class->create_modem = create_modem; | ||
4555 | 342 | plugin_class->grab_port = grab_port; | ||
4556 | 343 | } | ||
4557 | 0 | 344 | ||
4558 | === modified file 'debian/changelog' | |||
4559 | --- debian/changelog 2014-09-17 08:46:25 +0000 | |||
4560 | +++ debian/changelog 2015-10-09 10:06:57 +0000 | |||
4561 | @@ -1,3 +1,10 @@ | |||
4562 | 1 | modemmanager (1.4.0-2) vivid-proposed; urgency=medium | ||
4563 | 2 | |||
4564 | 3 | * New hardware enablement: Support the new MBIM devices from Dell. | ||
4565 | 4 | (LP: #1441095) | ||
4566 | 5 | |||
4567 | 6 | -- Bin Li <bin.li@canonical.com> Fri, 09 Oct 2015 15:46:46 +0800 | ||
4568 | 7 | |||
4569 | 1 | modemmanager (1.4.0-1) unstable; urgency=medium | 8 | modemmanager (1.4.0-1) unstable; urgency=medium |
4570 | 2 | 9 | ||
4571 | 3 | * New upstream release. | 10 | * New upstream release. |
4572 | 4 | 11 | ||
4573 | === added file 'debian/patches/dell-mbim-plugin.patch' | |||
4574 | --- debian/patches/dell-mbim-plugin.patch 1970-01-01 00:00:00 +0000 | |||
4575 | +++ debian/patches/dell-mbim-plugin.patch 2015-10-09 10:06:57 +0000 | |||
4576 | @@ -0,0 +1,576 @@ | |||
4577 | 1 | commit 93d6e4f102da51e72ecd2fbfcfa096cd2fd2e02e | ||
4578 | 2 | Author: Aleksander Morgado <aleksander@aleksander.es> | ||
4579 | 3 | Date: Fri Feb 6 16:35:52 2015 +0100 | ||
4580 | 4 | |||
4581 | 5 | dell: new Dell plugin | ||
4582 | 6 | |||
4583 | 7 | For Dell-branded Novatel, Sierra and Ericsson modems. | ||
4584 | 8 | |||
4585 | 9 | The Novatel plugin will no longer accept every Dell-branded modem, which was | ||
4586 | 10 | the current situation. Instead, a new Dell plugin will take care of probing for | ||
4587 | 11 | the correct vendor string, and based on the results create a specific Novatel, | ||
4588 | 12 | Sierra or Ericsson modem. | ||
4589 | 13 | |||
4590 | 14 | In order to properly support this, the Novatel, Sierra and MBM plugins now | ||
4591 | 15 | export their implementations into non-inst libraries that the Dell plugin will | ||
4592 | 16 | import. | ||
4593 | 17 | |||
4594 | 18 | Also, for now, the Dell plugin doesn't make any difference between e.g. Sierra | ||
4595 | 19 | or Ericsson MBIM implementations, just a generic MBIM modem is created in both | ||
4596 | 20 | cases, as that is anyway what the Ericsson MBM and Sierra plugins do already. | ||
4597 | 21 | |||
4598 | 22 | https://bugs.freedesktop.org/show_bug.cgi?id=86713 | ||
4599 | 23 | |||
4600 | 24 | --- | ||
4601 | 25 | plugins/Makefile.am | 9 | ||
4602 | 26 | plugins/dell/mm-plugin-dell.c | 448 ++++++++++++++++++++++++++++++++++++ | ||
4603 | 27 | plugins/dell/mm-plugin-dell.h | 46 +++ | ||
4604 | 28 | plugins/novatel/mm-plugin-novatel.c | 4 | ||
4605 | 29 | 4 files changed, 504 insertions(+), 3 deletions(-) | ||
4606 | 30 | |||
4607 | 31 | Index: modemmanager/plugins/Makefile.am | ||
4608 | 32 | =================================================================== | ||
4609 | 33 | --- modemmanager.orig/plugins/Makefile.am | ||
4610 | 34 | +++ modemmanager/plugins/Makefile.am | ||
4611 | 35 | @@ -125,6 +125,7 @@ pkglib_LTLIBRARIES = \ | ||
4612 | 36 | libmm-plugin-motorola.la \ | ||
4613 | 37 | libmm-plugin-novatel.la \ | ||
4614 | 38 | libmm-plugin-novatel-lte.la \ | ||
4615 | 39 | + libmm-plugin-dell.la \ | ||
4616 | 40 | libmm-plugin-altair-lte.la \ | ||
4617 | 41 | libmm-plugin-samsung.la \ | ||
4618 | 42 | libmm-plugin-option.la \ | ||
4619 | 43 | @@ -497,6 +498,14 @@ libmm_plugin_novatel_la_CPPFLAGS = $(PLU | ||
4620 | 44 | libmm_plugin_novatel_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
4621 | 45 | libmm_plugin_novatel_la_LIBADD = $(NOVATEL_COMMON_LIBADD_FLAGS) | ||
4622 | 46 | |||
4623 | 47 | +# Dell (e.g. Novatel or Sierra) modem | ||
4624 | 48 | +libmm_plugin_dell_la_SOURCES = \ | ||
4625 | 49 | + dell/mm-plugin-dell.c \ | ||
4626 | 50 | + dell/mm-plugin-dell.h | ||
4627 | 51 | +libmm_plugin_dell_la_CPPFLAGS = $(PLUGIN_COMMON_COMPILER_FLAGS) $(NOVATEL_COMMON_COMPILER_FLAGS) $(SIERRA_COMMON_COMPILER_FLAGS) $(MBM_COMMON_COMPILER_FLAGS) | ||
4628 | 52 | +libmm_plugin_dell_la_LDFLAGS = $(PLUGIN_COMMON_LINKER_FLAGS) | ||
4629 | 53 | +libmm_plugin_dell_la_LIBADD = $(NOVATEL_COMMON_LIBADD_FLAGS) $(SIERRA_COMMON_LIBADD_FLAGS) $(MBM_COMMON_LIBADD_FLAGS) | ||
4630 | 54 | + | ||
4631 | 55 | # Altair LTE modem | ||
4632 | 56 | libmm_plugin_altair_lte_la_SOURCES = \ | ||
4633 | 57 | altair/mm-modem-helpers-altair-lte.c \ | ||
4634 | 58 | Index: modemmanager/plugins/dell/mm-plugin-dell.c | ||
4635 | 59 | =================================================================== | ||
4636 | 60 | --- /dev/null | ||
4637 | 61 | +++ modemmanager/plugins/dell/mm-plugin-dell.c | ||
4638 | 62 | @@ -0,0 +1,448 @@ | ||
4639 | 63 | +/* -*- Mode: C; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */ | ||
4640 | 64 | + | ||
4641 | 65 | +/* | ||
4642 | 66 | + * This program is free software; you can redistribute it and/or | ||
4643 | 67 | + * modify it under the terms of the GNU General Public License as | ||
4644 | 68 | + * published by the Free Software Foundation; either version 2 of the | ||
4645 | 69 | + * License, or (at your option) any later version. | ||
4646 | 70 | + * | ||
4647 | 71 | + * This program is distributed in the hope that it will be useful, | ||
4648 | 72 | + * but WITHOUT ANY WARRANTY; without even the implied warranty of | ||
4649 | 73 | + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
4650 | 74 | + * General Public License for more details. | ||
4651 | 75 | + * | ||
4652 | 76 | + * You should have received a copy of the GNU General Public | ||
4653 | 77 | + * License along with this program; if not, write to the | ||
4654 | 78 | + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, | ||
4655 | 79 | + * Boston, MA 02111-1307, USA. | ||
4656 | 80 | + * | ||
4657 | 81 | + * Copyright (C) 2015 Aleksander Morgado <aleksander@aleksander.es> | ||
4658 | 82 | + */ | ||
4659 | 83 | + | ||
4660 | 84 | +#include <string.h> | ||
4661 | 85 | +#include <gmodule.h> | ||
4662 | 86 | + | ||
4663 | 87 | +#define _LIBMM_INSIDE_MM | ||
4664 | 88 | +#include <libmm-glib.h> | ||
4665 | 89 | + | ||
4666 | 90 | +#include "mm-plugin-dell.h" | ||
4667 | 91 | +#include "mm-common-novatel.h" | ||
4668 | 92 | +#include "mm-private-boxed-types.h" | ||
4669 | 93 | +#include "mm-broadband-modem.h" | ||
4670 | 94 | +#include "mm-broadband-modem-novatel.h" | ||
4671 | 95 | +#include "mm-common-novatel.h" | ||
4672 | 96 | +#include "mm-broadband-modem-sierra.h" | ||
4673 | 97 | +#include "mm-common-sierra.h" | ||
4674 | 98 | +#include "mm-log.h" | ||
4675 | 99 | + | ||
4676 | 100 | +#if defined WITH_QMI | ||
4677 | 101 | +#include "mm-broadband-modem-qmi.h" | ||
4678 | 102 | +#endif | ||
4679 | 103 | + | ||
4680 | 104 | +#if defined WITH_MBIM | ||
4681 | 105 | +#include "mm-broadband-modem-mbim.h" | ||
4682 | 106 | +#endif | ||
4683 | 107 | + | ||
4684 | 108 | +G_DEFINE_TYPE (MMPluginDell, mm_plugin_dell, MM_TYPE_PLUGIN) | ||
4685 | 109 | + | ||
4686 | 110 | +int mm_plugin_major_version = MM_PLUGIN_MAJOR_VERSION; | ||
4687 | 111 | +int mm_plugin_minor_version = MM_PLUGIN_MINOR_VERSION; | ||
4688 | 112 | + | ||
4689 | 113 | +#define TAG_DELL_MANUFACTURER "dell-manufacturer" | ||
4690 | 114 | +typedef enum { | ||
4691 | 115 | + DELL_MANUFACTURER_UNKNOWN = 0, | ||
4692 | 116 | + DELL_MANUFACTURER_NOVATEL = 1, | ||
4693 | 117 | + DELL_MANUFACTURER_SIERRA = 2, | ||
4694 | 118 | + DELL_MANUFACTURER_ERICSSON = 3 | ||
4695 | 119 | +} DellManufacturer; | ||
4696 | 120 | + | ||
4697 | 121 | +/*****************************************************************************/ | ||
4698 | 122 | +/* Custom init */ | ||
4699 | 123 | + | ||
4700 | 124 | +typedef struct { | ||
4701 | 125 | + MMPortProbe *probe; | ||
4702 | 126 | + MMPortSerialAt *port; | ||
4703 | 127 | + GCancellable *cancellable; | ||
4704 | 128 | + GSimpleAsyncResult *result; | ||
4705 | 129 | + guint gmi_retries; | ||
4706 | 130 | + guint cgmi_retries; | ||
4707 | 131 | + guint ati_retries; | ||
4708 | 132 | +} CustomInitContext; | ||
4709 | 133 | + | ||
4710 | 134 | +static void | ||
4711 | 135 | +custom_init_context_complete_and_free (CustomInitContext *ctx) | ||
4712 | 136 | +{ | ||
4713 | 137 | + g_simple_async_result_complete_in_idle (ctx->result); | ||
4714 | 138 | + | ||
4715 | 139 | + if (ctx->cancellable) | ||
4716 | 140 | + g_object_unref (ctx->cancellable); | ||
4717 | 141 | + g_object_unref (ctx->port); | ||
4718 | 142 | + g_object_unref (ctx->probe); | ||
4719 | 143 | + g_object_unref (ctx->result); | ||
4720 | 144 | + g_slice_free (CustomInitContext, ctx); | ||
4721 | 145 | +} | ||
4722 | 146 | + | ||
4723 | 147 | +static gboolean | ||
4724 | 148 | +dell_custom_init_finish (MMPortProbe *probe, | ||
4725 | 149 | + GAsyncResult *result, | ||
4726 | 150 | + GError **error) | ||
4727 | 151 | +{ | ||
4728 | 152 | + return !g_simple_async_result_propagate_error (G_SIMPLE_ASYNC_RESULT (result), error); | ||
4729 | 153 | +} | ||
4730 | 154 | + | ||
4731 | 155 | +static void | ||
4732 | 156 | +novatel_custom_init_ready (MMPortProbe *probe, | ||
4733 | 157 | + GAsyncResult *res, | ||
4734 | 158 | + CustomInitContext *ctx) | ||
4735 | 159 | +{ | ||
4736 | 160 | + GError *error = NULL; | ||
4737 | 161 | + | ||
4738 | 162 | + if (!mm_common_novatel_custom_init_finish (probe, res, &error)) | ||
4739 | 163 | + g_simple_async_result_take_error (ctx->result, error); | ||
4740 | 164 | + else | ||
4741 | 165 | + g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4742 | 166 | + custom_init_context_complete_and_free (ctx); | ||
4743 | 167 | +} | ||
4744 | 168 | + | ||
4745 | 169 | +static void | ||
4746 | 170 | +sierra_custom_init_ready (MMPortProbe *probe, | ||
4747 | 171 | + GAsyncResult *res, | ||
4748 | 172 | + CustomInitContext *ctx) | ||
4749 | 173 | +{ | ||
4750 | 174 | + GError *error = NULL; | ||
4751 | 175 | + | ||
4752 | 176 | + if (!mm_common_sierra_custom_init_finish (probe, res, &error)) | ||
4753 | 177 | + g_simple_async_result_take_error (ctx->result, error); | ||
4754 | 178 | + else | ||
4755 | 179 | + g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4756 | 180 | + custom_init_context_complete_and_free (ctx); | ||
4757 | 181 | +} | ||
4758 | 182 | + | ||
4759 | 183 | +static void custom_init_step (CustomInitContext *ctx); | ||
4760 | 184 | + | ||
4761 | 185 | +static void | ||
4762 | 186 | +custom_init_step_next_command (CustomInitContext *ctx) | ||
4763 | 187 | +{ | ||
4764 | 188 | + if (ctx->gmi_retries > 0) | ||
4765 | 189 | + ctx->gmi_retries = 0; | ||
4766 | 190 | + else if (ctx->cgmi_retries > 0) | ||
4767 | 191 | + ctx->cgmi_retries = 0; | ||
4768 | 192 | + else if (ctx->ati_retries > 0) | ||
4769 | 193 | + ctx->ati_retries = 0; | ||
4770 | 194 | + custom_init_step (ctx); | ||
4771 | 195 | +} | ||
4772 | 196 | + | ||
4773 | 197 | +static void | ||
4774 | 198 | +response_ready (MMPortSerialAt *port, | ||
4775 | 199 | + GAsyncResult *res, | ||
4776 | 200 | + CustomInitContext *ctx) | ||
4777 | 201 | +{ | ||
4778 | 202 | + const gchar *response; | ||
4779 | 203 | + GError *error = NULL; | ||
4780 | 204 | + gchar *lower; | ||
4781 | 205 | + DellManufacturer manufacturer; | ||
4782 | 206 | + | ||
4783 | 207 | + response = mm_port_serial_at_command_finish (port, res, &error); | ||
4784 | 208 | + if (error) { | ||
4785 | 209 | + /* Non-timeout error, jump to next command */ | ||
4786 | 210 | + if (!g_error_matches (error, MM_SERIAL_ERROR, MM_SERIAL_ERROR_RESPONSE_TIMEOUT)) { | ||
4787 | 211 | + mm_dbg ("(Dell) Error probing AT port: %s", error->message); | ||
4788 | 212 | + g_error_free (error); | ||
4789 | 213 | + custom_init_step_next_command (ctx); | ||
4790 | 214 | + return; | ||
4791 | 215 | + } | ||
4792 | 216 | + /* Directly retry same command on timeout */ | ||
4793 | 217 | + custom_init_step (ctx); | ||
4794 | 218 | + g_error_free (error); | ||
4795 | 219 | + return; | ||
4796 | 220 | + } | ||
4797 | 221 | + | ||
4798 | 222 | + /* Guess manufacturer from response */ | ||
4799 | 223 | + lower = g_ascii_strdown (response, -1); | ||
4800 | 224 | + if (strstr (lower, "novatel")) | ||
4801 | 225 | + manufacturer = DELL_MANUFACTURER_NOVATEL; | ||
4802 | 226 | + else if (strstr (lower, "sierra")) | ||
4803 | 227 | + manufacturer = DELL_MANUFACTURER_SIERRA; | ||
4804 | 228 | + else if (strstr (lower, "ericsson")) | ||
4805 | 229 | + manufacturer = DELL_MANUFACTURER_ERICSSON; | ||
4806 | 230 | + else | ||
4807 | 231 | + manufacturer = DELL_MANUFACTURER_UNKNOWN; | ||
4808 | 232 | + g_free (lower); | ||
4809 | 233 | + | ||
4810 | 234 | + /* Tag based on manufacturer */ | ||
4811 | 235 | + if (manufacturer != DELL_MANUFACTURER_UNKNOWN) { | ||
4812 | 236 | + g_object_set_data (G_OBJECT (ctx->probe), TAG_DELL_MANUFACTURER, GUINT_TO_POINTER (manufacturer)); | ||
4813 | 237 | + | ||
4814 | 238 | + /* Run additional custom init, if needed */ | ||
4815 | 239 | + | ||
4816 | 240 | + if (manufacturer == DELL_MANUFACTURER_NOVATEL) { | ||
4817 | 241 | + mm_common_novatel_custom_init (ctx->probe, | ||
4818 | 242 | + ctx->port, | ||
4819 | 243 | + ctx->cancellable, | ||
4820 | 244 | + (GAsyncReadyCallback) novatel_custom_init_ready, | ||
4821 | 245 | + ctx); | ||
4822 | 246 | + return; | ||
4823 | 247 | + } | ||
4824 | 248 | + | ||
4825 | 249 | + if (manufacturer == DELL_MANUFACTURER_SIERRA) { | ||
4826 | 250 | + mm_common_sierra_custom_init (ctx->probe, | ||
4827 | 251 | + ctx->port, | ||
4828 | 252 | + ctx->cancellable, | ||
4829 | 253 | + (GAsyncReadyCallback) sierra_custom_init_ready, | ||
4830 | 254 | + ctx); | ||
4831 | 255 | + return; | ||
4832 | 256 | + } | ||
4833 | 257 | + | ||
4834 | 258 | + /* Finish custom_init */ | ||
4835 | 259 | + g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4836 | 260 | + custom_init_context_complete_and_free (ctx); | ||
4837 | 261 | + return; | ||
4838 | 262 | + } | ||
4839 | 263 | + | ||
4840 | 264 | + /* If we got a response, but we didn't get an expected string, try with next command */ | ||
4841 | 265 | + custom_init_step_next_command (ctx); | ||
4842 | 266 | +} | ||
4843 | 267 | + | ||
4844 | 268 | +static void | ||
4845 | 269 | +custom_init_step (CustomInitContext *ctx) | ||
4846 | 270 | +{ | ||
4847 | 271 | + /* If cancelled, end */ | ||
4848 | 272 | + if (g_cancellable_is_cancelled (ctx->cancellable)) { | ||
4849 | 273 | + mm_dbg ("(Dell) no need to keep on running custom init in (%s)", | ||
4850 | 274 | + mm_port_get_device (MM_PORT (ctx->port))); | ||
4851 | 275 | + g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4852 | 276 | + custom_init_context_complete_and_free (ctx); | ||
4853 | 277 | + return; | ||
4854 | 278 | + } | ||
4855 | 279 | + | ||
4856 | 280 | +#if defined WITH_QMI | ||
4857 | 281 | + /* If device has a QMI port, don't run anything else, as we don't care */ | ||
4858 | 282 | + if (mm_port_probe_list_has_qmi_port (mm_device_peek_port_probe_list (mm_port_probe_peek_device (ctx->probe)))) { | ||
4859 | 283 | + mm_dbg ("(Dell) no need to run custom init in (%s): device has QMI port", | ||
4860 | 284 | + mm_port_get_device (MM_PORT (ctx->port))); | ||
4861 | 285 | + mm_port_probe_set_result_at (ctx->probe, FALSE); | ||
4862 | 286 | + mm_port_probe_set_result_qcdm (ctx->probe, FALSE); | ||
4863 | 287 | + g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4864 | 288 | + custom_init_context_complete_and_free (ctx); | ||
4865 | 289 | + return; | ||
4866 | 290 | + } | ||
4867 | 291 | +#endif | ||
4868 | 292 | + | ||
4869 | 293 | +#if defined WITH_MBIM | ||
4870 | 294 | + /* If device has a MBIM port, don't run anything else, as we don't care */ | ||
4871 | 295 | + if (mm_port_probe_list_has_mbim_port (mm_device_peek_port_probe_list (mm_port_probe_peek_device (ctx->probe)))) { | ||
4872 | 296 | + mm_dbg ("(Dell) no need to run custom init in (%s): device has MBIM port", | ||
4873 | 297 | + mm_port_get_device (MM_PORT (ctx->port))); | ||
4874 | 298 | + mm_port_probe_set_result_at (ctx->probe, FALSE); | ||
4875 | 299 | + mm_port_probe_set_result_qcdm (ctx->probe, FALSE); | ||
4876 | 300 | + g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4877 | 301 | + custom_init_context_complete_and_free (ctx); | ||
4878 | 302 | + return; | ||
4879 | 303 | + } | ||
4880 | 304 | +#endif | ||
4881 | 305 | + | ||
4882 | 306 | + if (ctx->gmi_retries > 0) { | ||
4883 | 307 | + ctx->gmi_retries--; | ||
4884 | 308 | + mm_port_serial_at_command (ctx->port, | ||
4885 | 309 | + "AT+GMI", | ||
4886 | 310 | + 3, | ||
4887 | 311 | + FALSE, /* raw */ | ||
4888 | 312 | + FALSE, /* allow_cached */ | ||
4889 | 313 | + ctx->cancellable, | ||
4890 | 314 | + (GAsyncReadyCallback)response_ready, | ||
4891 | 315 | + ctx); | ||
4892 | 316 | + return; | ||
4893 | 317 | + } | ||
4894 | 318 | + | ||
4895 | 319 | + if (ctx->cgmi_retries > 0) { | ||
4896 | 320 | + ctx->cgmi_retries--; | ||
4897 | 321 | + mm_port_serial_at_command (ctx->port, | ||
4898 | 322 | + "AT+CGMI", | ||
4899 | 323 | + 3, | ||
4900 | 324 | + FALSE, /* raw */ | ||
4901 | 325 | + FALSE, /* allow_cached */ | ||
4902 | 326 | + ctx->cancellable, | ||
4903 | 327 | + (GAsyncReadyCallback)response_ready, | ||
4904 | 328 | + ctx); | ||
4905 | 329 | + return; | ||
4906 | 330 | + } | ||
4907 | 331 | + | ||
4908 | 332 | + if (ctx->ati_retries > 0) { | ||
4909 | 333 | + ctx->ati_retries--; | ||
4910 | 334 | + /* Note: in Ericsson devices, ATI3 seems to reply the vendor string */ | ||
4911 | 335 | + mm_port_serial_at_command (ctx->port, | ||
4912 | 336 | + "ATI1I2I3", | ||
4913 | 337 | + 3, | ||
4914 | 338 | + FALSE, /* raw */ | ||
4915 | 339 | + FALSE, /* allow_cached */ | ||
4916 | 340 | + ctx->cancellable, | ||
4917 | 341 | + (GAsyncReadyCallback)response_ready, | ||
4918 | 342 | + ctx); | ||
4919 | 343 | + return; | ||
4920 | 344 | + } | ||
4921 | 345 | + | ||
4922 | 346 | + /* Finish custom_init */ | ||
4923 | 347 | + mm_dbg ("(Dell) couldn't flip secondary port to AT in (%s): all retries consumed", | ||
4924 | 348 | + mm_port_get_device (MM_PORT (ctx->port))); | ||
4925 | 349 | + g_simple_async_result_set_op_res_gboolean (ctx->result, TRUE); | ||
4926 | 350 | + custom_init_context_complete_and_free (ctx); | ||
4927 | 351 | +} | ||
4928 | 352 | + | ||
4929 | 353 | +static void | ||
4930 | 354 | +dell_custom_init (MMPortProbe *probe, | ||
4931 | 355 | + MMPortSerialAt *port, | ||
4932 | 356 | + GCancellable *cancellable, | ||
4933 | 357 | + GAsyncReadyCallback callback, | ||
4934 | 358 | + gpointer user_data) | ||
4935 | 359 | +{ | ||
4936 | 360 | + CustomInitContext *ctx; | ||
4937 | 361 | + | ||
4938 | 362 | + ctx = g_slice_new (CustomInitContext); | ||
4939 | 363 | + ctx->result = g_simple_async_result_new (G_OBJECT (probe), | ||
4940 | 364 | + callback, | ||
4941 | 365 | + user_data, | ||
4942 | 366 | + dell_custom_init); | ||
4943 | 367 | + ctx->probe = g_object_ref (probe); | ||
4944 | 368 | + ctx->port = g_object_ref (port); | ||
4945 | 369 | + ctx->cancellable = cancellable ? g_object_ref (cancellable) : NULL; | ||
4946 | 370 | + ctx->gmi_retries = 3; | ||
4947 | 371 | + ctx->ati_retries = 3; | ||
4948 | 372 | + | ||
4949 | 373 | + custom_init_step (ctx); | ||
4950 | 374 | +} | ||
4951 | 375 | + | ||
4952 | 376 | +/*****************************************************************************/ | ||
4953 | 377 | + | ||
4954 | 378 | +static gboolean | ||
4955 | 379 | +port_probe_list_has_manufacturer_port (GList *probes, | ||
4956 | 380 | + DellManufacturer manufacturer) | ||
4957 | 381 | +{ | ||
4958 | 382 | + GList *l; | ||
4959 | 383 | + | ||
4960 | 384 | + for (l = probes; l; l = g_list_next (l)) { | ||
4961 | 385 | + if (GPOINTER_TO_UINT (g_object_get_data (G_OBJECT (l->data), TAG_DELL_MANUFACTURER)) == manufacturer) | ||
4962 | 386 | + return TRUE; | ||
4963 | 387 | + } | ||
4964 | 388 | + return FALSE; | ||
4965 | 389 | +} | ||
4966 | 390 | + | ||
4967 | 391 | +static MMBaseModem * | ||
4968 | 392 | +create_modem (MMPlugin *self, | ||
4969 | 393 | + const gchar *sysfs_path, | ||
4970 | 394 | + const gchar **drivers, | ||
4971 | 395 | + guint16 vendor, | ||
4972 | 396 | + guint16 product, | ||
4973 | 397 | + GList *probes, | ||
4974 | 398 | + GError **error) | ||
4975 | 399 | +{ | ||
4976 | 400 | + /* Note: at this point we don't make any difference between different | ||
4977 | 401 | + * Dell-branded QMI or MBIM modems; they may come from Novatel, Ericsson or | ||
4978 | 402 | + * Sierra. */ | ||
4979 | 403 | + | ||
4980 | 404 | +#if defined WITH_QMI | ||
4981 | 405 | + if (mm_port_probe_list_has_qmi_port (probes)) { | ||
4982 | 406 | + mm_dbg ("QMI-powered Dell-branded modem found..."); | ||
4983 | 407 | + return MM_BASE_MODEM (mm_broadband_modem_qmi_new (sysfs_path, | ||
4984 | 408 | + drivers, | ||
4985 | 409 | + mm_plugin_get_name (self), | ||
4986 | 410 | + vendor, | ||
4987 | 411 | + product)); | ||
4988 | 412 | + } | ||
4989 | 413 | +#endif | ||
4990 | 414 | + | ||
4991 | 415 | +#if defined WITH_MBIM | ||
4992 | 416 | + if (mm_port_probe_list_has_mbim_port (probes)) { | ||
4993 | 417 | + mm_dbg ("MBIM-powered Dell-branded modem found..."); | ||
4994 | 418 | + return MM_BASE_MODEM (mm_broadband_modem_mbim_new (sysfs_path, | ||
4995 | 419 | + drivers, | ||
4996 | 420 | + mm_plugin_get_name (self), | ||
4997 | 421 | + vendor, | ||
4998 | 422 | + product)); | ||
4999 | 423 | + } | ||
5000 | 424 | +#endif |
The diff has been truncated for viewing.