- Add auto TX power and RX sensitivity calibration support. Add two sysctl
authorSepherosa Ziehau <sephe@dragonflybsd.org>
Thu, 17 Jan 2008 07:35:38 +0000 (07:35 +0000)
committerSepherosa Ziehau <sephe@dragonflybsd.org>
Thu, 17 Jan 2008 07:35:38 +0000 (07:35 +0000)
commit99fda2c4f7bbb9d9351fbc814aa0a0dde8ff7e73
treeb288da18ad2ec87d565f94c34dff303d280cf9e8
parenta7bdb8f3eea129e1432ac76f4dda81f540fcc4bc
- Add auto TX power and RX sensitivity calibration support.  Add two sysctl
  nodes to enable/disable them.  Calibration is only done when NIC operates
  as STA, since it does not make sense when the NIC operates in other mode.
  By default, they are all disabled.
- Add sysctl node for TX power correction.  TX power correction is disabled
  by default.  This could be used when TX power calibration should not be
  performed, e.g. when NIC operates as AP

Enable TX power and RX sensitivity calibration and set TX power correction
to 8 (-4db) makes my EW-7608PG work well @48Mb and @54Mb when it is near AP
(-44dbm ~ -58dbm), @54Mb ~50 retries for ~1080 packets.  Originally the NIC
requires at least one retry for every packets @48Mb.

TX power calibration needs further investigation.  Calibrating TX power
based on RSSI may not work weel; integrate it into TX rate control may work
better.

Various limits and correction values are obtained from Ralink RT61 driver.

# TX power stepping for Auto-AGC capable NICs is not in place yet.
# RX sensitivity calibration for long distance is not in place yet.
sys/dev/netif/ral/rt2661.c
sys/dev/netif/ral/rt2661reg.h
sys/dev/netif/ral/rt2661var.h