Hi!
The diff below makes cdce(4) to recognize cdce part of my Dell 5540 mini-pcie
card.
cdce port must be enabled before use by sending following to one
of the serial ports(should it be somehow documented in the manpage?):
AT+CFUN=1 # enable radio
AT+CGDCONT=1,IP,internet # configure apn
AT*ENAP=1,1 # enable cdce port
umodem0 at uhub5 port 6 configuration 1 interface 1 ADell Wireless 5540 Dell
Wireless 5540 rev 2.00/0.00 addr 3
umodem0: data interface 2, has CM over data, has break
umodem0: status change notification available
ucom0 at umodem0
umodem1 at uhub5 port 6 configuration 1 interface 3 ADell Wireless 5540 Dell
Wireless 5540 rev 2.00/0.00 addr 3
umodem1: data interface 4, has CM over data, has break
umodem1: status change notification available
ucom1 at umodem1
cdce0 at uhub5 port 6 configuration 1 interface 6 ADell Wireless 5540 Dell
Wireless 5540 rev 2.00/0.00 addr 3
cdce0: address 02:80:37:ec:02:00
umodem2 at uhub5 port 6 configuration 1 interface 9 ADell Wireless 5540 Dell
Wireless 5540 rev 2.00/0.00 addr 3
umodem2: data interface 10, has CM over data, has break
umodem2: status change notification available
ucom2 at umodem2
ugen0 at uhub5 port 6 configuration 1 ADell Wireless 5540 Dell Wireless 5540
rev 2.00/0.00 addr 3
Diff:
Index: sys/dev/usb/if_cdce.c
===
RCS file: /OpenBSD/src/sys/dev/usb/if_cdce.c,v
retrieving revision 1.50
diff -u -p -r1.50 if_cdce.c
--- sys/dev/usb/if_cdce.c 3 Jul 2011 15:47:17 - 1.50
+++ sys/dev/usb/if_cdce.c 20 Oct 2011 10:03:40 -
@@ -146,8 +146,9 @@ cdce_match(struct device *parent, void *
if (cdce_lookup(uaa-vendor, uaa-product) != NULL)
return (UMATCH_VENDOR_PRODUCT);
- if (id-bInterfaceClass == UICLASS_CDC id-bInterfaceSubClass ==
- UISUBCLASS_ETHERNET_NETWORKING_CONTROL_MODEL)
+ if (id-bInterfaceClass == UICLASS_CDC (
+ id-bInterfaceSubClass ==
UISUBCLASS_ETHERNET_NETWORKING_CONTROL_MODEL ||
+ id-bInterfaceSubClass == UISUBCLASS_MOBILE_DIRECT_LINE_MODEL))
return (UMATCH_IFACECLASS_GENERIC);
return (UMATCH_NONE);
Index: sys/dev/usb/usb.h
===
RCS file: /OpenBSD/src/sys/dev/usb/usb.h,v
retrieving revision 1.37
diff -u -p -r1.37 usb.h
--- sys/dev/usb/usb.h 4 Mar 2011 23:55:32 - 1.37
+++ sys/dev/usb/usb.h 20 Oct 2011 10:03:40 -
@@ -412,6 +412,7 @@ typedef struct {
#define UISUBCLASS_CAPI_CONTROLMODEL 5
#define UISUBCLASS_ETHERNET_NETWORKING_CONTROL_MODEL 6
#define UISUBCLASS_ATM_NETWORKING_CONTROL_MODEL 7
+#define UISUBCLASS_MOBILE_DIRECT_LINE_MODEL10
#define UIPROTO_CDC_AT 1
#define UICLASS_HID0x03
Index: share/man/man4/cdce.4
===
RCS file: /OpenBSD/src/share/man/man4/cdce.4,v
retrieving revision 1.14
diff -u -p -r1.14 cdce.4
--- share/man/man4/cdce.4 14 Mar 2008 15:19:52 - 1.14
+++ share/man/man4/cdce.4 20 Oct 2011 10:03:40 -
@@ -46,6 +46,8 @@ including the following:
.It
Acer Labs USB 2.0 Data Link
.It
+Dell Wireless 5540
+.It
FRITZ!Box Fon ata 1020
.It
G.Mate YP3X00
--
rivo