Re: Updated Driver for 3945ABG Intel 3945ABG Wireless LAN controller

2007-01-31 Thread Benjamin Close

Hi Folks,
   A new version of the driver is up which fixes the firmware issues. 
Seems the wpi-firmware-kmod port was creating corrupt modules.
Things should work much better now. Download at the same place, file: 
20070131-wpi-freebsd.tar.gz


Cheers,
   Benjamin

Sam Fourman Jr. wrote:

I can also confirm that i get the firmware_get: failed to load
firmware image wpi_fw on the
20070125 version.
I should note that I tried it on a fresh 6.2 RELEASE install.

Sam Fourman Jr.

On 1/27/07, Gilbert Cao [EMAIL PROTECTED] wrote:

On Fri, Jan 26, 2007 at 11:09:51PM +1030, Benjamin Close wrote:
 Hi Gilbert,
Thanks for the custom version. I've integrated the changes into the
 driver I'm working on.
 For those wanting to test out the driver which is now fully up to date
 with all change from NetBSD  OpenBSD - and has a few minor 
improvements

 over them, grab it from:

 http://www.clearchain.com/~benjsc/download/

 File is: 20070125-wpi-freebsd.tar.gz

 Full instructions on how to build / install the driver are in the 
README

 in the tar file.

 This should work both under -current and 6.2-Stable now.

 Info about the driver and what's working/broken can be found at:

 http://www.clearchain.com/wiki/wpi

 Cheers,
Benjamin

I have tried the new 20070125 version.
However, I did not manage to make work. At least, it compiles.
I have installed, both wpi_fw.ko and the if_wpi.ko, as the README said.
wpi_fw.ko lies in /boot/modules and if_wpi.ko in /boot/kernel.

When, I kldload if_wpi, here is a small sample of /var/log/messages

Jan 27 10:30:39 vaio kernel: wpi0: Intel(R) PRO/Wireless 3945ABG 
mem 0xcc00-0xcc000fff irq 18 at device 0.0 on pci6
Jan 27 10:30:39 vaio kernel: bus_dmamem_alloc failed to align memory 
properly.

Jan 27 10:30:39 vaio last message repeated 6 times
Jan 27 10:30:39 vaio kernel: wpi0: Ethernet address: 00:18:de:5c:cb:9a
Jan 27 10:30:39 vaio kernel: wpi0: [GIANT-LOCKED]
Jan 27 10:30:39 vaio kernel: wpi0: 11a rates:
Jan 27 10:30:39 vaio kernel: wpi0: 11b rates:
Jan 27 10:30:40 vaio kernel: firmware_get: failed to load firmware 
image wpi_fw
Jan 27 10:30:40 vaio kernel: wpi0: could not load firmware image 
'wpi_fw'
Jan 27 10:30:40 vaio kernel: firmware_get: failed to load firmware 
image wpi_fw
Jan 27 10:30:40 vaio kernel: wpi0: could not load firmware image 
'wpi_fw'
Jan 27 10:32:19 vaio kernel: firmware_get: failed to load firmware 
image wpi_fw
Jan 27 10:32:19 vaio kernel: wpi0: could not load firmware image 
'wpi_fw'


