summaryrefslogtreecommitdiff
path: root/src/mbimcli
AgeCommit message (Collapse)AuthorFilesLines
2021-11-02mbimcli: implement --set-ip-packet-filtersAleksander Morgado3-28/+380
The option receives a key-value pair string that can be used to define zero or more filters. E.g. if we want to add TCP and UDP packets to the filters, we could run: $ PF_TCP="packet-filter=40000000000000000006,packet-mask=F00000000000000000FF" $ PF_UDP="packet-filter=40000000000000000011,packet-mask=F00000000000000000FF" $ sudo mbimcli -v -d /dev/wwan0mbim0 -p --set-ip-packet-filters="session-id=0,${PF_TCP},${PF_UDP}" Or, if we want to remove all filters, we could run: $ sudo mbimcli -v -d /dev/wwan0mbim0 -p --set-ip-packet-filters="session-id=0"
2021-10-25libmbim-glib,tlv: parsers for wake command and wake packet typesAleksander Morgado1-10/+79
2021-10-25ms-basic-connect-extensions: implement wake-reasonSom_SP1-2/+63
This CID is used by host to query the modem for its wake reason when power up because of device wake. If the device supports this function, but fails the query from host, it means the power up is not caused by a wake from the device. Includes updates by Aleksander Morgado to fix coding style issues, message definitions add missing documentation items.
2021-10-25ms-basic-connect-extensions-v3: implement 'Modem Configuration'Som_SP1-1/+57
This CID is used to notify the host of the configuration progress and parameters of the device. This CID is added as part of MBIM 3.0 extension. Includes updates by Aleksander Morgado to fix coding style issues, memory handling fixes add missing documentation items.
2021-10-25mbimcli: add support for MBIMEx v3.0 Device CapsAleksander Morgado1-23/+91
2021-10-24libmbim-glib,enums: rename 'MbimDataClassV2' to 'MbimDataClassV3'Aleksander Morgado2-6/+6
The type is introduced in MBIMEx v3.0, so just name it with the v3 suffix, not to confuse with the updated introduced in MBIMEx v2.0, which is compatible with the original type in MBIM v1.0.
2021-10-13libmbim-glib,mbimcli: 'Registration Parameters' command is part of MBIMEx v3.0Aleksander Morgado1-181/+182
2021-10-13libmbim-glib,mbimcli: 'Version' command is part of MBIMEx v2.0Aleksander Morgado1-94/+94
2021-10-12mbimcli,basic-connect: avoid updating connect positional arguments logicAleksander Morgado1-19/+4
The supported way to use the connect operation is through key-value pairs; the positional arguments method is fully deprecated and should no longer be used or updated.
2021-10-12ms-basic-connect-v3: switch 'Basic Connect' to use MbimTlvsAleksander Morgado1-31/+21
The logic is updated to avoid requiring intermediate structs in the API; for the string TLVs that are included as named fields we'll use the 'tlv-string' types. We also add support for the unnamed IEs as 'tlv-list' fields at the end of the messages.
2021-10-12libmbim-glib: new MbimTlv generic typeAleksander Morgado1-0/+2
The Microsoft Extensions define a new generic TLV type that allows including any kind of data in it: from strings, to arrays of uints, to more complex types. We define support for the generic 'tlv' type and the generic 'tlv-list' type, which allow implementing the "unnamed IEs" that are appended to some new messages in the MS extensions. And we also define support for a more specific 'tlv-string', used exclusively when the TLVs are part of the named fields, so that we can provide strings in our libmbim-glib APIs, instead of requiring the user to build MbimTlv instances.
2021-10-12ms-basic-connect: implement connect for mbim version 3Som_SP2-63/+162
This command is an extension for the existing MBIM_CID_CONNECT defined in the MBIM specification revision 1.0. This extension adds 5G SA specific parameters.
2021-10-12ms-basic-connect-v3: fix MbimTai struct definitionAleksander Morgado3-10/+55
The PLMN field is not a single 32 bit value, it's really 2 separate guint16 values. This is important because the endianness change in BE systems would be different. Also, the format of the MCC and MNC inside the PLMN fields is very specific to the implementation (BCD encoded, MNC PCS digit indicated in most significant bit of the MNC field...).
2021-10-12mbimcli,basic-connect: minor rework on how packet service status response is ↵Aleksander Morgado1-47/+30
printed No need to fully print the whole output in v3, just print the extra new things.
2021-10-12MBIMEx 3.0: implement "packet service v3" for SASom_SP1-20/+73
This command is an extension for the existing MBIM_CID_PACKET_SERVICE defined in the MBIM specification revision 2.0.
2021-10-12libmbim-glib: implement 'Base Stations Info v3'Aleksander Morgado1-41/+149
2021-10-12ms-basic-connect-extensions-v3: don't reimplement commands if they didn't changeAleksander Morgado1-8/+2
If a given command didn't change in the new version update of the service, skip creating methods to handle it, just use the ones from the original version.
2021-10-12ms-basic-connect-v3: don't reimplement commands if they didn't changeAleksander Morgado1-6/+1
If a given command didn't change in the new version update of the service, skip creating methods to handle it, just use the ones from the original version.
2021-10-12ms-basic-connect-v2: don't reimplement commands if they didn't changeAleksander Morgado1-20/+5
If a given command didn't change in the new version update of the service, skip creating methods to handle it, just use the ones from the original version.
2021-10-12libmbim-glib: implement 'Base Stations Info'Aleksander Morgado1-1/+267
2021-10-06mbimcli,ms-basic-connect-extensions: print detailed network error infoAleksander Morgado1-2/+15
2021-10-06ms-basic-connect-extensions-v3: fix order of NwError fieldAleksander Morgado1-1/+1
It should be the 2nd element, not the last one. Also, add it in the Notification, which was completely missing.
2021-10-06libmbim-glib,ms-basic-connect-extensions-v3: add new service to buildAleksander Morgado1-1/+0
2021-10-06ms-basic-connect-extensions-v3: implement 'lte-attach-info'Som_SP1-17/+50
This CID is an extension for the MBIM_CID_MS_LTE_ATTACH_STATUS already defined in the MBIM specification revision 1.0.
2021-10-06mbimcli: allow requesting MBIMEx v3.0Aleksander Morgado1-0/+12
2021-10-06libmbim-glib,ms-basic-connect-v3: fix ready status flagsAleksander Morgado1-15/+18
It should be defined as a flags bitmask, not as an enum. Also, the value for MBIM_SUBSCRIBER_READY_STATUS_FLAG_SIM_REMOVABLE was actually wrong.
2021-10-06libmbim-glib,ms-basic-connect-v3: add new service to buildAleksander Morgado1-2/+0
2021-10-06ms-basic-connect-v3: implement "subscriber-ready-status"Som_SP1-13/+48
This command is an extension for the existing MBIM_CID_SUBSCRIBER_READY_STATUS defined in the MBIM specification revision 1.0. This version of MBIM CID add a new field MBIM_SUBSCRIBER_READY_STATUS_FLAGS in the response.
2021-10-05mbimcli,ms-basic-connect-extensions: use key-value pairs for ↵Aleksander Morgado3-55/+132
--ms-set-registration-parameters And also, avoid custom string to enum parsers.
2021-10-05ms-basic-connect-extensions: rework enum fields in 'Registration Parameters'Aleksander Morgado1-27/+27
2021-10-05ms-basic-connect-extensions: rename 'Registration Params' to 'Registration ↵Aleksander Morgado1-22/+22
Parameters' In most cases we use full words, not abbreviations.
2021-10-05MBIMEx 3.0: implement "registration-params"Som_SP1-3/+130
This CID is used by the host to set 5G-specific registration parameters to an MBIM device. This CID is added as part of MBIMEx 3.0 for 5G SA support.
2021-09-30mbimcli,sar: demote message to debug levelAleksander Morgado1-1/+1
2021-09-30mbimcli,sar: print 'all' instead of '0xFFFFFFFF' in SAR config responseAleksander Morgado1-6/+6
2021-09-30mbimcli,sar: minor changes in how SAR config response is printedAleksander Morgado1-3/+6
2021-09-30mbimcli,sar: use regex matching for the list of SAR config statesAleksander Morgado3-41/+86
2021-09-30mbimcli,sar: avoid custom string to enums parsersAleksander Morgado2-13/+7
2021-09-30mbimcli,sar: use 'all' to set antenna index as '0xFFFFFFFF'Jack Song1-1/+9
2021-09-27mbimcli,ms-basic-connect-extensions: fix double message unrefAleksander Morgado1-1/+0
2021-09-27mbimcli,basic-connect: support 'context-type' in --connectAleksander Morgado1-2/+10
2021-09-27mbimcli,basic-connect: support 'compression' in --connectAleksander Morgado1-3/+11
2021-09-27mbimcli,basic-connect: avoid custom string to enums parsersAleksander Morgado1-43/+3
Use the new generic string to enum processor instead.
2021-09-27mbimcli,ms-basic-connect-extensions: avoid custom string to enums parsersAleksander Morgado2-244/+20
Use the new generic string to enum processor instead.
2021-09-27mbimcli: setup common helper to get enum values from stringsAleksander Morgado3-20/+38
2021-09-27mbimcli,basic-connect: auth, username and protocol validation only in legacy ↵Aleksander Morgado1-10/+10
input format This validation should not be applied when using key-value pairs, we should instead just pass whatever we received to the device, without any additional validation on top, as we do with other commands.
2021-09-27mbimcli,basic-connect: minor coding style updatesAleksander Morgado1-56/+26
Simplify the parser method to receive the ConnectActivateProperties to be used as output.
2021-09-27mbimcli,basic-connect: deprecate 'apn' key and prefer 'access-string'Aleksander Morgado1-15/+21
Let's try to have a consolidated naming for keys in different commands.
2021-09-27mbimcli,ms-basic-connect-extensions: use key-value pairs for ↵Aleksander Morgado1-102/+86
--ms-set-provisioned-contexts
2021-09-27mbimcli,basic-connect: overwrite duplicated key-value pairsAleksander Morgado1-23/+14
Don't fail on some duplicated key-value pairs; just overwrite the old ones in all possible keys. This gives us a consistent behavior in all keys, instead of different behaviors depending on which is the key being processed.
2021-09-27mbimcli: don't include possible enum values in the short command helpAleksander Morgado1-1/+1
This may work for enums with just a couple of values, but there are enums with ton of different possible values, and we cannot document all those there.