OpenWrt Forum Archive

Topic: Wifi on AR7 (with acx-mac80211)

The content of this topic has been archived between 30 Mar 2018 and 12 Apr 2018. Unfortunately there are posts – most likely complete pages – missing.

heruan wrote:

How did you get it working? wpa_supplicant? could you please post the steps you did?

wpa_supplicant -Dwext -i<your wlan iface> -c<your conf file>
worked for me on r9009

But i can't get it working in AP mode. Anyone?

There is no AP mode support in the acx-mac80211 drivers at the moment.

nabcore wrote:

There is no AP mode support in the acx-mac80211 drivers at the moment.

From acx-mac80211-20070718.tar.bz2 Changelog:

[20060605-20060706]
* Jeff Williams <jeff@wdwconsulting.net>
  Added DeviceScape 80211 stack support to PCI
  Works with wpa_supplicant and hostapd
  Removed excess homegrown/linux-wlan 80211 stack

So, provided it worked as supplicant, i suppose it should work as AP too (?)
A newer version came with r9112, i'll give it a try...

i'll be waiting on your report

rAndy wrote:
heruan wrote:

How did you get it working? wpa_supplicant? could you please post the steps you did?

wpa_supplicant -Dwext -i<your wlan iface> -c<your conf file>
worked for me on r9009

In r9047 I get:

root@OpenWrt:~# wpa_supplicant -Dwext -iwlan0 -c /etc/wpa_supplicant.conf 
ioctl[SIOCSIWAUTH]: Operation not supported
WEXT auth param 7 value 0x1 - ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWAUTH]: Operation not supported
WEXT auth param 4 value 0x0 - ioctl[SIOCSIWAUTH]: Operation not supported
WEXT auth param 5 value 0x1 - CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
ioctl[SIOCSIWENCODEEXT]: Operation not supported
CTRL-EVENT-DISCONNECTED - Disconnect event - remove keys

... and so on.
Maybe an error in my config file?

ctrl_interface=/var/run/wpa_supplicant
eapol_version=1
ap_scan=1
fast_reauth=1
network={
        ssid="MySSID"
        proto=WPA
        key_mgmt=WPA-EAP
        pairwise=CCMP TKIP
        group=CCMP TKIP
        eap=TLS
        identity="My Identity"
        ca_cert="/etc/certs/CA.crt"
        client_cert="/etc/certs/my.crt"
        private_key="/etc/certs/my.key"
        private_key_passwd="secret"
        priority=1
}
Weedy wrote:

i'll be waiting on your report

Digged in package/acx-mac80211 src code. It looks like it's from Linville wireless-dev tree, which should support AP mode...  Rootkit user means acx driver insn't so far yet, and updated version of acx driver from r9012 on doesn't contain improvements about AP mode. I'm afraid it won't work yet.
I have to understand first how acx driver works...

heruan wrote:

Maybe an error in my config file?

ctrl_interface=/var/run/wpa_supplicant
eapol_version=1
ap_scan=1
fast_reauth=1
network={
        ssid="MySSID"
        proto=WPA
        key_mgmt=WPA-EAP
        pairwise=CCMP TKIP
        group=CCMP TKIP
        eap=TLS
        identity="My Identity"
        ca_cert="/etc/certs/CA.crt"
        client_cert="/etc/certs/my.crt"
        private_key="/etc/certs/my.key"
        private_key_passwd="secret"
        priority=1
}

First of all, i assume you're using acx-mac80211, not acx driver.
Looking at your conf file, it seems to me you want to use IEEE 802.1X authentication. I never try that, only PSK2. But your conf file looks fine.
Please check first if wpa_supplicant .config file in the build directory includes all the capabilities you need. Then try WEP encription first, maybe the driver has problems with WPA

as of r9149, acx-mac80211 locks up the box

rAndy wrote:

