On Sun, May 14, 2017 at 03:24:34PM +0200, Jan Stary wrote:
> > But please show me your hostname.iwm0 file.
> dhcp

So you're not setting a network name (and perhaps a WPA password) before
bringing the interface up. Does the message go away if you do that?

> > It's possible that you're running a specific sequence of commands which
> > triggers this. If I knew what those are I could try to reproduce it.
> 
> I move between different SSIDs and never got around to automatize it
> (btw, what do people use for that?), so I do it manually, like this:
> 
> $ doas ifconfig iwm0 up nwid stare.cz wpakey XXXPASSWORDXXX -nwkey

No need for 'up' in this line. 'up' triggers a scan because the interface
will try to find an AP when it goes UP. The following commands on this line
then set additional parameters and because of that the device must be reset.
So with this single line you bounce the device up and down several times.
It works, but it may cause a scan to be aborted midway and then you'll see
the 'could not initiate scan' message. It is really just a cosmetic problem.
You're pushing the configuration through various states before things
eventually settle down.

I am not blaming you -- this is a problem with how the ifconfig->kernel
interfaces and scanning logic were designed. There is no way for the driver
to tell whether ifconfig is looking for a list of APs or a specific AP to
connect to, for example. The commands 'ifconfig scan' and 'ifconfig up' are
the same from the driver's perspective. Changing this would be a lot of work
so we'd need another wifi developer to do that. Any volunteers?

> $ doas sh /etc/netstart iwm0

You could just run 'dhclient iwm0' here.

> > > Running against a current/i364 AP
> > > seems to work fine with 11g (less so with 11n).
> > 
> > It's an athn(4) AP?
> 
> Yes. It's an ALIX (dmesg below) with
> 
> athn0 at pci0 dev 12 function 0 "Atheros AR5416" rev 0x01: irq 9
> athn0: MAC AR5416 rev 2, RF AR2133 (3T2R), ROM rev 2, address 
> 00:1d:6a:6b:03:07

> I was having problems using 11n (with various clients) and
> was advised here to use 11g for now, which indeed seems more reliable.

You have a device with unequal numbers of Tx and Rx streams.
There was a bug in 6.1 which affects those. I believe a commit I made on
the 23rd of April has fixed 11n mode for your athn device but you're still
running a snap from April 9. So please upgrade and try again!

> OpenBSD 6.1-current (GENERIC) #304: Sun Apr  9 20:21:01 MDT 2017
>     [email protected]:/usr/src/sys/arch/i386/compile/GENERIC

Reply via email to