Re: FreeBSD 8.1, if_cdce and an OpenMoko phone

2010-09-19 Thread Hans Petter Selasky
On Sunday 19 September 2010 01:10:27 Torfinn Ingolfsen wrote:
 Hi,
 
 Under FreeBSD 7.3-stable, I could connect my Neo FreeRunner (Openmoko
 phone) via usb cable to my workstation, kldload if_cdce and get an
 ethernet interface up.
 Now running FreeBSD 8.1-release on said workstation:
 r...@kg-work2# uname -a
 FreeBSD kg-work2.kg4.no 8.1-RELEASE FreeBSD 8.1-RELEASE #0: Mon Jul 19
 02:55:53 UTC 2010
 r...@almeida.cse.buffalo.edu:/usr/obj/usr/src/sys/GENERIC  i386
 
 and the FreeRunner is detected like this:
 r...@kg-work2#  usbconfig
 ugen0.1: UHCI root HUB Intel at usbus0, cfg=0 md=HOST spd=FULL (12Mbps)
 pwr=ON ugen1.1: UHCI root HUB Intel at usbus1, cfg=0 md=HOST spd=FULL
 (12Mbps) pwr=ON ugen2.1: UHCI root HUB Intel at usbus2, cfg=0 md=HOST
 spd=FULL (12Mbps) pwr=ON ugen3.1: EHCI root HUB Intel at usbus3, cfg=0
 md=HOST spd=HIGH (480Mbps) pwr=ON ugen2.2: RNDIS/Ethernet Gadget Linux
 2.6.29-rc3-v21 with s3c2410_udc at usbus2, cfg=0 md=HOST spd=FULL
 (12Mbps) pwr=ON
 
 and cdce(4) is already in the GENERIC kernel. From /var/log/messages:
 Sep 19 00:06:49 kg-work2 root: Unknown USB device: vendor 0x1457 product
 0x5122 bus uhub2 Sep 19 00:06:49 kg-work2 kernel: ugen2.2: Linux
 2.6.29-rc3-v21 with s3c2410_udc at usbus2 Sep 19 00:12:47 kg-work2
 kernel: interface cdce.1 already present in the KLD 'kernel'!
 
 The problem is of course that therer isn't an ethernet interface for this
 usb device: r...@kg-work2# ifconfig
 em0: flags=8843UP,BROADCAST,RUNNING,SIMPLEX,MULTICAST metric 0 mtu 1500
   
 options=209bRXCSUM,TXCSUM,VLAN_MTU,VLAN_HWTAGGING,VLAN_HWCSUM,WOL_MAGIC
   ether 00:08:74:b3:5e:c8
   inet 10.1.150.16 netmask 0x broadcast 10.1.255.255
   media: Ethernet autoselect (100baseTX full-duplex)
   status: active
 plip0: flags=8810POINTOPOINT,SIMPLEX,MULTICAST metric 0 mtu 1500
 lo0: flags=8049UP,LOOPBACK,RUNNING,MULTICAST metric 0 mtu 16384
   options=3RXCSUM,TXCSUM
   inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3
   inet6 ::1 prefixlen 128
   inet 127.0.0.1 netmask 0xff00
   nd6 options=3PERFORMNUD,ACCEPT_RTADV
 
 So, what magic tricks do I need to perform to get this working under 8.1?
 
 References:
 1) http://wiki.openmoko.org/wiki/Neo_FreeRunner

Hi,

You need to:

usbconfig -d X.Y set_config 1

To get it working.

--HPS
___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to freebsd-usb-unsubscr...@freebsd.org


Re: FreeBSD 8.1, if_cdce and an OpenMoko phone

2010-09-19 Thread Torfinn Ingolfsen
On Sun, 19 Sep 2010 10:26:18 +0200
Hans Petter Selasky hsela...@c2i.net wrote:

 You need to:
 
 usbconfig -d X.Y set_config 1
 
 To get it working.

Indeed, that works nicely:
r...@kg-work2# usbconfig -d 2.2 set_config 1
r...@kg-work2# tail /var/log/messages
Sep 19 04:00:00 kg-work2 newsyslog[1242]: logfile turned over due to size100K
Sep 19 18:56:18 kg-work2 kernel: cdce0: CDC Ethernet Control Model (ECM) on 
usbus2
Sep 19 18:56:18 kg-work2 kernel: ue0: USB Ethernet on cdce0
Sep 19 18:56:18 kg-work2 kernel: ue0: Ethernet address: 00:1f:11:01:0d:39
Sep 19 18:56:19 kg-work2 root: Unknown USB device: vendor 0x1457 product 0x5122 
bus uhub2
r...@kg-work2# ifconfig ue0
ue0: flags=8802BROADCAST,SIMPLEX,MULTICAST metric 0 mtu 1500
ether 00:1f:11:01:0d:39

Thanks!

For future reference, where is this (things like set_config 1 and so on) 
documented?
The man page for usbconfig doesn't have any reference to it, nor does usb(4).

And perhaps the cdce(4) man page should mention that the interface name will be 
ueX?
HAND
-- 
Torfinn

___
freebsd-usb@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-usb
To unsubscribe, send any mail to freebsd-usb-unsubscr...@freebsd.org