TDLS: Fix key configuration with current mac80211

A kernel commit ("mac80211: fix FT roaming") started validating that the
STA entry is marked associated when adding a key. While this is needed
to fix some FT use cases with hardware crypto, it has a side effect of
breaking TDLS key configuration. Work around this by trying to
re-configure the key for the direct link after the STA entry has been
set with all information. In addition, try to tear down the link if
anything goes wrong in key configuration (if both attempts fail) or
enabling the link in the driver.

Signed-hostap: Jouni Malinen <j@w1.fi>
wlantest: Fix CCMP-256 cipher

TK was incorrectly truncated in a way that resulted in CCMP (128-bit
key) encryption being used in practice.

Signed-hostap: Jouni Malinen <jouni@qca.qualcomm.com>
wpa_supplicant: Support minimum interval between scan attempts.

When running lots of vifs, they can all end up wanting to
scan right after the other.  This leaves too little time for
useful work to happen.  Allow users to configure a minimum
timer interval (in seconds) between scans.  Default is zero,
which is current behaviour.

Signed-off-by: Ben Greear <greearb@candelatech.com>
supplicant:  Allow limiting number of concurrent associations.

When using lots of virtual clients, it may be useful to
limit the number that attempt to connect to the AP at
once.  Limitting the associations per scan response is
an easy way to do this.

Signed-hostap: Ben Greear <greearb@candelatech.com>
hostap:  Ensure netlink recv buf size is large enough.

I was getting this error on wpa_supplicant startup when configured
for 200+ stations:

1333514002.074458: netlink: recvfrom failed: No buffer space available

So, increase rcv buffer size to 1MB so we don't drop netlink
packets.

Signed-hostap: Ben Greear <greearb@candelatech.com>
nl80211:  Increase verbosity for some auth failures.

Makes the logs a bit more useful when running in default
message level (INFO).
Increase EAPOL timers.

This allows 128 stations to associate & authenticate
all at once.  Without this, 4-way handshake doesn't
work right.

From: Bjorn Smedman <bjorn.smedman@venatech.se>

NOTE:  This should probably not be applied upstream as is..but
should be a configuration option in the hostapd.conf file.

Signed-off-by: Ben Greear <greearb@candelatech.com>
Support can-scan-one using -1 for freq.

Signed-off-by: Ben Greear <greearb@candelatech.com>
nl80211: Add identifier to structs

This helps one figure out what type of struct the object is, since they
are usually passed around as void* ctx pointers. Can be used in gdb
currently, but run-time checks could be added later if needed.

Signed-off-by: Ben Greear <greearb@candelatech.com>
nl80211:  Remove MLME retry code that causes trouble.

When testing 130+ virtual stations, using no encryption
(no WPA, etc), some number of them will get into endless
loops of authenticating and de-authenticating.  It appears
that the code that is supposed to ignore the spurious de-auth
event created by this retry logic does not work in all cases.

Removing the retry code as this patch does fixes the problem
for me.

Maybe the entire patch (6d6f4bb8) should be reverted?

Signed-hostap: Ben Greear <greearb@candelatech.com>
Fix can-scan-one logic..merge error.

Signed-off-by: Ben Greear <greearb@candelatech.com>