Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 8 Aug 2009 13:21:20 +0200
From:      Lucius Windschuh <lwindschuh@googlemail.com>
To:        Hans Petter Selasky <hselasky@c2i.net>, freebsd-usb@freebsd.org
Subject:   Re: reattach 3g0 device: could not allocate new device
Message-ID:  <90a5caac0908080421n35bd31b7v19b18d636d946616@mail.gmail.com>
In-Reply-To: <200908071712.50579.hselasky@c2i.net>
References:  <89dbfdc30902231031j4407614vdce09e8e58cdc346@mail.gmail.com> <200908060937.48442.hselasky@c2i.net> <90a5caac0908060412r3a117597m16573c16d35cc34a@mail.gmail.com> <200908071712.50579.hselasky@c2i.net>

next in thread | previous in thread | raw e-mail | index | archive | help

2009/8/7 Hans Petter Selasky <hselasky@c2i.net>:
> Try this patch:
>
> src/sys/dev/usb/usb_device.c
>
> @@ -1777,7 +1777,8 @@
>                        }
>                } else if (usb_test_huawei_autoinst_p(udev, &uaa) == 0) {
>                        DPRINTFN(0, "Found Huawei auto-install disk!\n");
> -                       err = USB_ERR_STALLED;  /* fake an error */
> +                       /* leave device unconfigured */
> +                       usb_unconfigure(udev, USB_UNCFG_FLAG_FREE_SUBDEV);
>                }
>        } else {
>                err = 0;                /* set success */
>

That makes it work nicely:

$ kldload u3g
(insert dongle)
dmesg:
 usb_test_autoinstall:571: Eject CD command status: USB_ERR_NORMAL_COMPLETION
 usb_alloc_device:1781: Found Huawei auto-install disk!
 ugen0.3: <Novatel Wireless> at usbus0
 ugen0.3: <Novatel Wireless> at usbus0 (disconnected)
 ugen0.3: <Novatel Wireless> at usbus0
 u3g0: <Data Interface> on usbus0
 u3g0: Found 2 ports.

Thank you. :-)

Lucius



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?90a5caac0908080421n35bd31b7v19b18d636d946616>