-current is booting on my laptop again, and after applying the diff the Huawei E220 is now recognized as

umsm0 at uhub2
 port 1 "HUAWEI Technologies HUAWEI Mobile" rev 1.10/0.00 addr 2
ucom0 at umsm0 portno 0

Anyone who has a ppp.conf that might work with swedish "3" operator (Hi3G Access AB) so I can test the modem? I have no real personal interest in this modem right now, hence won't take the time to figure it out.

/Markus


Markus Bergkvist wrote:
I'll test it as soon as I get a chance, currently my laptop gets a page fault and enters ddb during boot :-/
Also, I could not apply your diff on -current. Below is an updated diff.

BR,
Markus

--- sys/dev/usb/umsm.c.orig     Wed Dec 12 22:21:44 2007
+++ sys/dev/usb/umsm.c  Wed Dec 12 22:14:21 2007
@@ -58,6 +58,7 @@
        { USB_VENDOR_AIRPRIME,  USB_PRODUCT_AIRPRIME_PC5220 },
        { USB_VENDOR_DELL,      USB_PRODUCT_DELL_W5500 },
        { USB_VENDOR_KYOCERA2,  USB_PRODUCT_KYOCERA2_KPC650 },
+       { USB_VENDOR_HUAWEI,    USB_PRODUCT_HUAWEI_E220 },
        { USB_VENDOR_NOVATEL,   USB_PRODUCT_NOVATEL_EXPRESSCARD },
        { USB_VENDOR_NOVATEL,   USB_PRODUCT_NOVATEL_MERLINV620 },
        { USB_VENDOR_NOVATEL,   USB_PRODUCT_NOVATEL_S720 },
@@ -119,6 +120,25 @@

        bzero(&uca, sizeof(uca));
        sc->sc_udev = uaa->device;
+
+       if(uaa->product == USB_PRODUCT_HUAWEI_E220) {
+               usb_device_request_t req;
+               usbd_status err;
+
+               req.bmRequestType = UT_WRITE_DEVICE;
+               req.bRequest = UR_SET_FEATURE;
+               USETW(req.wValue, 1);
+               USETW(req.wIndex, 0);
+               USETW(req.wLength, 0);
+               err = usbd_do_request(sc->sc_udev, &req, 0);
+
+               if (err) {
+                       printf("%s: failed to initialize device ",
+                                       sc->sc_dev.dv_xname);
+                       sc->sc_dying = 1;
+                       return;
+               }
+       }

        if (usbd_set_config_index(sc->sc_udev, UMSM_CONFIG_NO, 1) != 0) {
                printf("%s: could not set configuration no\n",
--- share/man/man4/umsm.4.orig  Wed Dec 12 22:22:33 2007
+++ share/man/man4/umsm.4       Wed Dec 12 22:15:01 2007
@@ -38,6 +38,7 @@
 .Bl -column "Device                " "Bus" -compact -offset 6n
 .It Em "Device         Bus"
 .It Li "AirPrime PC5220" Ta Ta CardBus
+.It Li "Huawei Mobile E220" Ta Ta USB
 .It Li "Kyocera KPC650" Ta Ta CardBus
 .It Li "Novatel Wireless ES620" Ta Ta USB
 .It Li "ONDA Communication H600" Ta Ta CardBus


Felix Kronlage wrote:
On Tue, Dec 11, 2007 at 04:58:18PM +0100, [EMAIL PROTECTED]@mgedv.net wrote:

i'm currently testing the c-code which is provided there (i'm not
a guru) but the first one does not look that bad (there are some
errors and problems which i do not really have the time right now
to look into).

attached diff sends the proper message to the device to cause the
ucom port to appear. I still have the problem, that sometimes talking
to the ucom will cause the device to reset itself, I have not figured
out what is causing that.

felix

Reply via email to