First of all, i assume you're using acx-mac80211, not acx driver.
Looking at your conf file, it seems to me you want to use IEEE 802.1X authentication. I never try that, only PSK2. But your conf file looks fine.
Please check first if wpa_supplicant .config file in the build directory includes all the capabilities you need. Then try WEP encription first, maybe the driver has problems with WPA

Yes of course, I'm using acx-mac80211. I can't use PSK too, I get the same error messages...
In wpa_supplicant .confg file I guess includes all those capabilities:

# Enable IEEE 802.1X Supplicant (automatically included if any EAP method is
# included)
CONFIG_IEEE8021X_EAPOL=y

# EAP-MD5 (automatically included if EAP-TTLS is enabled)
CONFIG_EAP_MD5=y

# EAP-MSCHAPv2 (automatically included if EAP-PEAP is enabled)
CONFIG_EAP_MSCHAPV2=y

# EAP-TLS
CONFIG_EAP_TLS=y

# EAL-PEAP
CONFIG_EAP_PEAP=y

# EAP-TTLS
CONFIG_EAP_TTLS=y

Hello,

here is a summary of my results with OpenWrt trunk (revision 9177):

1. Driver acx no longer works, because the VLYNQ-PCI part for AR7 was removed.
    So loading of acx.ko results in unresolved symbols and fails.

2. Driver acx-mac80211 loads, but does not create a network device.
    So this driver is not usable, too.

Here is an extract of the boot protocol.

[42949374.080000] Registered led device: ar7:status
[42949374.090000] vlynq0: regs 0x08611800, irq 29, mem 0x04000000
[42949374.090000] vlynq1: regs 0x08611c00, irq 33, mem 0x0c000000
[42949374.100000] nf_conntrack version 0.5.0 (128 buckets, 1024 max)
...
[42949381.830000] Freeing unused kernel memory: 116k freed
[42949382.400000] Algorithmics/MIPS FPU Emulator v1.5
[sighandler]: No more events to be processed, quitting.
[cleanup]: Waiting for children.
[cleanup]: All children terminated.
- preinit -
- init -
[42949386.580000] acx: this driver is still EXPERIMENTAL
[42949386.580000] acx: reading README file and/or Craig's HOWTO is recommended, visit http://acx100.sourceforge.net/wiki in case of further n
[42949386.590000] acx: compiled to use 32bit I/O access. I/O timing issues might occur, such as non-working firmware upload. Report them
[42949386.600000] acx: running on a little-endian CPU
[42949386.600000] acx: PCI/VLYNQ module v0.3.36-mac80211 initialized, waiting for cards to probe...

Stefan

sw wrote:

Hello,

here is a summary of my results with OpenWrt trunk (revision 9177):

1. Driver acx no longer works, because the VLYNQ-PCI part for AR7 was removed.
    So loading of acx.ko results in unresolved symbols and fails.

Indeed, was removed with changeset 9143, so last working revision is 9141
Will try svn trunk tomorrow...

r9183 on d-link dsl-664g: acx-mac80211 loads fine, no errors, but AP remains invisible to Kismet neither can a client associate

The mac80211 stack with hostap support is the one in the mac80211-attic branch of the wireless-2.6 tree
I can use it as client mode, but only if I do iwconfig commands after that the interface is up. eg:

ifconfig wlan0 192.168.0.1 netmask 255.255.255.0
iwconfig wlan0 essid homenet key open s:apassword

Btw, link quality is very low, and unreliable for real usage yet:

[/]# ping 192.168.0.2 -s 1492
PING 192.168.0.2 (192.168.0.2): 1492 data bytes
1500 bytes from 192.168.0.2: seq=0 ttl=127 time=19.857 ms
1500 bytes from 192.168.0.2: seq=1 ttl=127 time=22.157 ms
1500 bytes from 192.168.0.2: seq=2 ttl=127 time=21.951 ms
1500 bytes from 192.168.0.2: seq=3 ttl=127 time=21.572 ms
1500 bytes from 192.168.0.2: seq=4 ttl=127 time=19.656 ms
1500 bytes from 192.168.0.2: seq=5 ttl=127 time=21.770 ms
1500 bytes from 192.168.0.2: seq=6 ttl=127 time=20.662 ms
1500 bytes from 192.168.0.2: seq=7 ttl=127 time=20.057 ms
1500 bytes from 192.168.0.2: seq=8 ttl=127 time=38.338 ms
1500 bytes from 192.168.0.2: seq=9 ttl=127 time=20.255 ms
1500 bytes from 192.168.0.2: seq=10 ttl=127 time=22.994 ms
1500 bytes from 192.168.0.2: seq=11 ttl=127 time=20.555 ms
1500 bytes from 192.168.0.2: seq=12 ttl=127 time=20.767 ms