In kldstat, both modules are loaded.
Then, I have kldunload if_wpi (and if_wpi seems to be reload,
automatically, I don't know why). Same problem, it seems that wpi_fw
could not be load (found ?).

As a result, no AP is associated.


After a fresh reboot, I have reinstall the custom 20070121 version of
mine, and all returns OK.
Another strange thing: when kldload if_wpi with 20070121 version, and
then kldstat, I don't see wpi_ucode. It seems that wpi_ucode.ko does
not need to be loaded, in my case.
My wpi_ucode.ko lies in /boot/modules

After another fresh reboot, I first moved wpi_ucode.ko to another place.
When I kldload if_wpi, I got the following message:

Jan 27 09:47:16 vaio kernel: wpi0: Intel(R) PRO/Wireless 3945ABG 
mem 0xcc00-0xcc000fff irq 18 at device 0.0 on pci6
Jan 27 09:47:16 vaio kernel: bus_dmamem_alloc failed to align memory 
properly.

Jan 27 09:47:16 vaio last message repeated 6 times
Jan 27 09:47:16 vaio kernel: wpi0: Ethernet address: 00:18:de:5c:cb:9a
Jan 27 09:47:16 vaio kernel: wpi0: [GIANT-LOCKED]
Jan 27 09:47:16 vaio kernel: wpi0: 11a rates: 6Mbps 9Mbps 12Mbps 
18Mbps 24Mbps 36Mbps 48Mbps 54Mbps

Jan 27 09:47:16 vaio kernel: wpi0: 11b rates: 1Mbps 2Mbps 5.5Mbps 11Mbps
Jan 27 09:47:16 vaio kernel: wpi0: 11g rates: 1Mbps 2Mbps 5.5Mbps 
11Mbps 6Mbps 9Mbps 12Mbps 18Mbps 24Mbps 36Mbps 48Mbps 54Mbps
Jan 27 09:47:16 vaio kernel: firmware_get: failed to load firmware 
image wpi_ucode
Jan 27 09:47:16 vaio kernel: wpi0: could not load firmware image 
'wpi_ucode'


So, it seems that wpi_ucode.ko have to lied in my /boot/modules (the
place where I have also put if_wpi 20070121 version), even if it is not
loaded.

--

 (hika) Gilbert Cao
 http://www.miaouirc.com
  - MiaouIRC Project 2002-2003
 http://www.bsdmon.com
  - The BSD DMON Power to serve
 IRC : #miaule at IRCNET Network





___
[EMAIL PROTECTED] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-drivers
To unsubscribe, send any mail to 
[EMAIL PROTECTED]

___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Updated Driver for 3945ABG Intel 3945ABG Wireless LAN controller

2007-01-26 Thread Benjamin Close

Gilbert Cao wrote:

Snip
As I have posted a message here:
http://lists.freebsd.org/pipermail/freebsd-questions/2007-January/140475.html

I have put a custom version of mine from your last package here:
http://www.bsdmon.com/download/20070121-wpi-freebsd.tar.gz

What I have mainly done is to make the package compile and work (for me
a least) on 6.2-RELEASE (and possibly other 6.x ?).

Don't know if you will ignore it or not, but I feel like I should have post
it here, anyway.
As it works well, now for my daily uses (reading mail, surfing on the
HTTP, playing Q3 ;), I may post some debug output, if needed, but I keep
using 6.2, no -current.
The post may be off topic, sorry ..

Hi Gilbert,
   Thanks for the custom version. I've integrated the changes into the 
driver I'm working on.
For those wanting to test out the driver which is now fully up to date 
with all change from NetBSD  OpenBSD - and has a few minor improvements 
over them, grab it from:


http://www.clearchain.com/~benjsc/download/

File is: 20070125-wpi-freebsd.tar.gz

Full instructions on how to build / install the driver are in the README 
in the tar file.


This should work both under -current and 6.2-Stable now.

Info about the driver and what's working/broken can be found at:

http://www.clearchain.com/wiki/wpi

Cheers,
   Benjamin
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


Re: Updated Driver for 3945ABG Intel 3945ABG Wireless LAN controller

2007-01-07 Thread Benjamin Close

Massimo Lusetti wrote:

On 1/5/07, Max Laier [EMAIL PROTECTED] wrote:

Thoughts?  Volunteers?

I can say that the first attempt still running fine here on my laptop
on a -STABLE as of yesterday. I use it on a daily basis without any
glitch. I must say i don't do or tried to do nothing special or
network intensive job, but for reading emails, doing a lot of ssh and
http/https the drivers is working smoothly.

I will try to compile this new one on my stable during the week end
and will see on Monday how it will perform on my office wi-lan.

For the records: my wpi doesn't still work on OpenBSD-current cause
it's integrated and the switch used to turn it on seems an acpi one
which OpenBSD doesn't attach very well yet.

Hi Folks,
   I did the port as my searching led me to believe that progress on a 
driver had stagnated.
Port 1: was done by Damien himself 
(http://lists.freebsd.org/pipermail/freebsd-mobile/2006-July/008768.html)
Port 2: was an updated version by Daminen:  
http://osdir.com/ml/freebsd-hackers@freebsd.org/msg58154.html
   which seems to be duplicated here: 
http://people.freebsd.org/~flz/local/wpi/ 
(http://www.mail-archive.com/freebsd-net@freebsd.org/msg20710.html)
With version 2 being minor bug fixes to version 1 to try and get it 
working. Since then the driver has come a long way in netbsd with the 
FreeBSD version just getting older. 

To others working on a wpi driver, please post something indicating what 
you've done and even a sample of what your up to so we can one build one 
driver that just works. I also did the driver port as everything I found 
failed to work on a 64bit kernel, most the time wouldn't even compile.


I'm happy to try and maintain this driver. I have the hardware.

The main bugs I know about in this driver port are:

* The use of the iee80211_amrr code
The files exist in -current in /usr/src/sys/net80211 but the required 
symbols are not in a GENERIC kernel build. There is a wlan_amrr module 
which uses this code, though I'm not sure how to make use of this, it 
appears a simple dependency on the module is not enough. The use of the 
80211_amrr code also means that use under -stable requires quite a bit 
more work as Rink pointed out.


* Bus resource allocation issues
Mainly related to:  bus_dmamem_alloc failed to align memory properly.
I'm hoping Mike 
(http://lists.freebsd.org/pipermail/freebsd-stable/2006-June/026262.html) 
might be able to help resolve these.


These allocation issues are caused while allocating of the rx  tx ring 
buffers - which if they are broken explain why things don't work.
I'm still coming to grips to how the whole bus_dma_tag_create works. The 
Netbsd bus_dma_map_alloc seems much more intuitive.
I've found if the module failed the first time, unloading it, then 
reloading it would often make the allocation issues disappear and the 
driver just work.
Though I've also found sometimes that even though the allocation issues 
are reported, things still work, I'm guessing the alignment is pulled 
into line by higher levels of bus_dma.


* ifconfig down causes timeouts reseting the tx ring
I'm still chasing the cause of this. It seems non critical as the driver 
still works with an ifconfig up


* Watch dog timer uses an obsolete interface
I'm looking into the correct way to do watchdog timing

* A lock order reversal in wpi_intr
lock order reversal:
1st 0x812d9e20 wpi0 (network driver) @ if_wpi.c:1554
 2nd 0xff003cee32f0 radix node head (radix node head) @ net/route.c:147
 KDB: stack backtrace:
 db_trace_self_wrapper() at db_trace_self_wrapper+0x3a
 witness_checkorder() at witness_checkorder+0x4f9
 _mtx_lock_flags() at _mtx_lock_flags+0x75
 rtalloc1() at rtalloc1+0x7a
 arplookup() at arplookup+0x5c
 arpintr() at arpintr+0x255
 ether_demux() at ether_demux+0x2d3
 ether_input() at ether_input+0x1e9
 ieee80211_input() at ieee80211_input+0xd05
 wpi_intr() at wpi_intr+0x9d7
 ithread_loop() at ithread_loop+0xfe
 fork_exit() at fork_exit+0xaa
 fork_trampoline() at fork_trampoline+0xe
 --- trap 0, rip = 0, rsp = 0xa0698d40, rbp = 0 ---

For those wishing to help debug the driver and get it working, I've 
posted a new version

http://www.clearchain.com/~benjsc/download/20070107-wpi-freebsd.tar.gz

To help debug:

   kldload wpi_ucode
   kldload if_wpi
   wlandebug -i wpi0 0xff   (I've included a copy of the -current 
tool to save having to checkout the tree)

   sysctl debug.wpi=10(Debug levels are explained in if_wpi.c)
   ifconfig wpi0 up
   ... wait 30 seconds then...
   ifconfig wpi0 down

   Then put /var/log/messages somewhere on the web  let me know

This will dump lots of debug info to syslog but should help me work out 
whats happening. If the driver works for you, stick to debug level 5 
max, else you'll be bombarded with logs. I'll try to install FBSD 32 
-current  -stable (32/64) on the laptop in the next week to see what 
might be different. ANY feedback is helpful.


Finally, for those who see rx 

Updated Driver for 3945ABG Intel 3945ABG Wireless LAN controller

2007-01-05 Thread Benjamin Close

Hi All,
   After getting a new laptop I discovered being tied to a wire when 
your used to wireless is extremely annoying.


Hence I've done a port of the NetBSD driver wpi (20070106 rev) for the 
Intel3945ABG wireless card to FreeBSD
Many thanks to Damien for writing the NetBSD driver in the first place 
and the initial FreeBSD port which I referenced extensively.


The driver is available at:

http://www.clearchain.com/~benjsc/download/20070106-wpi-freebsd.tar.gz

(dynamic dns host, so just retry later if it's down):

Please let me know if you have any issues and I'll try to address them.
I'm not sure how well it will work on -stable, I'm running

FreeBSD wolf.clearchain.com 7.0-CURRENT FreeBSD 7.0-CURRENT #0: Wed Dec 
13 16:09:21 CST 2006 
[EMAIL PROTECTED]:/usr/src/sys/amd64/compile/GENERIC  amd64


and don't have a -stable machine for testing.
Those not using -current, be sure to remove

#define WPI_CURRENT

in if_wpi.c before compiling.

This email was sent through the driver :)

Cheers,
   Benjamin
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]


[RFT]: InFlight Mode Patch

2006-07-17 Thread Benjamin Close

Hi Folks,
	After receiving no feedback on -current, figured I'd send this to 
-hackers... probably should of in the first place.

Please CC any comments as I'm not on the hackers list.

-

Hi All,
   Whilst looking on the FreeBSD projects page I noticed the 'InFlight'
mode project.
A patch is available at:

http://www.clearchain.com/people/benjsc/download/20060712-inflight_mode.patch.gz

Which implements a boot menu item, sysctl tunable (hw.inflight_mode) and
prevents all wireless  bluetooth drivers from attaching (probe succeeds
still).

Testing / comments welcome.

Cheers,
   Benjamin
___
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to [EMAIL PROTECTED]