Skip to content
Snippets Groups Projects
  1. Nov 13, 2020
    • Aleksander Morgado's avatar
      libmbim-glib,device: avoid using an already unref-ed source · ef133a7a
      Aleksander Morgado authored
      We were creating the source, attaching it to the main context, and
      removing our reference right away. That meant that the ownership of
      the source was fully given to the main context, and so we shouldn't
      have attempted to remove it from the main context later on, as it
      could have already been fired and removed behind our back.
      
      Solve this, by making sure we keep a valid source reference of our
      own, and in this way we can safely destroy the source (it's fine to
      destroy an already destroyed source, as long as the reference is
      valid) and then fully unref it.
      
        ModemManager[55085]: transaction 0x6 aborted, but message is not abortable
        ModemManager[55085]: [/dev/mhi_MBIM] MBIM error: Cannot write message: Broken pipe
      
        (ModemManager:55085): GLib-CRITICAL **: 10:04:58.605: g_source_destroy: assertion 'g_atomic_int_get (&source->ref_count) > 0' failed
      
        Thread 1 "ModemManager" received signal SIGTRAP, Trace/breakpoint trap.
        0x00007ffff775ef23 in g_logv () from /usr/lib/libglib-2.0.so.0
        (gdb) bt
        #0  0x00007ffff775ef23 in g_logv () at /usr/lib/libglib-2.0.so.0
        #1  0x00007ffff775f1a0 in g_log () at /usr/lib/libglib-2.0.so.0
        #2  0x00007ffff7a8f564 in transaction_context_free (ctx=0x5555558254a0) at mbim-device.c:162
        #3  0x00007ffff79240ba in  () at /usr/lib/libgio-2.0.so.0
        #4  0x00007ffff78537b1 in g_object_unref () at /usr/lib/libgobject-2.0.so.0
        #5  0x00007ffff77512b3 in  () at /usr/lib/libglib-2.0.so.0
        #6  0x00007ffff775384a in  () at /usr/lib/libglib-2.0.so.0
        #7  0x00007ffff7756b90 in g_main_context_dispatch () at /usr/lib/libglib-2.0.so.0
        #8  0x00007ffff77a81f9 in  () at /usr/lib/libglib-2.0.so.0
        #9  0x00007ffff7756163 in g_main_loop_run () at /usr/lib/libglib-2.0.so.0
        #10 0x00005555555a0b15 in main (argc=2, argv=0x7fffffffeac8) at main.c:206
      ef133a7a
  2. Oct 01, 2020
  3. Sep 29, 2020
  4. Sep 23, 2020
  5. Aug 09, 2020
  6. Jul 10, 2020
    • Aleksander Morgado's avatar
      libmbim-glib,proxy: fix reporting of merged subscribe list · ecd188ff
      Aleksander Morgado authored
      We were doing the subscribe list merge correctly, but not reporting it
      as done because the 'updated' pointer is set to NULL before returning
      it.
      
      This was breaking QMI over MBIM indications, as the registration
      message to request them was never sent to the device.
      ecd188ff
  7. Jun 28, 2020
    • Aleksander Morgado's avatar
      libmbim-glib,proxy: fix segfault when printing updated subscriber list · 0590b7e9
      Aleksander Morgado authored
      We were printing the 'updated' variable after its contents had already
      been stolen.
      
          [28 Jun 2020, 03:06:27] [Debug] Merged service subscribe list built for device '/dev/cdc-wdm0'
          Thread 1 "mbim-proxy" received signal SIGSEGV, Segmentation fault.
          _mbim_proxy_helper_service_subscribe_list_debug (list=list@entry=0x0, list_size=6) at mbim-proxy-helpers.c:104
          104	        const MbimEventEntry *entry = list[i];
          (gdb) p list
          $1 = (const MbimEventEntry * const *) 0x0
          (gdb) p list_size
          $2 = 6
      
      The segfault was only triggered when the mbim-proxy was run with
      --verbose.
      0590b7e9
  8. Jun 23, 2020
    • Aleksander Morgado's avatar
      libmbim-glib,device: ignore messages with wrong MBIM message type · cbb3e394
      Aleksander Morgado authored
      The Cinterion mPLS62-w may end up sending messages which are clearly
      not well formatted MBIM messages, and upon receiving one of them, the
      mbim-proxy would get completely stuck (e.g. attempting to read a
      message of >800MB because of the reported length in the first
      malformed messae).
      
      Try to avoid this, by doing an initial filter by message type, which
      at least solves the seen problem. Not a fully robust fix yet, though.
      
      E.g. new logs:
      
          [23 jun 2020, 10:43:49] [Debug] [/dev/cdc-wdm1] Sent message (translated)...
          <<<<<< Header:
          <<<<<<   length      = 48
          <<<<<<   type        = command (0x00000003)
          <<<<<<   transaction = 20
          <<<<<< Fragment header:
          <<<<<<   total   = 1
          <<<<<<   current = 0
          <<<<<< Contents:
          <<<<<<   service = 'atds' (5967bdcc-7fd2-49a2-9f5c-b2e70e527db3)
          <<<<<<   cid     = 'location' (0x00000002)
          <<<<<<   type    = 'query' (0x00000000)
      
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 293 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 200 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 168 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 311 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 311 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 311 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 335 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 277 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 312 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 314 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 312 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 280 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 312 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 312 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 326 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 260 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 244 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 326 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 326 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 326 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 306 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 334 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 324 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 356 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 356 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 191 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 201 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 356 bytes in MBIM stream as message type validation fails
          [23 jun 2020, 10:43:49] -Warning ** [/dev/cdc-wdm1] discarding 356 bytes in MBIM stream as message type validation fails
      cbb3e394
  9. Jun 18, 2020
  10. May 30, 2020
  11. May 29, 2020
  12. May 27, 2020
  13. May 18, 2020
  14. May 14, 2020
  15. May 13, 2020
Loading