tech-kern archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

Re: umodeswitch



Emmanuel Dreyfus <manu%netbsd.org@localhost> wrote:

>   port 3 addr 4: high speed, self powered, config 1, ZTE WCDMA
> Technologies MSM(0
> x0117), ZTE,Incorporated(0x19d2), rev 0.00(0x0000), serial
> MF1900BYTD010000

I had some success with ZTE MF112 by just telling umass to not attach it
using umass_quirks (patch below). I got a frienly OK when telling it ATZ
on /dev/ttyU2 at 230400 bps. I need to add a SIM to perform further
testing.

Is the approach sane?

--- u3g.c.orig  2021-04-09 20:52:16.008519125 +0200
+++ u3g.c       2021-04-11 03:15:54.050593540 +0200
@@ -251,8 +251,9 @@
        { USB_VENDOR_ZTE, USB_PRODUCT_ZTE_MF622 },
        { USB_VENDOR_ZTE, USB_PRODUCT_ZTE_MF626 },
        { USB_VENDOR_ZTE, USB_PRODUCT_ZTE_MF628 },
        { USB_VENDOR_ZTE, USB_PRODUCT_ZTE_MF820D },
+       { USB_VENDOR_ZTE, USB_PRODUCT_ZTE_MF112 },
 
        /* 4G Systems */
        { USB_VENDOR_LONGCHEER, USB_PRODUCT_LONGCHEER_XSSTICK_P14 },
        { USB_VENDOR_LONGCHEER, USB_PRODUCT_LONGCHEER_XSSTICK_W14 },
--- umass_quirks.c.orig 2021-04-11 02:24:22.832597008 +0200
+++ umass_quirks.c      2021-04-11 03:16:45.624011222 +0200
@@ -342,8 +342,22 @@
          PQUIRK_NOSYNCCACHE,
          UMATCH_VENDOR_PRODUCT,
          NULL, NULL
        },
+
+       /*
+        * ZTE MF112 3G modem advertises itself as umass, but the 
+        * storage is not functionnal and umodeswitch fails to change 
+        * personality, beaause it is already a 3G modem. Make sure 
+        * umass does not attach it.
+        */
+       { { USB_VENDOR_ZTE, USB_PRODUCT_ZTE_MF112 },
+         UMASS_WPROTO_UNSPEC, UMASS_CPROTO_UNSPEC,
+         0,
+         0,
+         UMATCH_NONE,
+         NULL, NULL
+       },
 };
 
 const struct umass_quirk *
 umass_lookup(uint16_t vendor, uint16_t product)




-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
manu%netbsd.org@localhost


Home | Main Index | Thread Index | Old Index