Commit message (Collapse) | Author | Age | Files | Lines | ||
---|---|---|---|---|---|---|
... | ||||||
* | build-aux,codegen: generate GIR compat helpers for arrays of structs | Aleksander Morgado | 2022-03-07 | 10 | -53/+1022 | |
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The original methods in libqmi-glib used GArrays of structs when it was required to return a collection of complex items. Some of these arrays of structs were so complex that contained inner arrays of other structs. Using these methods from C was no problem, but the automatic language binding support given by GObject Introspection isn't capable of using such complex arrays of structs. The simplest way forward is to switch those GArrays into GPtrArrays, so that we provide arrays of pointers to structs, instead of arrays of structs. This approach is fully supported right now by GIR, and doesn't give any additional problem. The new GIR compat method introduced are all suffixed with '_gir' in their names, and renamed to the original method name for the language binding. The original method names are explicitly flagged to be skipped by the bindings. E.g. the C method qmi_indication_uim_refresh_output_get_event() gets a new qmi_indication_uim_refresh_output_get_event_gir() compat method to be used by the bindings, and it's renamed to get_event() (without the _gir suffix) in the binding. If the structs contained other arrays of structs, new struct types using GPtrArray are also introduced, renamed with the 'Gir' suffix. E.g. the QmiMessageDmsListStoredImagesOutputListImage struct contains a GArray of QmiMessageDmsListStoredImagesOutputListImageSublistSublistElement elements, while the new QmiMessageDmsListStoredImagesOutputListImageGir struct contains a GPtrArray of the same type of elements. The use of GArrays and GPtrArrays in APIs is really not recommended by GIR, but in our case they're always transfer-none and so there is no much risk in binding getting that wrong. Whenever we rework these APIs completely, we can think on making sure we provide a single set of methods to be used both in C and bindings, and avoiding GArrays and GPtrArrays at the same time. This change was not done right now in order to keep the change as minimum as possible (e.g. the methods using GArrays of simple structs or GArrays of strings or bytes were not changed to have GIR compat methods). Fixes https://gitlab.freedesktop.org/mobile-broadband/libqmi/-/issues/83 | |||||
* | libqmi-glib,compat: fix minor typo in documentation | Aleksander Morgado | 2022-03-02 | 1 | -1/+1 | |
| | | | | Extends the fix that was done in 03166f830e5ff70b581e6715af3bbfdd768b7677 | |||||
* | docs,reference: QmiWdsGetCurrentSettingsRequestedSettings is flags | Aleksander Morgado | 2022-02-28 | 1 | -2/+2 | |
| | | | | | So publish the _build_string_from_mask() method in the API, not the _get_string() one. | |||||
* | libqmi-glib,qmicli: new foxconn modem service | Freedom Liu | 2022-02-28 | 15 | -2/+405 | |
| | ||||||
* | build: version bump to flag existence of new API (codegen related changes) | Aleksander Morgado | 2022-02-28 | 1 | -1/+1 | |
| | ||||||
* | libqmi-glib,compat: fix minor typo in documentation | Aleksander Morgado | 2022-02-27 | 1 | -1/+1 | |
| | ||||||
* | build-aux,codegen: clear array method not needed | Aleksander Morgado | 2022-02-27 | 3 | -11/+0 | |
| | | | | | Seems to be a leftover from a previous iteration. This method is not required because we can no longer have arrays of arrays. | |||||
* | build-aux,codegen: minor coding style fix | Aleksander Morgado | 2022-02-27 | 1 | -1/+1 | |
| | ||||||
* | build-aux,codegen: no need to defined private/public format in arrays | Aleksander Morgado | 2022-02-27 | 1 | -3/+0 | |
| | | | | | We can no longer have arrays of arrays, so there is no point in defining these. | |||||
* | build-aux,codegen: split variable declarations for bundles and structs | Aleksander Morgado | 2022-02-27 | 7 | -24/+56 | |
| | ||||||
* | build-aux,codegen: remove doc fields from methods in variables | Aleksander Morgado | 2022-02-27 | 5 | -203/+3 | |
| | | | | | Let's improve the main variable object documentation in one single place. | |||||
* | build-aux,codegen: coding style changes | Aleksander Morgado | 2022-02-27 | 9 | -48/+55 | |
| | ||||||
* | build-aux,codegen: 'Result' TLV doesn't apply in input bundles | Aleksander Morgado | 2022-02-27 | 1 | -3/+0 | |
| | ||||||
* | build-aux,codegen: sequence variable may need dispose | Aleksander Morgado | 2022-02-27 | 1 | -2/+2 | |
| | | | | Remove the TODO, because this is really required | |||||
* | build-aux,codegen: 'sequence-prefix-format' unsupported with 'fixed-size' arrays | Aleksander Morgado | 2022-02-27 | 1 | -7/+11 | |
| | ||||||
* | build-aux,codegen: remove emit_helper_methods() | Aleksander Morgado | 2022-02-27 | 5 | -35/+0 | |
| | | | | No longer needed anywhere. | |||||
* | build-aux,codegen: use per-type clear methods | Aleksander Morgado | 2022-02-27 | 6 | -36/+52 | |
| | | | | | We create new clear methods for each struct type, plus additional generic clear methods for GArrays and strings. | |||||
* | build-aux,codegen: emit_types() may update both hfile and cfile | Aleksander Morgado | 2022-02-26 | 6 | -16/+16 | |
| | ||||||
* | build-aux,codegen: require explicit array length definition | Aleksander Morgado | 2022-02-26 | 9 | -643/+714 | |
| | | | | | | Don't assume that if nothing given an size-prefix-format of 8 bits should be used; force the developer to provide a correct array size definition, either with size-prefix-format or fixed-size. | |||||
* | build-aux,codegen: 'to' is always reference in getter implementation | Aleksander Morgado | 2022-02-26 | 6 | -33/+18 | |
| | ||||||
* | libqmi-glib,compat: update copyright years | Aleksander Morgado | 2022-02-26 | 2 | -2/+2 | |
| | ||||||
* | build-aux,codegen: disallow arrays of arrays, use an intermediate struct always | Aleksander Morgado | 2022-02-26 | 1 | -0/+4 | |
| | | | | This is required since we're going to return C arrays in our API. | |||||
* | qmicli,uim: use the new Other Slots getter without array of arrays | Aleksander Morgado | 2022-02-26 | 1 | -10/+12 | |
| | ||||||
* | uim: avoid array of arrays in Personalization Status Other | Aleksander Morgado | 2022-02-26 | 4 | -18/+145 | |
| | ||||||
* | qmicli,uim: use the new Slot EID getter with QmiSlotEidElement | Aleksander Morgado | 2022-02-26 | 2 | -6/+8 | |
| | ||||||
* | uim: avoid array of arrays in Slot EID Information | Aleksander Morgado | 2022-02-26 | 3 | -11/+211 | |
| | | | | | We cannot do arrays of arrays when supporting the new GIR array compat methods in 1.32 | |||||
* | qmicli,loc: port to use the new APIs without QmiIndicationLoc...GpsTime | Aleksander Morgado | 2022-02-26 | 1 | -3/+4 | |
| | ||||||
* | qmicli,loc: port to use the new APIs without ↵ | Aleksander Morgado | 2022-02-26 | 1 | -5/+7 | |
| | | | | QmiIndicationLoc...DilutionOfPrecision | |||||
* | qmicli,dms: port to use the new APIs without ↵ | Aleksander Morgado | 2022-02-26 | 1 | -5/+5 | |
| | | | | QmiMessageDmsGetStoredImageInfoInputImage | |||||
* | qmicli,dms: port to use the new APIs without ↵ | Aleksander Morgado | 2022-02-26 | 1 | -24/+23 | |
| | | | | QmiMessageDmsDeleteStoredImageInputImage | |||||
* | build-aux,codegen: no longer allow TLVs as structs | Aleksander Morgado | 2022-02-26 | 2 | -128/+6 | |
| | | | | | | | | The TLVs that have more than one item should be defined as sequences, not as structs, so that we can avoid any unneeded intermediate struct. The struct variable types will now exclusively be for array elements. | |||||
* | loc: skip the need of the QmiIndicationLoc...GpsTime intermediate struct | Aleksander Morgado | 2022-02-26 | 4 | -3/+63 | |
| | ||||||
* | loc: skip the need of the QmiIndicationLoc...DilutionOfPrecision ↵ | Aleksander Morgado | 2022-02-26 | 4 | -6/+80 | |
| | | | | intermediate struct | |||||
* | dms: skip the need of the QmiMessageDmsGetStoredImageInfoInputImage ↵ | Aleksander Morgado | 2022-02-26 | 4 | -3/+105 | |
| | | | | intermediate struct | |||||
* | dms: skip the need of the QmiMessageDmsDeleteStoredImageInputImage ↵ | Aleksander Morgado | 2022-02-26 | 4 | -3/+106 | |
| | | | | intermediate struct | |||||
* | data,loc: remove wrong extra format field in a TLV | Aleksander Morgado | 2022-02-26 | 1 | -1/+0 | |
| | ||||||
* | qmi-codegen: skip the need of the intermediate QmiMessageResult struct | Aleksander Morgado | 2022-02-26 | 5 | -34/+34 | |
| | | | | | We can just have a sequence of variables in the Result TLV, no need for a full new type. | |||||
* | qmicli,pdc: port to use autoptr() | Aleksander Morgado | 2022-02-26 | 1 | -174/+93 | |
| | ||||||
* | qmicli,pdc: port to use new APIs without QmiConfigTypeAndId | Aleksander Morgado | 2022-02-26 | 1 | -86/+58 | |
| | ||||||
* | pdc: skip the need of the QmiConfigTypeAndId intermediate struct | Aleksander Morgado | 2022-02-26 | 4 | -11/+304 | |
| | ||||||
* | build-aux,codegen: update copyright years | Aleksander Morgado | 2022-02-26 | 16 | -17/+17 | |
| | ||||||
* | build: don't include CTL service in GIR | Aleksander Morgado | 2022-02-22 | 1 | -5/+7 | |
| | | | | | We should not include any private header or source file in the computation of the GIR files. | |||||
* | build-aux,codegen: skip gtk-doc snippets in internal CTL service | Aleksander Morgado | 2022-02-22 | 12 | -109/+132 | |
| | ||||||
* | libqmi-glib,doc: QmiNasBandPreference and QmiDmsBandCapability are compatible | Aleksander Morgado | 2022-02-22 | 2 | -2/+6 | |
| | | | | Just make an explicit reference about this bit by bit compatibility. | |||||
* | libqmi-glib,device: fix leak on unexpected message errors | Aleksander Morgado | 2022-02-22 | 1 | -6/+9 | |
| | | | | transaction_complete_and_free() doesn't take ownership of the GError | |||||
* | libqmi-glib,test: fix leak in invalid NAS Get Cell Location Info test | Aleksander Morgado | 2022-02-22 | 1 | -1/+1 | |
| | ||||||
* | compat: fix 'GERAN Info' TLV return in 'NAS Get Cell Location Info' | Aleksander Morgado | 2022-02-22 | 4 | -4/+226 | |
| | | | | | | | | | | | | | The 'GERAN Info' TLV returned a "cell" GArray with array elements of the wrong format. This was fixed in the 'GERAN Info v2' update, but the compat method still needs to be able to return a GArray We could return an empty GArray and be done with it, but providing a compat array with the old element type isn't a big deal either, so we try to do that. This avoids breaking users that were correctly assuming the output GArray was always set if the TLV getter didn't fail. | |||||
* | build-aux,codegen: allow defining per-container "compat" contexts | Aleksander Morgado | 2022-02-22 | 2 | -4/+60 | |
| | | | | | | | | The compat methods need to be able to return variables in transfer-none, i.e. still owned by the container itself. In order to do so in compat methods, we will create a custom compat context that is owned by the container, so that when the container is disposed, so is the compat context. | |||||
* | libqmi-glib,compat: don't set args not requested by user | Aleksander Morgado | 2022-02-21 | 1 | -4/+8 | |
| | ||||||
* | simple-tester-python: support QMI over MBIM automatically | Aleksander Morgado | 2022-02-17 | 1 | -1/+1 | |
| |