--- 192.168.0.2 ping statistics ---
13 packets transmitted, 13 packets received, 0% packet loss
round-trip min/avg/max = 19.656/22.353/38.338 ms

20 msec are really too much for 5 meters without obstacles

(Last edited by rootkit on 8 Oct 2007, 20:55)

Using r9209, I find that I have to do the following:

insmod acx-mac80211.ko
iwconfig wlan0 mode ad-hoc key restricted
iwconfig wlan0 key s:secretket
iwconfig wlan0 essid thenet
ifconfig wlan0 192.168.1.1 up
iwlist wlan0 scanning

I insmod the module since I've disabled it in start up purely only for testing reasons. The final iwlist command seems very important since without it, the link does not work... I've not idea why this is. As for link speed, it seems ok (distance == 0.5 meters):

root@Bunny:~# ping 192.168.1.2 -s 1492
PING 192.168.1.2 (192.168.1.2): 1492 data bytes
1500 bytes from 192.168.1.2: seq=0 ttl=128 time=7.492 ms
1500 bytes from 192.168.1.2: seq=1 ttl=128 time=8.159 ms
1500 bytes from 192.168.1.2: seq=2 ttl=128 time=7.570 ms
1500 bytes from 192.168.1.2: seq=3 ttl=128 time=7.412 ms
1500 bytes from 192.168.1.2: seq=4 ttl=128 time=7.557 ms

Another thing is that I can sometimes trigger a complete crash if I execute the commands in the first block too quickly; i.e. ssh in and then paste all six lines

During normal operation, I also get many of these errors:

phy0: tx error 0x20, buf 03! (excessive Tx retries due to either distance too high or unable to Tx or Tx frame error - try changing 'iwconfig txpower XXX' or 'sens'itivity or 'retry')

