Linux central regulatory domain agent ------------------------------------- The central reg agent consists of two main parts: * ISO3166-1 module (iso3166-1.ko) * Regulatory module (regdomains.ko) Integration with the kernel wireless subsystem is done by extending cfg80211 to support a central regulatory domain to which all devices should adhere to. Then, mac80211 is expanded to allow devices to indicate their deivice is configured to a specific regulatory domain domain, set set either in its EEPROM or firmware. Helper routines are also provided for mac80211 to build the ieee80211_channel array of hardware supported channels. After a regulatory domain is set all cfg80211 devices are scanned for and their channels are iterated over, only channels which the regulatory domain indicates are valid for its current regulatory domain are enabled. Power restriction for PtP and PtMP type of connections are also considered and set. Each country can be mapped to one regulatory domain. Each regulatory domain has two maps for channels, one on the 2.4GHz band and another on the 5GHz band. Power restrictions are a little more complicated -- we break both the 2GHz band and the 5GHz band into 7 logical subbands as follows: Subband name Min (MHz) Max (MHz) IEEE-802.11 Channel range ISM-2.4 2412 2732 1-26 Telec 5005 5145 1-29 UNII-1 5150 5245 30-49 UNII-2 5250 5350 50-70 ETSI 5355 5720 71-144 UNII-3 5725 5825 145-165 AAD 5830 6100 166-220 Note that ETSI also operates on UNII-2, we split this into logical names just to be pragmatic. Then for each subband we define specific power restrictions. The current regualtory map is found in regulatory_map.h A userspace daemon can later be provided to update the regulatory map. At the very least the kernel should have the world regulatory domain but note that due to large amount of varied restrictions this means only enabling 3 channels on the 2GHz band (5, 6 and 7) and no channels on the 5GHz band with minimal PtMP power restrictions. For further implementation details please refer kerneldoc of iso3166-1, regdomains, cfg80211, and mac80211. --- Wireles regulatory primer: PtMP - Point to Multipoint PtP - Point to Point EIRP - Equivalent Isotropically Radiated Power IR - Intentional Radiator, transmitter dBm - dB milliwatt (mW), the base says that 1mW = 0 dBm dBi - dB relative to isotropic, used to measure antenna gain compared to an isotropic antenna on which radiation is distributed uniformly on the surface of a sphere EIRP = IR - loss in transmission line + passive gain of the antenna --- Some information based on: http://university.cyberarmy.net/kb/tiki-index.php?page=The+Power+of+802.11 Bellow is an example for FCC. In the 2.4Ghz ISM band the FCC stipulates that the creation of PtMP links be subject to the following restrictions: - EIRP must not exceed 36 dBm (4W) - IR must not exceed 30 dBm (1W) - For every 3 dBi of antenna gain after the first 6 “free” dBi the IR must be decreased by 3 dBi (the 1:1 rule) Example (without considering loss) of possible settings if Max EIRP is defined as 36 dBm and we are using the 1:1 rule: TX power (dBm) Antenna Gain (dBi) Max EIRP (dBm) 30-------------------6----------------------36 29-------------------7----------------------36 28-------------------8----------------------36 27-------------------9----------------------36 For PtP links that rule is augmented: - No Maximum EIRP - IR is limited to 30 dBm (1W) - For every 3 dBi after the first 6 of antenna gain the IR must be decreased by 1 dBi (the 3:1 rule) Example, where IR limit is 30, and has the 3:1 rule above for gain: TX power (dBm) Antenna Gain (dBi) Effective EIRP (dBm) 29-------------------6-----------------------35 30-------------------6-----------------------36 29-------------------9-----------------------38 28-------------------12----------------------40 27-------------------15----------------------42 26-------------------18----------------------44 25-------------------21----------------------46 In the 5GHz band the FCC stipulates for PtMP: - UNII-1: Maximum IR power may not exceed 40mW (16dBm) - UNII-1: EIRP may not exceed 160mW (22dBm) - UNII-2: Maximum IR power may not exceed 200mW (23dBm) - UNII-2: EIRP may not exceed 800mW (29dBm) - UNII-3: Maximum IR power may not exceed 800mW (29dBm) - UNII-3: EIRP may not exceed 3.2W (35dBm) - All three bands utilize the 1:1 rule For PtP: - UNII-1 Follows the same rules as the PtMP links - UNII-2 Follows the same rules as the PtMP links - UNII-3 May use an antenna with up to 23dBi of gain before the 1:1 rule becomes effective. (Giving a maximum EIRP of 200W!!)