]> git.baikalelectronics.ru Git - kernel.git/commit
cfg80211: Add antenna availability information
authorBruno Randolf <br1@einfach.org>
Wed, 8 Dec 2010 04:59:24 +0000 (13:59 +0900)
committerJohn W. Linville <linville@tuxdriver.com>
Mon, 13 Dec 2010 20:23:27 +0000 (15:23 -0500)
commit026150eee89c67eb816bca21809264553e3e9255
tree174134b89e490592003307263e6b3964d9a1eacf
parent88408b54a282d555676e6b0f474e6f46486ce909
cfg80211: Add antenna availability information

Add a field to wiphy for the hardware to report the availble antennas for
configuration. Only if this is set to something bigger than zero, will the
anntenna configuration ops be executed.

Allthough this could be a simple number of antennas, I defined it as a bitmap
of antennas which are available for configuration, since it's more consistent
with the rest of the antenna API and there could be cases where the
hardware allows only configuration of certain antennas. As it does not make
much of a difference in size or normal usage, I think it's better to be able to
support this, in case the need arises.

The antenna configuration is now also checked against the availabe antennas and
rejected if it does not match.

Signed-off-by: Bruno Randolf <br1@einfach.org>
--
v3: always apply available antenna mask (for "all" antennas case).

v2: reject antenna configurations which don't match the available antennas
Signed-off-by: John W. Linville <linville@tuxdriver.com>
include/net/cfg80211.h
net/wireless/nl80211.c