r9183 on d-link dsl-664g: even though AP remains invisible, running hostapd with PSK2 AES lets a client authenticate (dunno why didn't made it as i wrote my previous post). But, as soon as a dhcp request starts, AP throws client out with

Jan  1 00:12:32 suewrt daemon.info hostapd: wlan0: STA 00:14:6c:53:16:2c IEEE 802.11: disassociated
Jan  1 00:12:33 suewrt daemon.info hostapd: wlan0: STA 00:14:6c:53:16:2c IEEE 802.11: deauthenticated due to inactivity
Jan  1 00:12:33 suewrt user.warn kernel: phy0: tx error 0x20, buf 14! (excessive Tx retries due to either distance too high or unable to Tx or Tx frame error - try changing 'iwconfig txpower XXX' or 'sens'itivity or 'retry')

I couldn't get nothing more than a 5ms average 10 packets ping :-(

To be investigated is this too:

FIXME: Possibly broken code in acx_s_update_card_settings() at /mnt/hd/hdb/devel/openwrt/trunk/build_dir/linux-ar7/acx-mac80211-20071003/common.c:3588

.. and my wifi card gets too hot, even thou the router remains open (to gain acces to serial port). That's not good, maybe it's an heating issue too?

with r9253 i get the following.

root@OpenWrt:/$ insmod acx-mac80211.ko
acx: this driver is still EXPERIMENTAL
acx: reading README file and/or Craig's HOWTO is recommended, visit http://acx100.sourceforge.net/wiki in case of further questions/discussion
acx: compiled to use 32bit I/O access. I/O timing issues might occur, such as non-working firmware upload. Report them
acx: running on a little-endian CPU
acx: PCI/VLYNQ module v0.3.36-mac80211 initialized, waiting for cards to probe...
acx: found TI TNETW1130-based wireless network card at vlynq0, irq:80, phymem:0x4000000, mem:0xa4000000
initial debug setting is 0x000A
acx: need firmware for acx111 chipset with radio ID 16
Please provide via firmware hotplug:
either combined firmware (single file named 'tiacx111c16')
or two files (base firmware file 'tiacx111' + radio fw 'tiacx111r16')
acx: need to load firmware for acx111 chipset with radio ID 16, please provide via firmware hotplug:
acx: either one file only (<c>ombined firmware image file, radio-specific) or two files (radio-less base image file *plus* separate <r>adio-specific extension file)
requesting firmware image 'tiacx111c16'

and then its stalled.

Have you actually got the firmware in /lib/firmware ?

yes and

 root@OpenWrt:/$ insmod acx-mac80211.ko debug=0xffff
acx: this driver is still EXPERIMENTAL
acx: reading README file and/or Craig's HOWTO is recommended, visit http://acx100.sourceforge.net/wiki in case of further questions/discussion
00016196 ==> acxpci_e_init_module
acx: compiled to use 32bit I/O access. I/O timing issues might occur, such as non-working firmware upload. Report them
acx: running on a little-endian CPU
acx: PCI/VLYNQ module v0.3.36-mac80211 initialized, waiting for cards to probe...
00016214   ==> vlynq_probe
acx: found TI TNETW1130-based wireless network card at vlynq0, irq:80, phymem:0x4000000, mem:0xa4000000
initial debug setting is 0xFFFF
00016230     ==> acxpci_s_reset_dev
00016230       ==> acxpci_s_upload_fw
acx: need firmware for acx111 chipset with radio ID 16
Please provide via firmware hotplug:
either combined firmware (single file named 'tiacx111c16')
or two files (base firmware file 'tiacx111' + radio fw 'tiacx111r16')
acx: need to load firmware for acx111 chipset with radio ID 16, please provide via firmware hotplug:
acx: either one file only (<c>ombined firmware image file, radio-specific) or two files (radio-less base image file *plus* separate <r>adio-specific extension file)
requesting firmware image 'tiacx111c16'

Just tried r9254 on dsl-664g, same results as r9183

Problems on r9270...

root@OpenWrt:/$ dmesg | grep acx
acx: this driver is still EXPERIMENTAL
acx: reading README file and/or Craig's HOWTO is recommended, visit http://acx100.sourceforge.net/wiki in case of further questions/discussion
acx: compiled to use 32bit I/O access. I/O timing issues might occur, such as non-working firmware upload. Report them
acx: running on a little-endian CPU
acx: PCI/VLYNQ module v0.3.36-mac80211 initialized, waiting for cards to probe...
acx: found TI TNETW1130-based wireless network card at vlynq0, irq:80, phymem:0x4000000, mem:0xa4000000
acx: need firmware for acx111 chipset with radio ID 16
either combined firmware (single file named 'tiacx111c16')
or two files (base firmware file 'tiacx111' + radio fw 'tiacx111r16')
acx: need to load firmware for acx111 chipset with radio ID 16, please provide via firmware hotplug:
acx: either one file only (<c>ombined firmware image file, radio-specific) or two files (radio-less base image file *plus* separate <r>adio-specific extension file)
requesting firmware image 'tiacx111c16'
acx_write_fw (main/combined): 0
acx_validate_fw (main/combined): 0
FIXME: Possibly broken code in acx_s_set_sane_reg_domain() at /home/giovanni/workspace/openwrt/trunk/build_dir/linux-ar7/acx-mac80211-20071003/common.c:3296
acx: chipset TNETW1130, radio type 0x16 (Radia), form factor 0x01 ((mini-)PCI / CardBus), EEPROM version 0x05, uploaded firmware 'Rev 2.3.1.31''ncreating /proc entry driver/acx_
creating /proc entry driver/acx__diag
creating /proc entry driver/acx__eeprom
creating /proc entry driver/acx__phy
acx v0.3.36-mac80211: net device phy0, driver compiled against wireless extensions 22 and Linux 2.6.23
acx: ieee80211_register_hw() FAILED: -12
acx_vlynq: probe of vlynq0 failed with error -12

Different problems:

creating /proc entry driver/acx__diag
creating /proc entry driver/acx__eeprom
creating /proc entry driver/acx__phy
acx v0.3.36-mac80211: net device phy0, driver compiled against wireless extensions 22 and Linux 2.6.23
using IRQ 80
wmaster0: Selected rate control algorithm 'simple'
Virtual interface added (type: 0x00000002, ID: 4, MAC: 08:00:28:32:00:00)
updating initial settings on iface activation
get_mask 0x00000000, set_mask 0x0036EEFE
important setting has been changed. Need to update packet templates, too
updating Tx fallback to 1 retries
updating transmit power: 15 dBm
updating antenna value: 0x4A
updating Energy Detect (ED) threshold: 0
acx111 doesn't support ED!
updating Channel Clear Assessment (CCA) value: 0x00
acx111 doesn't support CCA!
updating channel to: 1
updating: enable Tx
FIXME: Possibly broken code in acx_s_update_card_settings() at /home/openwrt/build_dir/linux-ar7/acx-mac80211-20071003/common.c:38
updating: enable Rx on channel: 1
updating short retry limit: 7, long retry limit: 4
updating tx MSDU lifetime: 4096
updating regulatory domain: 0x10
FIXME: Possibly broken code in acx_s_set_sane_reg_domain() at /home/openwrt/build_dir/linux-ar7/acx-mac80211-20071003/common.c:326
setting RXconfig to 2008:0FDF
updating WEP key settings
get_mask 0x00000000, set_mask 0x00000040
setting RXconfig to 2008:0FDF
BUG: spinlock cpu recursion on CPU#0, klogd/193
 lock: 94326fa8, .magic: dead4ead, .owner: events/0/5, .owner_cpu: 0
Call Trace:
[<9400877c>] dump_stack+0x8/0x34
[<9412db98>] _raw_spin_lock+0x64/0x12c
[<9421a558>] _spin_lock_irqsave+0x30/0x44
[<c009fb14>] acx100pci_s_set_tx_level+0x390/0x4ec [acx_mac80211]

BUG: spinlock lockup on CPU#0, klogd/193, 94326fa8
Call Trace:
[<9400877c>] dump_stack+0x8/0x34
[<9412dc38>] _raw_spin_lock+0x104/0x12c
[<9421a558>] _spin_lock_irqsave+0x30/0x44
[<c009fb14>] acx100pci_s_set_tx_level+0x390/0x4ec [acx_mac80211]

This is caused by a call to acx_lock in acx_e_after_interrupt_task while a lock is already active.
It shows only when lock debugging is enabled.

(Last edited by sw on 13 Oct 2007, 21:30)

Off-topic : 2.6.23 is overall very unstable on my D-Link DSL-G624T ( without wifi ), anyone else experiencing hangs ( or watchdog reboots ) every 15 minutes ?

Cyberlullaby wrote:

Off-topic : 2.6.23 is overall very unstable on my D-Link DSL-G624T ( without wifi ), anyone else experiencing hangs ( or watchdog reboots ) every 15 minutes ?

watchdog reboot? i wish i had one...

..and you actually can have one. "watchdog /dev/watchdog" works for me.
Aren't you a OpenWRT developper ("matteo") ?

Cyberlullaby wrote:

..and you actually can have one. "watchdog /dev/watchdog" works for me.
Aren't you a OpenWRT developper ("matteo") ?

Yes, but the watchdog never worked on my WAG54G. I had a ticket for this

Sorry, posts 51 to 50 are missing from our archive.