From owner-freebsd-hardware@FreeBSD.ORG Sun Jul 18 07:10:30 2004 Return-Path: Delivered-To: freebsd-hardware@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 6178016A4CF for ; Sun, 18 Jul 2004 07:10:30 +0000 (GMT) Received: from fuf.mingrone.org (fuf.mingrone.org [204.251.2.34]) by mx1.FreeBSD.org (Postfix) with SMTP id EC01543D48 for ; Sun, 18 Jul 2004 07:10:29 +0000 (GMT) (envelope-from joey@mingrone.org) Received: (qmail 6809 invoked from network); 18 Jul 2004 07:10:27 -0000 Received: from fuf.mingrone.org (HELO localhost) (204.251.2.34) by fuf.mingrone.org with SMTP; 18 Jul 2004 07:10:27 -0000 From: Joey Mingrone To: freebsd-hardware@freebsd.org Date: Sun, 18 Jul 2004 04:09:55 -0300 User-Agent: KMail/1.6.2 MIME-Version: 1.0 Content-Disposition: inline X-UID: 19 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Message-Id: <200407180409.55686.joey@mingrone.org> Subject: NDISulator with Intel 2200 b/g on 5.2.1-RELEASE-p9 (some success ...almost working) X-BeenThere: freebsd-hardware@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: General discussion of FreeBSD hardware List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 18 Jul 2004 07:10:30 -0000 Hi all, Here are the steps I took: I built a new kernel with "options KSTACK_PAGES=8" to accommodate the large alloc the w22n51.sys driver makes on the kernel stack I added the following directories from CURRENT under my source tree: src/sys/compat/ndis sys/modules/ndis sys/modules/if_ndis src/sys/dev/if_ndis src/usr.sbin/ndiscvt In /sys/compat/ndis/subr_ntoskrnl.c I had to comment out the following lines to get everything to build: #include kdb_enter("ntoskrnl_debugger(): breakpoint"); cd /usr/src/usr.sbin/ndiscvt make make install cd /sys/modules/ndis make make install I put w22n51.sys and w22n51.INF in /sys/modules/if_ndis. If anyone is looking for these file they can be found inside this zip: http://www.powernotebooks.com/Support/intel_2200_wlan.zip cd /sys/modules/if_ndis ndiscvt -i w22n51.INF -s w22n51.sys -o ndis_driver_data.h make I got an an error: "make: don't know how to make pccarddevs.h. Stop", so I removed pccarddevs.h from /sys/modules/if_ndis/Makefile an it built okay. make install kldload -v ndis -> Loaded ndis, id=3 kldload -v if_ndis -> worked sometimes, other times the command would just hang, but the system would still be usable when kldload if_ndis did work, the output would look like: ndis0: mem 0xff9ee000-0xff9eef ff irq 11 at device 2.0 on pci2 ndis0: NDIS API version: 5.1 ndis0: 11b rates: 1Mbps 2Mbps 5.5Mbps 11Mbps 5.5Mbps 11Mbps ndis0: 11g rates: 6Mbps 9Mbps 12Mbps 18Mbps 24Mbps 36Mbps 48Mbps 54Mbps Loaded if_ndis, id=7 Then ifconfig -a would show: bge0: flags=8843 mtu 1500 options=1b inet6 fe80::20e:a6ff:fec4:a0b1%bge0 prefixlen 64 scopeid 0x1 inet 192.168.0.4 netmask 0xffffff00 broadcast 192.168.0.255 ether 00:0e:a6:c4:a0:b1 media: Ethernet autoselect (100baseTX ) status: active plip0: flags=8810 mtu 1500 lo0: flags=8049 mtu 16384 inet 127.0.0.1 netmask 0xff000000 inet6 ::1 prefixlen 128 inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3 ndis0: flags=8802 mtu 1500 ether 00:0e:35:1f:df:57 media: IEEE 802.11 Wireless Ethernet autoselect status: no carrier ssid "" channel -1 authmode OPEN powersavemode OFF powersavesleep 100 wepmode OFF weptxkey 1 Next I did: wicontrol -i ndis0 -l output: 0 stations: ifconfig ndis0 inet 192.168.0.5 netmask 255.255.255.0 ssid 5270-4 Sometimes this would output: ifconfig: ioctl (SIOCAIFADDR): File exists Other times it would work. I think doing "ifconfig bge0 down" first helped. now the output from "ifconfig -a" looked like: bge0: flags=8802 mtu 1500 options=1b inet6 fe80::20e:a6ff:fec4:a0b1%bge0 prefixlen 64 scopeid 0x1 inet 192.168.0.4 netmask 0xffffff00 broadcast 192.168.0.255 ether 00:0e:a6:c4:a0:b1 media: Ethernet autoselect (100baseTX ) status: active plip0: flags=8810 mtu 1500 lo0: flags=8049 mtu 16384 inet 127.0.0.1 netmask 0xff000000 inet6 ::1 prefixlen 128 inet6 fe80::1%lo0 prefixlen 64 scopeid 0x3 ndis0: flags=8843 mtu 1500 inet6 fe80::20e:35ff:fe1f:df57%ndis0 prefixlen 64 duplicated scopeid 0x4 inet 192.168.0.5 netmask 0xffffff00 broadcast 192.168.0.255 ether 00:0e:35:1f:df:57 media: IEEE 802.11 Wireless Ethernet autoselect (OFDM/54Mbps) status: associated ssid 5270-4 1:5270-4 channel 6 authmode OPEN powersavemode OFF powersavesleep 100 wepmode OFF weptxkey 1 wicontrol -i ndis0 -l: 1 station: ap[0]: netname (SSID): [ 5270-4 ] BSSID: [ 00:0f:66:36:cb:e8 ] Channel: [ 6 ] Quality/Signal/Noise [signal]: [ 115 / 115 / 0 ] [dBm]: [ 115 / -34 / -149 ] BSS Beacon Interval [msec]: [ 0 ] Capinfo: [ ] Now I unplugged bge0 and successfully pinged 192.168.0.x addresses on the local LAN using the ndis0. So that's what successfully worked. Here's are some of the problems: Even with a defaultrouter entry in rc.conf, nothing outside the local LAN could be reached. Trying to loading the two ndis kernel modules from /boot/loader.conf wouldn't allow the system to boot. I hope that all makes sense. Joey